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

2013/2/3

Is there a limit on how much stuff that can be put in a single Greenfoot game?

Gingervitis Gingervitis

2013/2/3

#
I have a lot of coding in my game and specific things that I used in the beginning of the game glitch later on and don't work properly.
Gevater_Tod4711 Gevater_Tod4711

2013/2/3

#
There are some limits in Greenfoot. If you want to upload your game it has to be smaller than 20MB. And if your game has to many classes it just doesn't work. But the limit of possible classes is very high I think. In my case it were about 120 classes when the game crashed.
Gingervitis Gingervitis

2013/2/3

#
Thank you. I don't have that many classes. I have about 20 classes. It turns out my error was that there were was a lot of coding. I put a semi colon in the wrong spot....
danpost danpost

2013/2/3

#
Without knowing what the glitches are, what action you are expecting, and without seeing ALL the code that is used dealing with the object(s) involved (from creation to destruction) from whatever classes are involved, it would be almost impossible to help you. As far as limits: as long as your game compiles and runs, you should be ok. However, if the file size of the scenario is too large, you will not be able to upload it onto the Greenfoot site. The only other problem you may have is lag (if you have an abundance of actors in the world at the same time -- meaning thousands).
Gingervitis Gingervitis

2013/2/3

#
I know about the lag and that was not my mistake. My mistake was that I put a semi colon in the wrong spot which kept executing the method over and over again. I originally that though it was because I had I lot of coding in one specific class. That I why I asked about how much stuff that can be put in a Greenfoot game. My game works perfectly now.... So far....
danpost danpost

2013/2/3

#
Glad to hear it!
Gingervitis Gingervitis

2013/2/3

#
I'm actually quite proud of the game I am making! I am not a programmer at all. I just learned basic Greenfoot in highschool a couple of weeks ago. I am just taking what I learned and I am experimenting. ( I also watched about 20 videos)
danpost danpost

2013/2/3

#
Have you seen the Java tutorials. The second section on the left named Trails Covering the Basics contains lots of useful information.
Gingervitis Gingervitis

2013/2/3

#
I have not seen that. I will definitely look at.
Gingervitis Gingervitis

2013/2/3

#
Is there a way I could have a still object move after it eats something? For example I want my rocket to stay still when it spawns, but when it eats my turtle, it will move vertically upward towards the top edge as if the turtle is riding the rocket.
Gingervitis Gingervitis

2013/2/3

#
public void act() 
    {
        ifCanSeeTurtle();
    }    
    
    public void ifCanSeeTurtle()
    {
        if (canSee(Turtle.class))
        {
            eat(Turtle.class);
            setImage("rocketCopy02.png");
            move(4);
        }
    }
this is what I have so far but it doesn't work
vonmeth vonmeth

2013/2/3

#
That will only move it once. You could checking if a boolean is true, and if it is, have it move(4). Have it change to true when it sees a turtle instead of having it move in the ifCanSeeTurtle method.
Gingervitis Gingervitis

2013/2/3

#
How exactly would I go about doing that? I don't really know about boolean statements...
danpost danpost

2013/2/3

#
Replied to in the 'Still and Moving Objects' discussion.
You need to login to post a reply.