public Point1 GetNextPoint() { Point1 head = pList.Last(); Point1 nextPoint = new Point1(head); nextPoint.Move(1, direction); return(nextPoint); }
public Snake(Point1 tail, int length, Direction _direction) { direction = _direction; pList = new List <Point1>(); for (int i = 0; i < length; i++) { Point1 p = new Point1(tail); p.Move(i, direction); pList.Add(p); } }