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
Problem with removeObjects
By Turbo_Thorsten, with 9 replies.
Last reply by Turbo_Thorsten, almost 5 years ago:
danpost wrote...
Super_Hippo wrote...
You remove the actor from the world in line 32. After that, you call the nuke method (line 40). The actor isn’t in the world anymore, so line 57 will never execute.
Move line 32 to after line 46.
Thank you it works!
how do I call
By Gabe1098, with 3 replies.
Last reply by danpost, almost 5 years ago:
Gabe1098 wrote...
Thanks! but how do I do a public one?
Same way from within the class (for
this
one). That is, the above line is equivalent to: <Code Omitted>following the standard: <Code Omitted>where 'this' refers to the object the method is executing on (or for). Similar to the English grammar of a sentence -- subject followed by verb. From outside the class where the method is public, a reference to the object of the class the method is in is needed and must be explicitly given. For example:
How can name a certain object?
By Turbo_Thorsten, with 2 replies.
Last reply by Turbo_Thorsten, almost 5 years ago:
Gbasire wrote...
You can do this : in a world, for example MyWorld.class : <Code Omitted>and in an actor, for example Player.class : <Code Omitted>
Thank you!
Greenfoot 3.7.0 released
By nccb, with 2 replies.
Last reply by RcCookie, almost 5 years ago:
Also, what’s next planned for development?
how can i test for this scenerio
By tennis097, with 1 reply.
Replied to by danpost, almost 5 years ago:
If your world is bounded, then the greatest x is getWorld().getWidth()
-1
, and the greatest y is getWorld().getHeight()
-1
.
Index Out of Bounds Error
By Billykid679, with 2 replies.
Last reply by Billykid679, almost 5 years ago:
Thanks a lot, I was stuck trying to make it work in the bomb class when I could have just put it in the plane class like you said.
random direction
By pleasehelpwithmycodeyt, with 3 replies.
Last reply by danpost, almost 5 years ago:
Maybe: <Code Omitted>
How do you fix the size of the playing screen
By KylesGallery, with 2 replies.
Last reply by KylesGallery, almost 5 years ago:
thanks
Array images
By EndlessTimes, with 7 replies.
Last reply by danpost, almost 5 years ago:
You could do something like this (where the class of falling objects is called
Falling
and its
static
image array is called
imgSet
): <Code Omitted>
Gold shaking method
By pleasehelpwithmycodeyt, with 1 reply.
Replied to by danpost, almost 5 years ago:
Add an
int
timer field: <Code Omitted>Then use something like this: <Code Omitted>
Multiplayer Board Game
By 349592576, with 3 replies.
Last reply by danpost, almost 5 years ago:
349592576 wrote...
I'm planning on using the UserInfo scoring ability to assign every user a serial number
That sounds like overkill. Each user already has a unique name. Also, I think a better use of the score field would be to track who is playing who. That is, when two players start a game, take a unique game number and make it the score field for both players. That way, you can use
getNearby
to quickly find an opponent as well as for checking for unique game numbers.
SetPaintOrder
By BlueHand, with 1 reply.
Replied to by Roshan123, almost 5 years ago:
setPaintOrder(A.class, B.class, C.class) A will be above B and C B will be above C and below A C will be below A and B
Problem with an transaction arraylist
By divinity, with 60 replies.
Last reply by divinity, almost 5 years ago:
ok
How to get rid of text?
By BlueHand, with no replies.
Hello! I have an arraylist and constructor in my Questions class! There are five questions in the constructor. After I make one appear, how do I make the previous question disappear?<Code Omitted>
How to make a object do something when touching an other object?
By Ineedhelpthx, with 3 replies.
Last reply by Ineedhelpthx, almost 5 years ago:
thanks for the work man
67
68
69
70
71
72
73
X