/// <summary> /// 构造函数 /// </summary> /// <param name="x"></param> /// <param name="y"></param> /// <param name="width"></param> /// <param name="height"></param> /// <param name="speed"></param> /// <param name="life"></param> /// <param name="dir"></param> public GameObject(int x, int y, int width, int height, int speed, int life, Diretion dir) { this.X = x; this.Y = y; this.Width = width; this.Height = height; this.Speed = speed; this.Life = life; this.Dir = dir; }
public Snake(Graphics graphics, int size, int width, int height, Color bodyColor) { this._headDiretion = Diretion.right; this._size = size; this._graphics = graphics; this._headNode.Position = new Point(0, 0); this._width = width; this._height = height; this.BodyColor = bodyColor; }
public PlaneFather(int x, int y, Image img, int speed, int life, Diretion dir) : base(x, y, img.Width, img.Height, speed, life, dir) { this.imgPlane = img; }
public PlaneHero(int x, int y, int speed, int life, Diretion dir) : base(x, y, imgPlane, speed, life, dir) { }