咳……又是自己摸索……
3 H+ g7 l2 N, ]5 U3 Zsel = SwarmUtils.getSelector("FoodSpace", "seedFood");4 a' U, R# N% J! b. b. u, R
worldRaster.setButton$Client$Message(1, modelSwarm.getFood(), sel);
/ ?1 X% g; F8 R! D+ d! O" O4 o4 w7 A. J. A6 Q9 p1 ]1 t# X: D
其中FoodSpace的seedFood函数:* D* b% L0 R B. T" J
public Object seedFood(int x, int y) {
" s1 _8 x8 _2 ^ putValue$atX$Y(1, x, y);
/ t: _/ q& W7 j8 w8 x! y* ~ return this;9 N, i# V5 M6 e
} |