Sign Up, Lost Password
What is happening right now?
3d Iso Demo
'non-static method cannot be referenced from a static context'
By Reaper47, with no replies.
I'm trying to call an method in one class from another, and when I try to do this I get this error. 'non-static method takeDamage(double) cannot be referenced from a static context' I don't even know what static method necessarily means in Greenfoot so I have no idea on how I would go about fixing the context/method. Any help on the issue or just a brief explanation on what 'static' means in Greenfoot would be great!
reply to why am I getting this error, please explain
By divinity - about 8 hours ago
thank you davmac very much. and hey it is nice to kno u are still here
reply to Make an actor orbiting another actor
By danpost - about 13 hours ago
One way is to turn the actor slightly and relocate the actor at the center of the circle; then turn 90 degrees and move the radial distance required from the center and un-turn 90 degrees.
Comment on Flying Game
By lordhershey - about 19 hours ago
Not bad, I like the idea, there are many things that can be done to improve it.
New Scenario: DrivingHedgehog
By game917 - 1 day ago
Hedgehog with a car
New Scenario: lobsters
By chalsia - 1 day ago
reply to java.lang.NullPointerException
By Super_Hippo - 1 day ago
Do you add the Point object into your world? You created it with this line: <Code Omitted>'getWorld' returns null on this object if it isn't in the world (so either not added at all or removed). To add it, you can use this line: <Code Omitted>
reply to Need an actor to always be on top visually.
By Reaper47 - 1 day ago
It is possible, using the setPaintOrder method in world. In the world's constructor, add something like this: <Code Omitted>You could specify the order in which they need to appear, the first one being the type that will be displayed on top of following ones, but if I'm not mistaken, specifying only one class will ensure it will get drawn on top of all the others.
I'll tweak around with this and look more into it if needed. Thank you.
reply to Is there a boolean for Greenfoot.stop()?
By danpost - 2 days ago
I'm working on a space shooter game, where the attackining space ships, who are coming down to the player's ship, are getting faster and faster. So the degree of difficulty increases but not to fast.
To slow down the speeding up of the space ships, you could do something like this: <Code Omitted>(have the value of 'i' start at the slow down value)
By ismaizoni - 3 days ago
New Scenario: duniazombie
By rahma30 - 3 days ago
By abrartaufik281296 - 3 days ago