This site requires JavaScript, please enable it in your browser!
Greenfoot
Username
Password
Remember Me?
Sign Up, Lost Password
Activity
About
Documentation
Download
Discuss
Scenarios
Discussions
You need to login to take part
Current Discussions
why does my for-loop create only one object instead of three?
By Joep, with 2 replies.
Last reply by davmac, over 13 years ago:
You create one new spider on line 9: Enemy spider = new Spider(); Then you have a for loop which attempts to add the spider to the world. But if you add an object into the world when that object is already in the world, it has no effect (other than maybe moving the object). You need to put the above line inside the for-loop body.
Pass in a class as a parameter?
By BubbaB, with 1 reply.
Replied to by danpost, over 13 years ago:
I would like to see the block of code that calls this method (the one with 'createObject(c, x, y);').
How to do you declare variable?
By gquach, with 7 replies.
Last reply by danpost, over 13 years ago:
Yes. Similarly, the same are <Code Omitted>But I guess this would mean you barfed it back up!
isKeyDown problem
By Game/maniac, with 10 replies.
Last reply by Game/maniac, over 13 years ago:
thanks :)
Life problems...
By JetLennit, with 19 replies.
Last reply by danpost, over 13 years ago:
I think you will still have to remove aliens from the contactedAliens list when they no longer show up in the currentContacts list. If you do not, then when you contact that alien at a future time, it will not do any 'damage'.
How check if a specific object is still in the world ?
By TomazVDSN, with 4 replies.
Last reply by JetLennit, over 13 years ago:
I know!! This place is the best!
CHALLENGE 1 | APRIL 2013
By Game/maniac, with no replies.
There are no prizes this is just for fun!
I will post a poll scenario at the end of the month, good luck!
Rules
-Do not copy anyone else's scenarios -You are allowed to use the discussion area to get help for your code -You are allowed to use code from demo scenarios, but you have to give credit to however made the demo -You can work in a group but the usernames of the members of the group have to be included in the description -You must include the source code -You must use the Challenge ID as a tag for you scenario -You can do whatever you want with the scenario as long as it does what the challenge asks for -You can enter more than one challenge but only one of your challenges can win -You are not allowed to ask people to vote for your scenario
Beginner
Challenge ID
C1BA13
Challenge Description
Create a game which allows you to fire a projectile that destroys enemies that spawn randomly, you must be able to transform(e.g.move, rotate) the object firing the projectiles.
Intermediate
Challenge ID
C1IA13
Challenge Description
Create a game which has randomly generated obstacles and hazards that could kill you, there has to be a scoring system and an end goal, the game must also have a menu.
Expert
Challenge ID
C1EA13
Challenge Description
You must create a scrolling puzzle game that has a scoring system, a menu, an end goal, a working score board, and multiple levels.
How to access one class's rotation from another class
By JetLennit, with 24 replies.
Last reply by danpost, over 13 years ago:
<Code Omitted>
Help with physics
By henrYoda, with 2 replies.
Last reply by henrYoda, over 13 years ago:
I think the problem is that I didn't use things like cos and sin, but I just don't understand how they work. Could someone (If you can) please correct my physics, using cos and sin, and explain to me what is happening? I really just don't understand physics, what I did above was kinda random
How to select a random part of an array list
By JetLennit, with 21 replies.
Last reply by Game/maniac, over 13 years ago:
Didn't notice that, thanks danpost
Writing a text file
By Ragtime, with 12 replies.
Last reply by Ragtime, over 13 years ago:
That was it :) thanks.
Minimize code
By JetLennit, with 21 replies.
Last reply by JetLennit, over 13 years ago:
and its a lot faster now
How to start a collection
By JetLennit, with 2 replies.
Last reply by JetLennit, over 13 years ago:
I see it.. thank you! (Sorry i didn't reply for a while... i was holding the little guy in my profile picture)
Problem with Greenfoot
By monfortpie, with 5 replies.
Last reply by allekalle, over 13 years ago:
I have the same problem, the folders keep saying that they are not writable, but I can“t change it. But only with Greenfoot is this a problem. I cannot make a new scenario with a new name with greenfoot.
defining the sides of an object
By welleid, with 5 replies.
Last reply by danpost, over 13 years ago:
You left the condition open in line 8. Your condition (as it is right now) states that if the bloc is anywhere to the left of the ball or if the bloc is anywhere to the right of the ball then such-n-such. The only possibility that will allow execution to proceed to the 'else' part of the expression is if the ball and the block are exactly above or below one another.
865
866
867
868
869
870
871
X