请帮帮忙。。。。
我有个数组的问题问你,我看别人的源代码有这样一段
第一帧
my = new Array(0, 0, 0, 0, 0);
my[0] = new Array(0, 0, 0, 0, 0);
my[1] = new Array(0, 0, 0, 0, 0);
my[2] = new Array(0, 0, 0, 0, 0);
my[3] = new Array(0, 0, 0, 0, 0);
my[4] = new Array(0, 0, 0, 0, 0);
my[1][4] = 1;
my[2][4] = 1;
第二帧是界面
这是个华容道的游戏 它的操作是每个棋子分上 下 左 右 点击其区域便向其对应的方向走,
其中曹操的右按钮上是
on (release) {
ycc = getProperty("_root.caocao", _y);
xcc = getProperty("_root.caocao", _x);
x = int((xcc-170)/70);
y = int((ycc-120)/70);
if (xcc<310 and _root.my[x+2][y] == 1 and _root.my[x+2][y+1] == 1) {
setProperty ("_root.caocao", _x, xcc+70);
_root.my[x+2][y] = 0;
_root.my[x+2][y+1] = 0;
_root.my[x][y] = 1;
_root.my[x][y+1] = 1;
if (x == 0 and y == 3) {
gotoAndPlay ("win");
}
}
}
我不明白曹操按钮上my[x+2][y] == 1 my[x+2][y+1] == 1
及_root.my[x+2][y] = 0;
_root.my[x+2][y+1] = 0;
_root.my[x][y] = 1;
_root.my[x][y+1] = 1;
的意思
还有第一帧的my[1][4] = 1;
my[2][4] = 1;