update to use square.pos.x instead of x_pos