Don't recalculate dir every time
constants in all caps, faces north when gets home
Start capturing the room size
Deal with size vs vector
Try to measure the x distance too
Save x
Wait if something (mob or player) blocks you