贪吃蛇小项目
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace 贪吃蛇
|
||||
{
|
||||
abstract class GameObject : IDraw
|
||||
{
|
||||
//当前位置
|
||||
public Position pos;
|
||||
|
||||
//绘制对象
|
||||
//可以继承接口后,把接口中的方法变成抽象方法,让子类去实现
|
||||
//因为时抽象行为,所以子类必须实现
|
||||
public abstract void Draw();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user