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
HELP! Confused on how to continue. if/then react to user input
By Stillinski24, with 10 replies.
Last reply by Stillinski24, over 9 years ago:
Thank you so much @danpost and @Super_Hippo my code worked!
Platforms
By colinj, with 2 replies.
Last reply by danpost, over 9 years ago:
The code given above does not give the behavior you were wanting. However, using the same added field, you can replace lines 28 through 32 with this to get the desired behavior: <Code Omitted>
why calculator is not working
By divinity, with 15 replies.
Last reply by danpost, over 9 years ago:
divinity wrote...
i m trying to follow your direction on the greenfoot thing and it is giving me an error access denied.
You need to more specific in what you are attempting to do and what you are doing when you get the error and copy/pasting the entire output of the error message.
Fading Starting Screen
By Hondrok, with 6 replies.
Last reply by danpost, over 9 years ago:
The transparency of an image is given in int values. This means that if you wish to fade back in as slowly as you are doing here, then 'fade' in line 13 will need to be converted to an 'int' value. I cannot say why you added the 'if' statement to the code as the Start_scr_a object would either be placed into a world because of that condition or automatically. Also, using a 'while' loop is not going to accomplish what you want as it is ran completely (in a single execution of act) before any screen updates -- lines 11 through 15 ( with 'fade' in line 13 corrected to '(int)fade' ) would be eq
Touching of two objects.
By PenguinPower, with 2 replies.
Last reply by PenguinPower, over 9 years ago:
Thank you so much :)
Problem with adding objects
By cooknj, with 1 reply.
Replied to by Super_Hippo, over 9 years ago:
Try to use this instead of the current lines 11-16. <Code Omitted>
bad operand type for binary operator
By divinity, with 2 replies.
Last reply by divinity, over 9 years ago:
thank u super_hippo and happy new year to you and yours
Divide by Zero Errors
By Theangryman, with 3 replies.
Last reply by Theangryman, over 9 years ago:
@Super_Hippo I tried out your method and it worked, thanks. @danpost Yeah, I understand what it is you're getting at, I had troubles using 120 as the max value when the length of the bar was 320 due to rounding errors, so instead I'm just gonna fudge it (read: be lazy) and make sure all the values I use are factors of 300 for the bar length and bar segment length.
Multiple Rock objects are created
By Salamander, with 7 replies.
Last reply by Salamander, over 9 years ago:
Thank both of you so much. All the errors are fixed and I am very grateful. I also appreciate how both of you have taken so much time to help us programming noobs with our problems. I tip my cap to both of you.
Numbers being pressed in order
By new113, with 2 replies.
Last reply by new113, over 9 years ago:
Thanks for your help
Collision Detection
By BrownDwarf, with 1 reply.
Replied to by danpost, over 9 years ago:
There are countless discussions on this issue. You can search for them by entering key words in the search field above ("platform collision" might get you somewhere).
2 Player Scoreboard
By Ryanmoss139, with 3 replies.
Last reply by Ryanmoss139, over 9 years ago:
I will check out the tutorial and have a go at writing the code for one. I have now deleted the code that i wrote but if I run into further troubles I will let you guys know. I am writing the code now so I may return for help in an hour or so if you guys are around then. Thanks for the help!
Scored board java.lang.null error help URGENT!
By teruc2, with 1 reply.
Replied to by Super_Hippo, over 9 years ago:
Show your 'MyWorld' code.
Issues with Fullscreen and creating worlds.
By ArchMageGaming, with 4 replies.
Last reply by Nosson1459, over 9 years ago:
danpost wrote...
I tried a copy of a scenario with it. I had no keyboard or mouse controls that previously worked with the scenario and had no file or desktop controls to work with -- could only break out of full screen by calling task manager.
I tried it and everything PRETTY MUCH worked, they just weren't as accurate. As for breaking out of full screen Gevater_Tod4711 said to use Alt + Tab, but that's also a window key shortcut and doesn't actually close the window rather it switches it to the regular Greenfoot window with the full screen window minimized. (The shortcut is used for s
Changing image when it collides
By Hondrok, with 13 replies.
Last reply by danpost, over 9 years ago:
Hondrok wrote...
I don't understand the "if (! getWorld().getObjects(GameOver.class).isEmpty()) return; " thing what it does?
It basically says to exit the method (do not have the actor do anything) if a GameOver object is in the world. If execution of the code in the act was to continue, then lines like 45, 50, 108 and 114 would undo the setting of the death image.
408
409
410
411
412
413
414
X