1 decade ago by gxxaxx
For various reasons in my recent game there was a need to have the option of assigning more than one collision tile type.
0: neither A nor B collide with tile
1: both A and B collide with tile
2: A collides, B does not collide with tile
3: B collides, A does not collide with tile
I tried to find a way to handle this without poking in the collision-map.js
But, when I finally worked out a solution, it was simplest to just change a few lines of code in the collision-map.js file.
Was wondering if anyone found a more direct method that did not involve hacking the core code.
p.s. I would have liked to get specific feedback on the code changes, but without a members only area, I don't feel okay in exposing chunks of the core code to google search.
0: neither A nor B collide with tile
1: both A and B collide with tile
2: A collides, B does not collide with tile
3: B collides, A does not collide with tile
I tried to find a way to handle this without poking in the collision-map.js
But, when I finally worked out a solution, it was simplest to just change a few lines of code in the collision-map.js file.
Was wondering if anyone found a more direct method that did not involve hacking the core code.
p.s. I would have liked to get specific feedback on the code changes, but without a members only area, I don't feel okay in exposing chunks of the core code to google search.