Skip to content

Instantly share code, notes, and snippets.

def move_to(x, y):
size = get_world_size()
ax = (x + size - get_pos_x()) % size
ay = (y + size - get_pos_y()) % size
if ax < size / 2:
dx = East
else:
dx = West