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 ME! WHAT DOES THIS MEAN AND HOW DO I FIX IT!?
By rory, with 5 replies.
Last reply by Yehuda, almost 8 years ago:
Are the "more errors" part of the same line of code? If yes, then say what they are. If you just have more errors in the project, then start a new discussion for the new topic.
Can't find method
By Nyoki, with 3 replies.
Last reply by Nyoki, almost 8 years ago:
ok! Thank you very much !
Change direction of an Actor
By L2plex, with 15 replies.
Last reply by CxVercility, almost 8 years ago:
danpost wrote...
CxVercility wrote...
Try this.getRotation() instead of just getRotation()
Makes no difference. The usage of 'this' in a non-static method is implicitly understood, if omitted.
thought so but i couldnt figure another error from the code by then :D
I have no clue where the error in the code is.
By rory, with 2 replies.
Last reply by danpost, almost 8 years ago:
And line 15 should be placed outside the act method.
A little question about BufferedImages
By TheStrangeOne, with 4 replies.
Last reply by CxVercility, almost 8 years ago:
danpost wrote...
CxVercility wrote...
Why is it i%size once and i/size the other time o.o
Because one, i%size, goes from 0 to 3 four times as 'i' goes from 0 to 8 and after every 4 values of 'i' the other one, i/size, increments by one. The values for (i%size, i/size) as i goes from 0 to 14, in order, are (0, 0), (1, 0), (2, 0), (3, 0), (0, 1), (1, 1), (2, 1), (3, 1), (0, 2), (1, 2), (2, 2), (3, 2), (0, 3), (1, 3) and (2, 3).
Damn, thats smart.
Help with ending my game
By rory, with 3 replies.
Last reply by Super_Hippo, almost 8 years ago:
<Code Omitted>
Sprite
By destroyer9909, with no replies.
Does anyone know where to download a cartoon shooter walking animation picture by picture sprite? All i came across was that you have to pay for it does anyone have for free?
Restarting current level
By Paul12345, with 2 replies.
Last reply by Paul12345, almost 8 years ago:
Thank you very much !
cheat code
By destroyer9909, with 22 replies.
Last reply by danpost, almost 8 years ago:
destroyer9909 wrote...
it still doesnt work
You placed your line 5 incorrectly. It is not a field, but a local variable. Move it, without the access modifier, into the act method (as first line).
Creating ScoreCounter
By Fizzy, with 3 replies.
Last reply by danpost, almost 8 years ago:
Fizzy wrote...
I tried many things, but the problem was, I had no act() but Score() in code.
The Score class does not require an act method. There is nothing it will do on its own -- only when the score is actually changing (which is completely taken care of in the 'addScore' method.
Wrong method behavior
By ImAndrew, with 4 replies.
Last reply by CxVercility, almost 8 years ago:
Your code is super confusing Why is it called Hero.getAttacked when he is the one attacking lol Also, shouldn't dx/dy be smaller than your max attack range? Besides that, as Dan already said you need a reference to the enemy being attacked to do something on that object only. One way would be to use a method in the enemy class that checks if the projectile hits them and then do something
Displaying text for a story game.
By Shadow, with 1 reply.
Replied to by danpost, almost 8 years ago:
You cannot be the Shadow, because "The Shadow knows." LOL By keeping the text and the message board separate, it is easy to change the text. The text can be an Actor object that is assigned various GreenfootImage objects containing the appropriate texts at the appropriate times.
Coming back to java
By wabuilderman, with 3 replies.
Last reply by danpost, almost 8 years ago:
wabuilderman wrote...
Yep... forgot the 1 in there... XD Funny how much one character can affect meaning....
One character can change everything (especially with coding).
Keep actors
By Chepaci, with 4 replies.
Last reply by Chepaci, almost 8 years ago:
oh, i don't know what i did, but it keeps everything thx bro.
Please help!
By agray11202, with 5 replies.
Last reply by xbLank, almost 8 years ago:
Line 13: 35 and 765 is refering to the range in which the mobs should spawn (on the y axis) in the world (my world is 1000x800 cells big). 999 (on the y axis) basically means that they should spawn on the very right end of my world.
294
295
296
297
298
299
300
X