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
Need a solution to inefficient code
By Andrew0739, with 2 replies.
Last reply by Andrew0739, over 7 years ago:
ok really? thanks!
problem with preventing player from moving if touching an object
By Andrew0739, with 3 replies.
Last reply by Andrew0739, over 7 years ago:
Oh, ok. I have made those change. Thanks. Also i found a solution.
Struggling with accessing variable from another class & world
By Kang, with 4 replies.
Last reply by Kang, over 7 years ago:
danpost wrote...
Remove "int" from line 4 and your getMutation method should only have the following one line: <Code Omitted>
Seems like it worked. Thx a lot : )
Giving an error
By Multisciente, with 1 reply.
Replied to by danpost, over 7 years ago:
Multisciente wrote...
<< Code Omitted >> This is giving error in ".WHITE". How to straighten?
Remove line 2.
How do I spawn an actor that has a reference to another actor
By BlueSnake, with 1 reply.
Replied to by danpost, over 7 years ago:
In line 4, you assign a
Class
type object to a field called
object
. A class is not a bullet, so you cannot assign
object
(containing a Class object) to a field that is to retain a
Bullet
object. Other issues include: * the variable called counter (at line 6) is not used anywhere; so that line is as if not there; * the Bullet constructor Counter parameter is not dealt with in the constructor, so it is as if you passed nothing; I will presume you want to create a new bullet and pass it the
Counter
object. You will need to show the code of the cla
having trouble understanding randomAsteroid()
By lprasgla, with 1 reply.
Replied to by danpost, over 7 years ago:
lprasgla wrote...
why do I have to mention the class in Asteroid.anz++? When I delete "Asteroid" from the line the code works but I get multiple asteroids in the universe. And when it is there, there's only one asteroid. Why is it like this? :)
You will need to show the code about which the method is called and indicate what class that code is in.
Need a little help with turning my image
By JoRt, with 9 replies.
Last reply by danpost, over 7 years ago:
You need to split line 94 up into individual lines so that you can make a reference variable to the new world: <Code Omitted>Now you can add to this to add the actor where it is in "this" world: <Code Omitted>It seems to me like all you really needed to do, instead of creating a whole new world, was to use a field to indicate the level and do things based on its value.
Problems with playing a different sound for different keys
By n1ght5t41xX, with 5 replies.
Last reply by n1ght5t41xX, over 7 years ago:
//PROBLEM SOLVED I managed to abstract the keys. Thank you all.
Sounds folder will not copy in book scenarios
By rhussainmenorah, with no replies.
I am unable to copy the sounds folders due to permissions in the book scenarios. Other folders seems to copy OK. I am able to copy extracted folder to the shared area but cannot copy it to student folders. Please help. Thank you.
missing buttons under "Share"
By Yogi64, with 1 reply.
Replied to by nccb, over 7 years ago:
How far can you get in the process? There should be a "Share..." button in the top-right. When you click that button, a window should show with three pictures across the top, which are tabs for the different export options. Is the problem that the window doesn't show, or that it's blank when it does show, or that some of the controls are then disabled or unresponsive?
greenfoot
By UyenTran, with no replies.
3. show the name and the values of the above four variables at the lower left corner of the screen using four lines of text. The sequence of the text follows the sequence shown in the requirement above
Bullet doesn't remove itself at a wall
By SemH., with 2 replies.
Last reply by SemH., over 7 years ago:
Thanks! It worked :)
Greenfoot.ask showing up before the world
By Kang, with 1 reply.
Replied to by danpost, over 7 years ago:
Kang wrote...
<< Code Omitted >> What I expect is after pressing enter from the start world, the set up world will show up and do Greenfoot.Ask but what actually happens is when I press enter form the start world, it does greenfoot.ask first then changes to set up world. Any solution for this?
You will probably have to override the
World
act
method in the
PredatorPopulation
class to perform the "ask".
Weird error
By R0b1n, with 1 reply.
Replied to by danpost, over 7 years ago:
I think lines 5 through 8 in the
gameOver
method need to be put in the following
if
block: <Code Omitted>
Scoreboard not working
By R0b1n, with 1 reply.
Replied to by danpost, over 7 years ago:
You have stuff inside the
canSee
if
block in the working one that is outside in the not working one.
206
207
208
209
210
211
212
X