Skip to content

CollisionStrategyNormal

object CollisionStrategyNormal : CollisionStrategy
Example
on_input<DeveloperCommandInput> { player ->
if (name != "north") return@on_input
val free = World.collisionView(player).canTraverse(player.tile4.tile, Direction.North, strategy = CollisionStrategyNormal)
player.message(if (free) "The way north is clear." else "Something blocks the way north.")
}
override fun canMove(
tileFlag: Int,
blockFlag: Int
): Boolean