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
How do I detect Objects that are NEAR another?
By Entity1037, with 7 replies.
Last reply by Entity1037, over 12 years ago:
It works! Thank you so much! I shall post my beta version of the game I'm making this for soon.
how do i make a wall with scrolling background
By KierTulp, with 12 replies.
Last reply by danpost, over 12 years ago:
By the way, my system would not let me delete some of the files in your scenario (telling me that they were still in use; even when nothing was open). I had to re-format to get rid of them. Fortunately, I am using USB drives. I copied all the files to another flash to re-format, then copied them back. Then, I was able to delete them.
PacManGamePad scenario with Logitec f310
By bkellermann, with no replies.
Hello everybody Today I tried to run the pacman example scenario which can be found here:
GamePad
But it didn't work. I got the following two errors: move(int) in Ghost cannot override move(int) in greenfoot.Actor attempting to assign weaker access privileges; was public -->so I mad it public and the same with the PacMan class: move(int) in PacMancannot override move(int) in greenfoot.Actor attempting to assign weaker access privileges; was public After that I was able to compile the code, but I got the next error by executing the programm: java.lang.UnsatisfiedLinkError: no jinput-dx8-64 in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at net.java.games.input.DirectInputEnvironmentPlugin$1.run(DirectInputEnvironmentPlugin.java:75) at java.security.AccessController.doPrivileged(Native Method) at net.java.games.input.DirectInputEnvironmentPlugin.loadLibrary(DirectInputEnvironmentPlugin.java:67) at net.java.games.input.DirectInputEnvironmentPlugin.<clinit>(DirectInputEnvironmentPlugin.java:109) at net.java.games.input.DirectAndRawInputEnvironmentPlugin.<init>(DirectAndRawInputEnvironmentPlugin.java:45) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at java.lang.Class.newInstance0(Class.java:372) at java.lang.Class.newInstance(Class.java:325) at net.java.games.input.DefaultControllerEnvironment.getControllers(DefaultControllerEnvironment.java:157) at gamepadlib.GamePadLoader.initialize(GamePadLoader.java:20) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at GamePad.<clinit>(GamePad.java:132) at Level.generateLevel(Level.java:109) at Level.<init>(Level.java:78) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at greenfoot.core.Simulation.newInstance(Simulation.java:578) at greenfoot.platforms.ide.WorldHandlerDelegateIDE$3.run(WorldHandlerDelegateIDE.java:408) at greenfoot.core.Simulation.runQueuedTasks(Simulation.java:465) at greenfoot.core.Simulation.maybePause(Simulation.java:279) at greenfoot.core.Simulation.runContent(Simulation.java:210) at greenfoot.core.Simulation.run(Simulation.java:203) java.lang.UnsatisfiedLinkError: no jinput-raw-64 in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at net.java.games.input.RawInputEnvironmentPlugin$1.run(RawInputEnvironmentPlugin.java:75) at java.security.AccessController.doPrivileged(Native Method) at net.java.games.input.RawInputEnvironmentPlugin.loadLibrary(RawInputEnvironmentPlugin.java:67) at net.java.games.input.RawInputEnvironmentPlugin.<clinit>(RawInputEnvironmentPlugin.java:109) at net.java.games.input.DirectAndRawInputEnvironmentPlugin.<init>(DirectAndRawInputEnvironmentPlugin.java:46) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at java.lang.Class.newInstance0(Class.java:372) at java.lang.Class.newInstance(Class.java:325) at net.java.games.input.DefaultControllerEnvironment.getControllers(DefaultControllerEnvironment.java:157) at gamepadlib.GamePadLoader.initialize(GamePadLoader.java:20) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at GamePad.<clinit>(GamePad.java:132) at Level.generateLevel(Level.java:109) at Level.<init>(Level.java:78) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at greenfoot.core.Simulation.newInstance(Simulation.java:578) at greenfoot.platforms.ide.WorldHandlerDelegateIDE$3.run(WorldHandlerDelegateIDE.java:408) at greenfoot.core.Simulation.runQueuedTasks(Simulation.java:465) at greenfoot.core.Simulation.maybePause(Simulation.java:279) at greenfoot.core.Simulation.runContent(Simulation.java:210) at greenfoot.core.Simulation.run(Simulation.java:203) java.lang.IllegalArgumentException: No gamepad found, are you sure it's plugged in? at GamePad.getGamePad(GamePad.java:305) at GamePad.getGamePad(GamePad.java:288) at Level.generateLevel(Level.java:109) at Level.<init>(Level.java:78) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at greenfoot.core.Simulation.newInstance(Simulation.java:578) at greenfoot.platforms.ide.WorldHandlerDelegateIDE$3.run(WorldHandlerDelegateIDE.java:408) at greenfoot.core.Simulation.runQueuedTasks(Simulation.java:465) at greenfoot.core.Simulation.maybePause(Simulation.java:279) at greenfoot.core.Simulation.runContent(Simulation.java:210) at greenfoot.core.Simulation.run(Simulation.java:203) java.lang.IllegalArgumentException: No gamepad found, are you sure it's plugged in? at GamePad.getGamePad(GamePad.java:305) at GamePad.getGamePad(GamePad.java:288) at Level.generateLevel(Level.java:109) at Level.<init>(Level.java:78) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:525) at greenfoot.core.Simulation.newInstance(Simulation.java:578) at greenfoot.platforms.ide.WorldHandlerDelegateIDE$3.run(WorldHandlerDelegateIDE.java:408) at greenfoot.core.Simulation.runQueuedTasks(Simulation.java:465) at greenfoot.core.Simulation.maybePause(Simulation.java:279) at greenfoot.core.Simulation.runContent(Simulation.java:210) at greenfoot.core.Simulation.run(Simulation.java:203) I'm using a Logitec f310 GamePad which can swich between DirectInput and XInput. I tried both modes but non of them worked. Does anybody have a solution?
Getting a position of different Objects
By Diphthong, with 4 replies.
Last reply by danpost, over 12 years ago:
Is it a static or non-static variable (non-static will not have the 'static' keyword in its declaration)? If non-static, how many objects of class2 are created and in the world? If only one, then in class1 (and I will give the variable an 'int' type, since you did not say): <Code Omitted>where you have the following method in class2: <Code Omitted>
Error that has no explanation
By lonely.girl, with 3 replies.
Last reply by lonely.girl, over 12 years ago:
I converted it to mp3 a& now it's working :D thank a million :)
Changing Codes on a Jar File
By rduran26, with 2 replies.
Last reply by vonmeth, over 12 years ago:
Can't you
extract
the jar, including the source code?
Help with objects above Actor.
By Sergio, with 2 replies.
Last reply by Sergio, over 12 years ago:
Didn't know this method existed, thanks mate I fount it and it really helped!
HELP understanding code needed plz
By Amanda92, with 12 replies.
Last reply by Amanda92, over 12 years ago:
thanks a lot
Greenfoot Mouse and Button
By yl92, with 1 reply.
Replied to by danpost, over 12 years ago:
Refer to the MouseInfo class documentation in Greenfoot to find what method(s) you are looking for.
Animation
By TomazVDSN, with 4 replies.
Last reply by TomazVDSN, over 12 years ago:
Thank you, I will try and let you and our colleagues to know the result.
Hi friends! Please explain some codes.
By hkrhässleholm, with 10 replies.
Last reply by vonmeth, over 12 years ago:
1) The rules are applied in the applyRule method. First it calls countNeighbors (which we went over last time), to get a count of the number of alive cells around the cell. Next the rules come into play. "if(numNeighborsOn) < 2)" Is the number of neighbors that are alive, less than 2? If so, it dies (state=false) It satisfies this rule: "1. Any live cell with fewer than two live neighbours dies, as if caused by under-population." "else if (numNeighborsOn > 3)" Is the number of neighbors that are alive, greater than 3? If so, it dies (state=false) It satisfies this rule: "3. An
Conway's Game Of life
By Wavesludge, with 18 replies.
Last reply by Wavesludge, over 12 years ago:
Yeah, that works. Thanks for the help!
Moving while in air
By programmer274, with 3 replies.
Last reply by danpost, over 12 years ago:
Just copy the mouse checks and movement code into the fall method.
play again button on scoreboard
By davemib123, with 13 replies.
Last reply by davemib123, over 12 years ago:
good suggestions :) i'll have to test them when I get a chance.
Need help with carrying objects
By Sergio, with 2 replies.
Last reply by Sergio, over 12 years ago:
Ah I see, thanks mate really helped a lot!!
908
909
910
911
912
913
914
X