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
Score problems
By cesararp10, with 2 replies.
Last reply by cesararp10, over 8 years ago:
thank you so much ... worked great!!
Spawning an object to a particular side of another object?
By cmdshepard, with 6 replies.
Last reply by cmdshepard, over 8 years ago:
alright, cheers again chaps
Greenfoot is reading setImage() but is not setting the image?
By SloanTheSloth, with 1 reply.
Replied to by danpost, over 8 years ago:
It looks like your instruction pointer is at the 'setImage' line (where it has not executed yet). However, there is a very easy way to accomplish what you are trying: <Code Omitted>
Sound starts playing despite using !isPlaying
By Saberdeer, with 2 replies.
Last reply by Saberdeer, over 8 years ago:
Aaaand I feel dumb. Yeah, that fixed it. Thank you!
need to understand this error
By divinity, with 2 replies.
Last reply by divinity, over 8 years ago:
thank you danpost, didnt even see and noticed that. thanks a lot
Help with moving an object?
By Astralman, with 5 replies.
Last reply by Super_Hippo, over 8 years ago:
This could work: <Code Omitted>
Heapspace error occurred,Greenfoot crashed, now won't initialize correctly
By JWK3986, with 1 reply.
Replied to by JWK3986, over 8 years ago:
Never mind I may have found a fix by resetting the images assigned to each actor by right clicking and choosing set image.
Can't jump
By Jochends, with 6 replies.
Last reply by Jochends, over 8 years ago:
Omg i found my big mistake.. It's maybe good to share this with others.. I found a platform(ground) image where he stands on and made it transparant( because it had a white background ). But their was still a few inches of transparency above the ground that i didnt cut in my program. So he was just standing on the 'invisble' part of that image. Thanks anyway for the improvement of my code
Creating Buttons?
By rn42v1r, with 6 replies.
Last reply by rn42v1r, over 8 years ago:
Thank you very much, it's working :D
getObjects(Actor.class);
By ZoeF, with 7 replies.
Last reply by danpost, over 8 years ago:
ZoeF wrote...
I wil give this idee a go and keep you updated if i have any issues with it.
You will have one, unless you change the access modifier of the list from 'private' to 'public'.
turntowards but image not facing correct way
By ZoeF, with 4 replies.
Last reply by ZoeF, over 8 years ago:
Yep did just that. Tnx anyway.
Tips before attempting a large project?
By alittle_bit, with 1 reply.
Replied to by danpost, over 8 years ago:
If you already know what you want overall, I suggest you create a game plan before writing any codes. For a decent full-fledged project, you could have a header screen, menu world, maps for levels, possibly with scrolling and/or smooth moving -- whatever. I usually start with whatever is first -- like the header screen. Then, move on to maybe the menu with button options for 'play', 'exit', 'credits', and 'controls'. One thing I would not do is create four separate classes for each of the option; but use one class to create the different option actors. Let the menu world retain references
Greenfoot Java Problems (can`t use Greenfoot)
By Stern, with no replies.
Everytime I try to use installed greenfoot, for example if I want to create a new Project, Open an old one, try to compile ... Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at sun.awt.shell.Win32ShellFolder2.getFileSystemPath(Win32ShellFolder2.java:571) at sun.awt.shell.Win32ShellFolder2.access$400(Win32ShellFolder2.java:72) at sun.awt.shell.Win32ShellFolder2$2.call(Win32ShellFolder2.java:298) at sun.awt.shell.Win32ShellFolder2$2.call(Win32ShellFolder2.java:296) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at sun.awt.shell.Win32ShellFolderManager2$ComInvoker$3.run(Win32ShellFolderManager2.java:547) at java.lang.Thread.run(Thread.java:745) So i can not do anything :( I am using Win 7, Greenfoot 3.0.4, Java 1.8.0_112 installed (just both new downloaded and installed) and it doesn't work Debuglogfile: Greenfoot run started: Wed Nov 09 11:54:37 CET 2016 Greenfoot version: 3.0.4 Java version 1.8.0_112 Virtual machine: Java HotSpot(TM) 64-Bit Server VM 25.112-b15 (Oracle Corporation) Running on: Windows 7 6.1 (amd64) Java Home: D:\Programme\Java\jdk1.8.0_112\jre ---- Opening project: D:\Programme\Greenfoot\lib\greenfoot\startupProject 1478688881892: Listening for JDWP connection on address: javadebug Connected to debug VM via dt_shmem transport... Communication with debug VM fully established. I tried the portable Version - and again, it does not work: java.rmi.ConnectException: Connection refused to host: 127.0.0.1; nested exception is: java.net.ConnectException: Connection refused: connect at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:619) at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:216) at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:130) at rmiextension.wrappers.RBlueJImpl_Stub.getOpenProjects(Unknown Source) at rmiextension.BlueJRMIClient.initialise(BlueJRMIClient.java:85) at greenfoot.core.GreenfootLauncherDebugVM$1.run(GreenfootLauncherDebugVM.java:81) Caused by: java.net.ConnectException: Connection refused: connect at java.net.DualStackPlainSocketImpl.connect0(Native Method) at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:79) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at java.net.Socket.connect(Socket.java:538) at java.net.Socket.<init>(Socket.java:434) at java.net.Socket.<init>(Socket.java:211) at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40) at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:148) at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613) ... 6 more java.rmi.ConnectException: Connection refused to host: 127.0.0.1; nested exception is: java.net.ConnectException: Connection refused: connect at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:619) at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:216) at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:130) at rmiextension.wrappers.RBlueJImpl_Stub.getSystemLibDir(Unknown Source) at greenfoot.core.GreenfootLauncherDebugVM$1.run(GreenfootLauncherDebugVM.java:82) Caused by: java.net.ConnectException: Connection refused: connect at java.net.DualStackPlainSocketImpl.connect0(Native Method) at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:79) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:589) at java.net.Socket.connect(Socket.java:538) at java.net.Socket.<init>(Socket.java:434) at java.net.Socket.<init>(Socket.java:211) at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40) at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:148) at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613) ... 5 more =============== Any idea how to get at least 1 working? (Both fresh downloaded today, include java)
Spawn Objects every second
By Blattstein, with 3 replies.
Last reply by danpost, over 8 years ago:
You could repeat lines 47 and 48 (omitting the 'Fireball' at the beginning of the first line on the repeated lines); or you could enclose those lines in a 'for' loop, the limit of which could be a random value ( maybe '3 + Greenfoot.getRandomNumber(2)' ).
Object floating above my platform and not touching
By Jochends, with 2 replies.
Last reply by Jochends, over 8 years ago:
Thanks, That helped!
427
428
429
430
431
432
433
X