Hi all !
Im relatively new to Defold and I’m currently developing a platformer game. I have an enemy game object with a script file (attached below) and collision object. I’m trying to create a Goomba like enemy where if the player collides with the enemy GO head collision object the enemy GO will be eliminated.
Enemy script file
skeletonMovements.script (2.9 KB)
My issue is that the enemy GO does not recognise a collision has taken place if in contact with the player GO. I’ve made sure the I’ve named the group and mask correctly and added a print message to trigger if a collision has taken place. I’ve tried having two collision objects on the same enemy and tried creating a child GO with a collision object( trigger type) off the parent enemy GO and neither have recognised a collision ( example below) and I’m not sure why.
Run time with physics debugger - Clear interception but no print message to console
I hope I have been able to express my issue in a way that is understandable. Please let me know if you need more information.