RunFaps
shaunjs
shaunjs patreon

Tile Collisions - Prep Work & Code optimization

🕑 Added 2017-08-29 16:03:06 +0000 UTC
Tile Collisions - Prep Work & Code optimization

Comments

You can make the player hitbox bigger than a tile but it will create problems with certain shapes in your level. You can avoid these in level design but it's best just to keep your tile size larger than your player hitbox. The art can obviously be whatever. You can still make this method work for larger player hitboxes in all cases by checking more points (such as the "middle" of each edge.)

Raeldor

Looks a lot more complex than object collision but it's nice if its more efficient. The player object can be bigger than a tile though? Also, Would be wise to do 2 types of tile collision, for different sized terrain or different properties?


More Creators