public void act() { if (Greenfoot.mouseClicked(this)) { MouseInfo mi = Greenfoot.getMouseInfo(); int x = (mi.getX()-30)/35; int y = (mi.getY()-30)/35; //map[y][x] = (map[y][x]+1)%2; setBackground(new GreenfootImage(images[map[y][x]])); //drawBinary(x, y); } }