technique
Represent obstacles as a 2D boolean array (true = blocked) and a player's position as a row/column index.
Also called: boolean obstacle grid · tile-based collision
Revision 1 · 1 source · Something wrong? Tell us.