public static List <GridPos> TransformOccupiedPositions(GridPosR localGridPos, List <GridPos> ori_OccupiedPositions) { List <GridPos> resGP = new List <GridPos>(); foreach (GridPos oriGP in ori_OccupiedPositions) { GridPos temp_rot = GridPos.RotateGridPos(oriGP, localGridPos.orientation); GridPos final = temp_rot + (GridPos)localGridPos; resGP.Add(final); } return(resGP); }
public bool Equals(GridPosR gp) { return(gp.x == x && gp.z == z && gp.orientation == orientation); }
public bool Equals(GridPosR r) { return(r.x == x && r.z == z); }