Hey everyone,
I've been using the getKey method a lot and I know that it only returns anything since the last time the method was called, but it is a bit frustrating that it carries between classes...
If I call the getKey method in my World subclass and simultaneously in any Actor subclass, only the most recent one to execute will return. I've tried putting the method in private voids, protected voids, I even tried making this:so I could have only the one method calling the getKey function where all my classes could access the output of it and that didn't even work...
Any suggestions/solutions?
Thanks
class myWorld()
{
public String lastKey = "";
private void returnKey()
{
lastKey = Greenfoot.getKey();
}
public void act()
{
returnKey();
}
}

