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
Scenario becomes unstable when creating setWorld Variable
By DatHeroAndy, with 10 replies.
Last reply by danpost, almost 6 years ago:
danpost wrote...
You probably have two classes that unconditionally initiate one another (or multiple classes creating a loop of initiations).
I still think this is the issue.
Greenfoot set more images
By off.nika, with 10 replies.
Last reply by off.nika, almost 6 years ago:
THank you so so so so much. I finally understood and it works. Thank you
Multi-thread bugs
By RcCookie, with 1 reply.
Replied to by RcCookie, almost 6 years ago:
?
how can I add score to both characters?
By sxgdfhcjvk, with 2 replies.
Last reply by danpost, almost 6 years ago:
sxgdfhcjvk wrote...
so im making my own game now and I have to count score for both of the characters, does anyone know hot to do that?
This is vague, without any attempted codes. Also, are the scores to be displayed or not?
While loop
By Sauravbasyalking12, with 3 replies.
Last reply by danpost, almost 6 years ago:
Sauravbasyalking12 wrote...
Could you please name one thing that can go wrong with a while loop
One thing that can go wrong is that the condition to loop remains true indefinitely -- so, execution is "stuck" in the loop. It will make it seem the scenario is "frozen" as the process never completes.
Check if object exists at specific coordinate
By Suavessence, with 2 replies.
Last reply by Suavessence, almost 6 years ago:
That helps, thank you!
Help with Greenfoot.getKey()
By DatHeroAndy, with 5 replies.
Last reply by RcCookie, almost 6 years ago:
Sorry mate, didn’t test run it. Good that you figured out how to fix it
How can i spawn more and faster?
By ShortScream, with 1 reply.
Replied to by RcCookie, almost 6 years ago:
You can adjust the propability of objects spawning in line 10 by increasing 20, and you can decrease the maximum time between spawns in line 37 (what cache is set to)
How to Increase Speed Over Time
By CuzImMicah, with 13 replies.
Last reply by danpost, almost 6 years ago:
Remove line 48, as it will delay everything -- not just the Igl
o
o actor. You only need one control value for spawning strawberries -- not two ( "
i
" and "
whileOff
" ) -- keep '
i
': <Code Omitted>(the above to replace from line 27 to 48). Raise "
75
" in line 25 to something in the mid to high 90s.
How to add wait
By ShauryaThapan, with 3 replies.
Last reply by ShauryaThapan, almost 6 years ago:
Got it
Two players from the same keyboard
By WannaBeADeveloper, with 2 replies.
Last reply by danpost, almost 6 years ago:
WannaBeADeveloper wrote...
I tried to copy the same class and change the inputs from the pressKey but it didn't nothing..
It would be better to have just one class where the input key values are variable, using a constructor with input key parameters.
How can I access Methods from a subclass of World in an Actor class?
By Dev_grey97, with 3 replies.
Last reply by danpost, almost 6 years ago:
Dev_grey97 wrote...
could you please elaborate how I can add the actor to the world and how to use the method addedToWorld() ?
Show entire page of
MyWorld
class codes. Oh, line 3 above, given by me, is flawed. It should be: <Code Omitted>
Picture Switching Problem
By ItzLukeStorm, with 4 replies.
Last reply by ItzLukeStorm, almost 6 years ago:
Thanks so much. It worked!
Is the Greenfoot project alive?
By Rabestro, with 3 replies.
Last reply by Roshan123, almost 6 years ago:
And sorry becaz the reply has no relation to the topic
Complex numbers problem
By rhys, with 7 replies.
Last reply by danpost, almost 6 years ago:
Use class name (
ComplexNumber
) for
static
method calls. Use instance variable name for non-
static
method calls. The
mod
method is not
static
, therefore: <Code Omitted>If you had a
static mod
method (which you do not -- at least, I did not find one in the class), then you might have something like this: <Code Omitted>
110
111
112
113
114
115
116
X