charlie
February 25th, 2003, 03:56 AM
I tried posting this on the Flash MX board yesterday, and a few people looked but no-one seemed to be able to help so far.
I am attempting a reasonable simple platform game in flash (think jet set willy or something suitably old.) The problem I am having is with the collision checks, I have tried with Hittest() and a mathematical solution which checks the location of character and object. Both ended up with a similar problem, if you hit a block either horizontally or vertically the collision was checked properly and the character would stop. BUT if you came in at an angle sometimes you'd end up stuck halfway through the object. It obviously is something to do with the difference in checking between horizontal and vertical collisions but I can't seem to find a solution.
Any help would be gratefully received, and if anyone would like to se the fla I would be glad to post it up.
I am attempting a reasonable simple platform game in flash (think jet set willy or something suitably old.) The problem I am having is with the collision checks, I have tried with Hittest() and a mathematical solution which checks the location of character and object. Both ended up with a similar problem, if you hit a block either horizontally or vertically the collision was checked properly and the character would stop. BUT if you came in at an angle sometimes you'd end up stuck halfway through the object. It obviously is something to do with the difference in checking between horizontal and vertical collisions but I can't seem to find a solution.
Any help would be gratefully received, and if anyone would like to se the fla I would be glad to post it up.