This site requires JavaScript, please enable it in your browser!
Greenfoot back
Katht99
Katht99 wrote ...

2017/6/12

Hidden Object Game

Katht99 Katht99

2017/6/12

#
Hi, in my game I'm having trouble with switching scenes after all the objects on the object list have been clicked. When I try to run this code, after clicking all the objects, nothing happens. Am I doing this right?
public static int removed=4;
if(removed==1)
//each time an object is clicked then it removes the object and decrements the removed variable.
        {
            //code
        }
danpost danpost

2017/6/12

#
You will need to post a lot more code than that for anyone to get any understanding of what might be happening. At a minimum, provide info as to what is clickable (removable) and how they are creeated and added into the world and any and all codes that deals with the 'removed' field. Indicate where all related code is located (class and type of superclass -- Actor, World or Object).
You need to login to post a reply.