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
remove all actors of one kind
By ZigZagNinja, with 5 replies.
Last reply by ZigZagNinja, almost 9 years ago:
doesnt matter i got it to work thanks for the help
Struggling to get Greenfoot.mouseClicked() to work
By arkod86, with 4 replies.
Last reply by danpost, almost 9 years ago:
arkod86 wrote...
The check should be done on the Food class?
Actually, and I fell victim to this above (after seeing your code and not realizing the problem), the check is done on a specific object -- not a class at all. However, with the following, your check could be done anywhere: <Code Omitted>Anywhere, provided the check is repeatedly performed (like from within an act method). The check will be 'true' any time any Food actor is clicked
Developing Greenfoot with any IDE using Maven
By lerk, with 4 replies.
Last reply by lerk, almost 9 years ago:
Still I believe developing Greenfoot games with IntelliJ is way more fun. And this Maven based workflow saves a lot of headache.
Exporting a Actor Class in Greenfoot
By wueschn, with 2 replies.
Last reply by wueschn, almost 9 years ago:
Thanks a lot Super_Hippa
Or you copy the files of the class from your project and paste it into Greenfoot>lib>greenfoot>common folder where the other classes are which you can import
This works fine, thanks!
Timer every 5 seconds something spawns
By ZigZagNinja, with 6 replies.
Last reply by ZigZagNinja, almost 9 years ago:
OK thanks you very much it works now
my code is not working...help?
By daverider05@gmail.com, with 4 replies.
Last reply by danpost, almost 9 years ago:
daverider05@gmail.com wrote...
its telling me "reached end of file while pursing"
You probably just need another closing bracket at the end of the class.
How to restrict character on top of screen while jumping?
By shantanu28, with 1 reply.
Replied to by danpost, almost 9 years ago:
shantanu28 wrote...
I have made a character who has the power to fly. But I am not able to restrict him to the screen. While flying it goes beyond the screen
Normally the following alone after the movement code would be enough: <Code Omitted>
class or method
By divinity, with 44 replies.
Last reply by divinity, almost 9 years ago:
IHi danpost and super_hippo I got it. I change the doublearea(1, 2, 3) to doublearea(A, B,C) the value that is being collected thank you guys for all of the help
Spawner
By Djolex, with 1 reply.
Replied to by danpost, almost 9 years ago:
Djolex wrote...
i want to learn spawner command i am beaginer and my Eanglish is bad i am from Serbia i am bad and i want to learn Java in greenfoot!
Manually spawn an object (right click on Actor subclass and select 'new ...'); next, save the world (use menubar: Controls >> Save the World). Then, look at the code in the 'prepare' method that was generated. It will show the kind of code required to spawn an actor into your world.
Hello
By asacool, with 2 replies.
Last reply by Djolex, almost 9 years ago:
Welcom friend i am new too i dont learn English a lot and my English is bad Welcom bro
Resize lock
By Kagz, with 1 reply.
Replied to by danpost, almost 9 years ago:
Kagz wrote...
when I place the actor into the world it is the correct size however when I press run it returns to its original size, how would I get him to stay the intended size after running the scenario?
We will need to see the entire class code (1) to see where the given code is located; and (2) to see if anything else is causing the issue.
Help! Can't display a message
By twistedninja42, with 3 replies.
Last reply by danpost, almost 9 years ago:
twistedninja42 wrote...
Well how exactly would I display a message? There's no "displayMessage", I don't think
Create a subclass of Actor for the game over object. Add a constructor to create the image with text required. Have the 'gotWinner' create an object from the class and add it into the world.
New version
By jacquelinereilly, with 4 replies.
Last reply by jacquelinereilly, almost 9 years ago:
Fixed it! Thank you. I actually like the new version better. Thank you
Problem with positioning
By diablo95, with 1 reply.
Replied to by danpost, almost 9 years ago:
On line 56, change '500' to '300'.
Issue with changing images.
By Beamo, with 2 replies.
Last reply by danpost, almost 9 years ago:
The prroblem is that line 23 will always be true. The 'getObjects' method always returns a List object. You need to check the size of the list (or its state of being empty) not whether it exists or not.
317
318
319
320
321
322
323
X