package tris func (p Placement) Move(f Field, rot Rotation, x, y int) (np Placement, floor, topout bool) { np = p np.Rot = rot np.X = x np.Y = y if !np.Collide(f) { // free air return np, false, false } np = p // last resort reset p fp := np fp.Y++ if fp.Collide(f) && np.Y < 0 { return np, true, true } return np, fp.Collide(f), false }