Live data from Hacker News

Guide to implementing 2D platformers (2012)

higherorderfun.com

11–12 of 12 posts

Re: Guide to implementing 2D platformers (2012)

#11
post #8

> Type #1: Tile-based (pure) > Character movement is limited to tiles, so you can never stand halfway between two tiles. […] > Examples: Prince of Persia That is absolutely false. You can stand on any pixel in Prince of Persia. It’s when I find stupid errors like these that I start to question the entire article they appear in.

As I remember, when you step slowly from the middle of a tile, you always end up on the edge of that tile. And if there is a chasm and you try to step once again, you almost trip and regain balance. If there is no chasm, you step to the middle of the next tile.

IIRC, you can adjust your position quite precisely by crouching, which has a side effect of making you move forward a tiny little bit. Yes, stepping towards a chasm will make you stop at the edge, but that does not alter the fact that your position is definitely not clipped to fixed steps, as the article erroneously claims.

Re: Guide to implementing 2D platformers (2012)

#12
post #6

Related. Others? Guide to implementing 2D platformers (2012) - https://news.ycombinator.com/item?id=31450218 - May 2022 (37 comments) A guide to implementing 2D platformers - https://news.ycombinator.com/item?id=10202275 - Sept 2015 (32 comments) The guide to implementing 2D platformers - https://news.ycombinator.com/item?id=4065033 - June 2012 (2 comments) The Guide to Implementing 2D Platformers - https://news.ycom…

[flagged]
Post reply on HN