Skip to content

1681-engine / index / bodyCollides

Function: bodyCollides() ​

ts
function bodyCollides(
   grid, 
   x, 
   y
): boolean;

Defined in: src/net/movement.ts:92

True if the body box centered at (x, y) overlaps a solid tile.

Parameters ​

ParameterType
gridCollisionGrid
xnumber
ynumber

Returns ​

boolean

Released under the MIT License.