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
I will post A game in between this april and may
By sashvanth, with no replies.
planning to cretae a pioano
Problem
By ADAM68801, with 1 reply.
Replied to by Super_Hippo, over 2 years ago:
Use a variable and set it to two. Upon hit, instead of removing the actor, decrease the value by one and check if it reached zero and remove the actors then.
Actors (graphics) only show up when the game gets to the end, instead of during
By newgfteacher, with 4 replies.
Last reply by newgfteacher, over 2 years ago:
RcCookie wrote...
You can use getWorld().repaint() to force repaining, or only make one input request per act cycle. Greenfoot only renders the world after the frame, so no blocking actions should be used.
Finally got my head around the act thing and it is working! Thank you!!
danpost wrote...
newgfteacher wrote...
The graphics should be showing up after each guess has been entered by the user (using Greenfoot.ask).
If I were to do a
Wordle
game (which I have a non-uploaded test scenario using 2 different words and no dictionary to check word entries), I would not use the
when i add more than 1 enemy, the new one despawns
By Aaron-aid, with 3 replies.
Last reply by Aaron-aid, over 2 years ago:
holy crap im so stupid, thx man
simple implement that my game stops after some timer
By Flipper3000, with 4 replies.
Last reply by Aaron-aid, over 2 years ago:
Aaron-aid wrote...
do you want to stop the program or change the scene to say they failed a mission? because you can change scenes by doing Greenfoot. int def_Val = 20; int timer = def_Val; act(){ timer--; if(timer <= 0) { Greenfoot.setWorld(new newWorld();) timer = def_Val; }
ignore this, the second one is right
Problem in importing Socket class
By Roshan123, with 2 replies.
Last reply by Roshan123, over 2 years ago:
Oh, ok. Thanks for the answer. To be honest I thought its a problem in my editor
Medical Office Management (aka MOM), what is wrong
By divinity, with no replies.
I know you all must be tired of me but anyways, I have this programme that I have build but it is not running as it should. It is called Medical Office Management where I have to used inheritance. I build the proram but something is deffinite;ly wrong, when I try to run it gave nothing, just blank and it keep running. the part of the program is working is the exit part. I am going to post all of the classes here so that you guys can take a look through my codes and tell me what is wrong and why it is not working properly. here are the classes. first one is the date the employee should be able to do this: A class variable which stores the number of patients noPat ii. Instance variables patID, first name, last name, phone number, date of birth (Date) and balance, which is used to keep track of any outstanding monies due by the patient. the patient class should be able to do this; A class variable which stores the number of patients noPat ii. Instance variables patID, first name, last name, phone number, date of birth (Date) and balance, which is used to keep track of any outstanding monies due by the patient Date class <Code Omitted> the employee class <Code Omitted> the patient class <Code Omitted> the person class (this class has a specification where u have to put a count (initialize to 0) and a company name of your choice. The person class <Code Omitted> The main class which is used to run the program, it is call MOM, short for Medical Office Management the main menu <Code Omitted> can someone tell me where i have gone wrong, why it is not working properly. can u gave me some ideas and how to fix it
Hello, i need help with my dialog class.
By Focused, with 6 replies.
Last reply by Focused, over 2 years ago:
Thanks RcCookie and Super_Hippo for the help. I appreciate it. It works perfectly now! Firstly, just the first and second string of the dialog showed up. So I changed the isKeyDown method to getKey. Also i checked the length of array, so no arrayoutofBoundserror. The dialog gets removed from the world after last string. That text String works also now. It works perfectly fine now!
Hi, need help with Error & logic
By PastorI, with 1 reply.
Replied to by Super_Hippo, over 2 years ago:
The code looks really messy, but the error comes because you remove the actor from the world (line 90 in GameSquare) and then proceed to continue calling getX and other methods on it. Some comments are also simply wrong. For example the comment regarding the keyword static. “static” has nothing to do with being a constant or unable to change. That’s what “final” is doing. Question: Why do you want to remove both GameSquares and add a new one in the same location? You could just remove one and keep the other. After you change the value, you only need to call the displayValue method, so the im
Please help,,is there a way to make this program work?
By syahwa_anugrah_ainu, with 2 replies.
Last reply by syahwa_anugrah_ainu, over 2 years ago:
thanks for the information bro
Turn towards an actor without using turnTowards
By PandaBear1911, with 2 replies.
Last reply by PandaBear1911, over 2 years ago:
Yeah my teacher wants me to do that without using this method. Then I'll just try to solve that with "manual" trigonometry, thanks.
Change the font of my text
By TheMuncher, with 3 replies.
Last reply by TheMuncher, over 2 years ago:
Thanks Roshan123
Error java.lang.NullPointerException
By Slimey, with 11 replies.
Last reply by Slimey, over 2 years ago:
Now it is saying non-static method takeDamage() cannot be referenced from a static context
How to flip an image when border is reached?
By Yaren, with 10 replies.
Last reply by danpost, over 2 years ago:
Best is probably to retain both images (non-mirrored and mirrored) in fields:
Spawning a raining of bombs
By jdkdoen05, with 12 replies.
Last reply by danpost, over 2 years ago:
jdkdoen05 wrote...
a second problem is that the game ends if the bomb is spawned in the world. I have no idea why this is because there is nothing written about it anywhere
Only time a game will end (exit a running state) is (1) an error occurred, in which case you will get some type of error message in the terminal console; or (2) a "Greenfoot.stop();" command was encountered.
37
38
39
40
41
42
43
X