Hi,
At the moment i can add an actor with the "1" key and remove it with "2".
I was wondering if i can open and close it with the same button, because with 2 it gets annoying fast. Is this possible and if so, how?
Thanks
if (Greenfoot.isKeyDown("1")) { addObject(screen, 450, 450); } if (Greenfoot.isKeyDown("2")) { removeObject(screen); }