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
Collision Sensing
By Steve_888, with 1 reply.
Replied to by mjrb4, about 13 years ago:
You probably want to look at the
getObjectsInRange
method which will allow you to get a list of all the objects a certain radius (or closer) away from the actor.
just looking for a little help
By ub3030, with 7 replies.
Last reply by mjrb4, about 13 years ago:
Well if it has objects in the way that makes it a bit more complicated. You could keep track of your position by judging how much you've turned / travelled then work out from that if something you've hit is a likely edge or obstacle. That might give you a starting point. With these sorts of problems it's often easier to map out your logic on paper first, then turn it into code later.
How to make the view like in Szenario "City" ??
By TopInPut, with 5 replies.
Last reply by mjrb4, about 13 years ago:
The short answer is likely if you have to ask the question, then you're probably not at a stage where you can implement it. It is indeed impressive and a nice piece of coding, but any 3D or iso-3D like worlds you see in Greenfoot have had the 3D in them coded by hand, it's not something that's built into Greenfoot at all! Of course, this doesn't mean you can't look at the source code, try to gain an understanding of it and learn from it :)
Cannot return a value from method whose result type is void
By darkmist255, with 1 reply.
Replied to by darkmist255, about 13 years ago:
I changed it to double and it no longer has an error, disregard this :D.
Making Coordinates
By kiarocks, with 11 replies.
Last reply by kiarocks, about 13 years ago:
I think ill use davmac's idea. @danpost, you remember that scenario you downloaded to take a look at the code? It's that scenario.
Beginner, and need your help
By antoun2011, with 4 replies.
Last reply by antoun2011, about 13 years ago:
Yeah that was it, I opened from a read-only. Thank you very much
I need PPT resource
By winnerpig, with 3 replies.
Last reply by winnerpig, about 13 years ago:
Yes,I am. I've joined greenroom yet,but it seems only be some demos there , and I dont know how to use those cases to my class.
Help!array question
By janjan01, with 1 reply.
Replied to by janjan01, about 13 years ago:
I have solved the question but i got a new question how can i get a signal that if the import file by scanner does not exist or the content in the file is not in correct order/format. i do not mean the immediate window will give out warnings but i want a method that will return boolean when the above error occur or not.
Greenfoot.isKeyDown
By bourne, with 3 replies.
Last reply by bourne, about 13 years ago:
Thanks davmac.
Collision Detecting
By ChrisIsOsmer, with 5 replies.
Last reply by kiarocks, about 13 years ago:
10 cells up from the actor you call it from
decimal (double) rotations of actors
By theguywholikeslinux, with no replies.
It would be really great if I could rotate my actors by not just 360 degrees but decimal values aswell, eg 287.47°. I find it especially useful for large actors in high-rez worlds where 1 degree can be the difference of 10px at each end! I often find myself storing my rotation as a double and then having to cast it to an int each time I want to adjust it but still store the full precision double separately.
One More Question..
By 2woodsway, with 2 replies.
Last reply by Builderboy2005, about 13 years ago:
You made a void method, the fact that it is returning nothing is a good thing :D Did you mean to say perhaps that nothing is being printed out?
Help Quick Question
By 2woodsway, with 3 replies.
Last reply by 2woodsway, about 13 years ago:
very true!! thanks so much
I am lost I am supposed to Write an interface named 'Test' with the following behavior:
By 2woodsway, with 1 reply.
Replied to by mjrb4, about 13 years ago:
Well: - The interface isn't called Test, it's called PointingDevice - It doesn't have a getDuration() method - It doesn't have a check() method - It doesn't have a getScore() method ...I'm not sure there's a lot to go on to help you there!
Making Variable names
By kiarocks, with 14 replies.
Last reply by actinium, about 13 years ago:
Just posted a connect 4 in progress scenarios that uses buttons the way you want, i put the code up , the squares on the board are effectively buttons. The buttons light up when the mouse moves over a particular legal square and when you click on a particular square a coin is placed in the square.. Note also when you enter a coin the square above that coin becomes active.
1026
1027
1028
1029
1030
1031
1032
X