-
Hi, I haven't been able to find a collision event in the lib... it looks like maybe people have written hacks to detect it? I want to be able to handle collisions differently depending on what they are: 2 NPC's collide, a player and an NPC collide, etc. Or by type of NPC. And obviously collision with a tile object like a chest. Is there anything I've missed? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hey @arnicas, In case they are blocking each other, a collision could be defined as an approach of a character to go to a tile which is already blocked by another character. In this case you can use directionChanged and check for a character on the tile that was tried to enter using getFacingPosition and getCharactersAt |
Beta Was this translation helpful? Give feedback.
-
Super, thank you - I will do the latter. |
Beta Was this translation helpful? Give feedback.
Super, thank you - I will do the latter.