- Home /
2D collisions on a Game Object Sprite with transparent areas
i had a fire animation on Game Object sprite, and i had success to make the fire ball able to trigger. but my problem is because the Image itself had transparent part, and the transparent area able trigger when i click it.
is that got any way, like add what component can auto remove the transparent part? or wont have any effect when i click on the transparent part?
because the images list is huge, so if i do it manual it. then it really will take a lot of time. so i hope any one can show me got other way to make it faster or not? even scripting, component or properties also can. thanks a lot.
Answer by Kamawoop · Aug 25, 2017 at 09:56 PM
I am fairly new. How I did it was:
Download GIMP (there are many other suitable packages available), but this is free.
Import your Sprite with an opaque transparent part and hmmm.....
Answer by SuryaEU · Aug 25, 2017 at 10:02 PM
You could use a polygon collider and edit it manually so the transparent part is not triggering. (if your animation is not modifying too much the shape of your image)
I don't know about automating it for lot of assets though (but I would be interested ! )