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
are there physics in greenfoot?
By RobTheRipper, with 2 replies.
Last reply by Gevater_Tod4711, over 11 years ago:
Unfortunatly there is no physics engine in greenfoot but this doesn't mean that you have to program everything on your own. There are many physics that someone else has already programmed and you can use them. For example for your catapult you could use this physics:
Double to int
By GreenGoo, with 14 replies.
Last reply by GreenGoo, over 11 years ago:
I have managed to solve the problem! The atan() was not happy about using integers instead of doubles. Then I made a host of other changes. Here is my current code: if (exploded == false && genericDelay < 0){ Actor player = (Actor) getWorld().getObjects(Player.class).get(0); double missileX = (double) this.getX(); double missileY = (double) this.getY(); double playerX = (double) player.getX(); double playerY = (double) player.getY(); double number = (missileX - playerX) / (playerY - missileY); double
Menu Button help
By FlyingRabidUnicornPig, with 1 reply.
Replied to by FlyingRabidUnicornPig, over 11 years ago:
I figured it out, getKey() only returns the last key pressed. Changed my whenClicked() method to: <Code Omitted> It w
How to make something spawn once?
By ColonelCaboose, with 4 replies.
Last reply by ColonelCaboose, over 11 years ago:
It works, thank you so much!
Simulating Karel or Karel J Robot
By PeggyCraft, with no replies.
The Karel simulator will not install in my school's computer lab, but it is what I want to teach. I think Greenfoot can be made into such a tool, but am failing to figure out how. Actual help or a pointer thereto? Here or to pcraft@cfsnc.org. thanks.
This simple thing just won't work..
By Wescorn, with 26 replies.
Last reply by JetLennit, over 11 years ago:
i thought it was something else.......... oh well, im glad it worked!
Help with Barriers??
By RedManRocket, with 4 replies.
Last reply by -nic-, over 11 years ago:
If you still need help im guessing you are using a detection that uses direct x + y coor's which will only be true for the very center of the object
Referencing Objects
By Gingervitis, with 7 replies.
Last reply by Gingervitis, over 11 years ago:
I figured it out. I had two constructors for the same thing and only one was being called for.
Need help with creating a rotating turret.
By Griffon305, with 13 replies.
Last reply by danpost, over 11 years ago:
The statement 'rotation += 5;' is the same thing as 'rotation = rotation + 5;. Since we are turning the actor plus five degrees, we want our rotation field to adjust by that same amount so we know the new bullet rotation value.
Score Board
By JetLennit, with 7 replies.
Last reply by JetLennit, over 11 years ago:
Thank you.... but i all ready came up with a way to do it.... if you want to see it you know where to go... but eventually i will probably use that
Does Greenfoot automatically update?
By JetLennit, with 2 replies.
Last reply by JetLennit, over 11 years ago:
Thank you SOOOO much
Need help removing actor when touched by another
By AA123, with 4 replies.
Last reply by danpost, over 11 years ago:
Another way to handle this is to combine the two methods into one, supplying the class to check for in a parameter field. Have the method return a boolean indicating whether an object was found or not. This is how it would be done:
adding sound to my object
By geekykid2013, with 22 replies.
Last reply by danpost, over 11 years ago:
You do not have to double post (unless your request for help goes days without a response -- then, just post 'bump'). There does not appear to be anything wrong with the Turtle class code as far as the 'canSee' method call. Maybe the Animal class code was altered (possibly by accident). Please show the code you have in the Animal class.
setting up my kinect for xp
By muscipula666, with no replies.
I'm following your instructions on setting up xp using your drivers at this page. http://www.greenfoot.org/topics I have installed sp2.and sp3. The cpp library installs as well as the .net stuff. But when I get to openni-win32.msi I get an error 'there is a problem with this windows installer package. A program run as part of the setup did not finish as expected. Contact your support personel or package vendor.'
Missile Swerving
By GreenGoo, with 2 replies.
Last reply by danpost, over 11 years ago:
No traffic control system is perfect. Even controlling the interaction between two vehicles involves not just the state of the two being close to each other, but determining how they are approaching each other and turning the correct way to avoid each other takes a bit of Maths. When a third vehicle is introduced into the equation, things really get complicated. Basically, what I am saying is that this is probably not anything a beginner should try to tackle. You could, however, randomly choose a direction and begin turning that way until either a collision occurs or the two vehicle have cl
860
861
862
863
864
865
866
X