I’m currently trying to make bullet holes wrap around a surface, like in Arsenal:
How should I go about this?
Theres a couple of topics on this, but none of them seemed to have a solution / the solution didn’t work for me / the solution was buggy
I found this article by EgoMoose, which is probably very useful for this sort-of-thing, but I couldn’t seem to wrap my head around it / how I would make it work with bullet holes.
Have to ask before writing a long post.
Have you tried calculating the location of the second bullet hole by, as you know the size of the original bullet hole, checking if it is on the edge of a part, and inserting another half-split bullet hole on another left/right side of that part?
That seems the most reasonable solution and what they are probably using.
You can solve that as there is enough material in a single raycast to do that.
Writing a performant solution right here right now is lengthy, that time to spend - I can’t afford.
I’ll give you a tip.
To figure out how close you are to the edge of a part, first localize the hit position related to the part you have:
local relative: Vector3 = hit_part.CFrame:PointToObjectSpace(hit_pos)
With the relative position you can find out on which size and how close to the edge you are.