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
Scrolling text
By Bluetiger, with no replies.
Hello I am coding a game for my school and I would like to have text that types by itself and appears on the screen. Please help me
pythagoras tree
By ronald, with 8 replies.
Last reply by ronald, almost 7 years ago:
Thank you, I found the solution
constrcutor as an image (or whatever)
By joejoe, with 8 replies.
Last reply by joejoe, almost 7 years ago:
its finally working, thanks a lot. i'll let you know if i need anything. thanks again for your time :)
fractal Tree
By ronald, with 4 replies.
Last reply by ronald, almost 7 years ago:
thank you for the help
yin yang
By ronald, with 5 replies.
Last reply by ronald, almost 7 years ago:
thank you
Help
By Stives123, with 1 reply.
Replied to by danpost, almost 7 years ago:
Stives123 wrote...
i Dont know whats wrong with this code can any one help me << Code Omitted >>
There is nothing wrong with the given
Mover
class code. However, there are two requirements to using it;; (1) you need to have a compatible
Vector
class; and (2) you must have a world that is not bounded.
My images are larger than they are supposed to be. Also, using multidimensional arrays and for-loops to put actors into the world.
By 444Jam444, with 35 replies.
Last reply by 444Jam444, almost 7 years ago:
danpost wrote...
In your
MyWorld
class, remove the
main
method (lines 184 to 189).
This is more what I mean by 'updated'. Just small things. Removing unnecessary (unused) code, etc.
Scenario not showing properly when I share it here
By protocolUnknown, with 10 replies.
Last reply by protocolUnknown, almost 7 years ago:
Ah, thanks a ton. I didn't know that JS would play into this as a factor but now I know. The scenario is now working properly and is, in fact, more efficient because it isn't re-reading the txt file over and over again like it had to before.
Loading existing world instances?
By twinArmageddons, with 6 replies.
Last reply by twinArmageddons, almost 7 years ago:
this is awesome!! thank you so much!
User writing and making the character move
By Scarley, with 20 replies.
Last reply by Scarley, almost 7 years ago:
Well i tried with <Code Omitted> and its working perfectly, if only i could show like a list with what commands the user typed so he could know a little bit of the sintax to write a program , but its already good enough, thanks for the help
I need help with how to read a txt file in greenfoot
By protocolUnknown, with 5 replies.
Last reply by protocolUnknown, almost 7 years ago:
I was able to fix it by moving everything to the world class. I think the issue was something else and not with the txt file reading method I had. I was able to fix it though, so thank you
Understanding how to handle the game mechanics in which classes
By protocolUnknown, with 1 reply.
Replied to by danpost, almost 7 years ago:
protocolUnknown wrote...
Is the World class meant for just the initial setup of what the screen/level will look like and nothing else after that?
A class, whether
World
,
Actor
or any other, is a blueprint (or part of one) for a type of object. Its fields maintain the different states that its objects can have and its methods provide the behavior for its objects (things these type objects can do). For each object, its states can be change and its behaviors can be utilized throughout the object's life (or its existence -- until all references to that object are lost). I s
Problem using canSee method
By kml008, with 1 reply.
Replied to by danpost, almost 7 years ago:
kml008 wrote...
some time this method works and some time it doesnt
It will only work in an
Actor
subclass that extends the
Animal
class or one that has a
canSee
method within itself. As an alternative, you can use the
isTouching
method.
2D Array
By Fargesia, with 14 replies.
Last reply by Super_Hippo, almost 7 years ago:
Swap lines 16 and 17 in the unJoueur class. Or replace the class code with this: <Code Omitted>
getObjectsInRange does not work...
By Proprogrammer04, with 1 reply.
Replied to by danpost, almost 7 years ago:
Proprogrammer04 wrote...
<< Code Omitted >> It sais Always true, even if the Player is About 900 cells away from the object…
It should be obvious as to why it always says "true".
170
171
172
173
174
175
176
X