111,129
社区成员
发帖
与我相关
我的任务
分享
public Opponent(Location myLocation)
{
this.myLocation = myLocation;
myRandomizer = new Random();
}
public partial class Form1 : Form
{
Opponent player;//player对象
public Form1()
{
InitializeComponent();
CreateObject();
player = new Opponent(frontYard);//实例化
}
private void CreateObject()
{
//player = new Opponent(frontYard);//为什么在这里不行?
}
}
