how would you make a cut wound mark on a shape ? (3D)

Started by RemiD, October 13, 2024, 22:20:45

Previous topic - Next topic

RemiD

hi  :)

for my current game ( hallowen shooter 3d), i want the player to use a machete (big knife), to fight against pumpkins, and i want that each hit must leave a cut wound mark on the pumpkin.

my current idea is to use line pick when the machete is turned moved, to get the hit points, and use these points to build a mesh (subdivided rectangle), which will be put above and along the pumpkin outside shape, and then set this wound mesh as a child of the pumpkin mesh, so that it will turn move with it (be parented with it).

from the experiments i have done so far, it seems to be doable...

any other idea ?

thanks !

Matty

Second texture with second set of uv coords (or even the same uv coords if it doesn't need to be exactly where the strike hit the object)....

Multiply blend a mainly white texture with a blood smear/cut on it over the main texture of the pumpkin. If you're using a second set of uv coords just position the texture so that the smear roughly aligns with whereabouts the pumpkin was hit.

RemiD

@Matty >>
a little less precise, but it may look good enough to be convincing, but i don't see how you would manage to put several cuts on the same second layer ?

and how to position the cut approximately where the blade has hit the shape ?

Quotejust position the texture so that the smear roughly aligns with whereabouts the pumpkin was hit.
and how would you do that ?

RemiD

another idea :
uvmap the surface of the shape so that the texel size is approximately uniform.

and use the codes linepick 3d to picked U,V and Picked TX,TY, to draw 2D lines between 2D points, directly on the texture.

https://www.syntaxbomb.com/3d-graphics-maths/bb-pickeduv-move-texture-with-mouse-by-noobody-1-years-ago/

https://www.syntaxbomb.com/3d-graphics-misc/bb-pickedu-pickedv-pickedw-by-fredborg-1-years-ago/

however this is more complicated to implement because the unwrap / uvmap must be done in a way that the 2d bodyparts (on the texture) must be continuous / not separated. otherwise the 2d line will go over others 2d bodyparts (on the texture) which is not what we want.

Baggey

Did you finish your Cyclone game?

Kindest Regards Baggey
Running a PC that just Aint fast enough!? i7 4Ghz Quad core 32GB ram  2x1TB SSD and NVIDIA Quadro K1200 on Acer 24" . DID Technology stop! Or have we been assimulated!

Windows10, Parrot OS, Raspberry Pi Black Edition! , ZX Spectrum 48k, C64, Enterprise 128K, The SID chip. Im Misunderstood!

RemiD

QuoteDid you finish your Cyclone game?

no i have not worked on it since 2023 November 20

i may work on it again, during the winter months...

blinkok

I would make a rectangle that is curved to conform (Roughly) with the shape of the pumpkin. 
Texture that to have a slash mark.
Attach that to the object at the angle and position of the machette.
I don't think it needs to be perfect

RemiD

QuoteI would make a rectangle that is curved to conform (Roughly) with the shape of the pumpkin

yes i am working on something like this, a rectangle mesh which will follow the shape of the pumpkin. and position vertices to make it look like a cut (wide at the middle, narrow at the extremities), and use a simple color texture but without details.