I could have, and I guess it would have made a little sense. But either way the result is the same--I'm checking whether or not the four tiles are grass.
PHP Code:
// NPC made by Dusty
if (mousedown) timeout=0.05;
if (timeout && leftmousebutton) {
grasstiles={0x0,0x1,0x10,0x1ff,0x3ff,0x7ff,0x835,0x836,0x837};
bushtiles={0x2,0x3,0x12,0x13};
ongrass=1;
for (i=0;i<4;i++) {
if (!(tiles[mousex-1+i%2,mousey-1+int(i/2)] in grasstiles)) ongrass=0;
}
if (ongrass==1) {
for (i=0;i<4;i++) tiles[mousex-1+i%2,mousey-1+int(i/2)]=bushtiles[i];
updateboard mousex-1,mousey-1,2,2;
}
timeout=0.05;
}
Also, I suppose the event && blah is just preference.