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
Call an object's method
By Aniveal, with 3 replies.
Last reply by Aniveal, about 10 years ago:
Thanks for the replies! Adding the (Terrain) helped. @danpost: You are right, that's exactly what I wanted. I think I would have found that out after testing though ;)
Power up two adjacent bullets programming
By tisoc2009, with 5 replies.
Last reply by Super_Hippo, about 10 years ago:
If you show your code, it will be easier for us to help you.
changing text size in world
By FaintingSatyr, with 1 reply.
Replied to by danpost, about 10 years ago:
You cannot adjust the size of the text that 'showText' uses. You can have the keys place its keyboard key value on themselves within the constructor of the Key class. There, you can create an image with text of any size and draw it onto the image of the key. You would be creating an object of and using methods of the GreenfootImage class (see documentation).
Help With mouseClicked
By AAkira, with 8 replies.
Last reply by danpost, about 10 years ago:
Okay, that eliminates one possibility. Now, post your entire Property class.
Making objects stay on top of other objects
By ymym, with 3 replies.
Last reply by Super_Hippo, about 10 years ago:
It should be 'direction' and not 'dir' in all cases in the act-method. Looks like I messed this up.
Two Enemies that follow error.
By Samas, with 4 replies.
Last reply by Samas, about 10 years ago:
Thank you!
Null Pointer Exception
By ymym, with 3 replies.
Last reply by danpost, about 10 years ago:
ymym wrote...
could you explain why 'getWorld' returns 'null' when 'this' is removed though? I'm fairly new to Greenfoot.
When you remove 'this' from the world, then 'this' will not be in any world. Therefore, calling 'getWorld' on 'this' actor will return the world that actor is in. If it is not currently in any world, 'null' is returned. Maybe it would help to explain that: <Code Omitted>is equivalent to: <Code Omitted>So, if 'this' is removed from the world, 'this.getWorld', which returns the world the actor is in, cannot
Player onstantly adding without eating and help with other ideas
By Boboy18, with 21 replies.
Last reply by Boboy18, about 10 years ago:
Great again it all works. Thanks again. I'm trying to work on 'lives' for the user. I will ask if there is any problems. ;)
Help with animating this boney guy.
By shloid, with 5 replies.
Last reply by danpost, about 10 years ago:
shloid wrote...
Oops I apologize I did not see the link on "Animated Character" hahaha. But thank you in advance.
I was looking over the code of the Animated Character scenario. It may be a bit complicated to understand. However, the main thing is that the parts be controlled together from one set of code. They should not be controlled independently. This means the code should be located in a class where only one instance is created. Unfortunately, that would exclude your Boss class as all objects of its subclasses are also considered Boss objects. Actually, it was incorrect for yo
Non static method (getHealthBar)
By MaxAaldering, with 5 replies.
Last reply by Super_Hippo, about 10 years ago:
Java is case sensitive. Danpost didn't only remove the 'new'. And as I already said, you have to use 'myworld' instead of 'MyWorld' or you just use this line as line 16 and remove lines 6 through 8: <Code Omitted>
Dragging objects with mouse in-game
By Octavius, with 1 reply.
Replied to by danpost, about 10 years ago:
Dragging, in game, is as simple as: <Code Omitted>You could act on the selection immediately, but probably better is to have a button to
Need help with a Slow Time Power up.
By Samas, with 8 replies.
Last reply by Samas, about 10 years ago:
Thank you so much! it worked perfectly!
Problem with jar file
By Green1604, with 1 reply.
Replied to by Green1604, about 10 years ago:
And please ignore the images =)
Help With Method
By AAkira, with 16 replies.
Last reply by AAkira, about 10 years ago:
ahh i got it now, it works perfectly but i need change every function that create a new LoserWorld, thank you Super_Hippo and danpost
Animating a Button
By Yakman3, with 4 replies.
Last reply by Yakman3, about 10 years ago:
That worked perfectly! Thanks so much!
442
443
444
445
446
447
448
X