kenshinakh I think you are mistaken about what double-buffering is. Double buffering does not prevent lag, it prevents flicker, and Greenfoot does implement it. Double buffering only means that what you make an adjustment to the image, you are not modifying the image that is on the screen, but a separate buffer that also contains a duplicate image. When the image you are drawing to is considered 'complete' (mostly done at the end of a frame or act cycle) the buffer is copied to the screen without any need to do any graphical calculations. This prevents flicker while images/objects are being modified between frames. You can see that greenfoot uses a version of double buffering, as changes to the actors positions are not seen until the act method is completed.
Ah, i see where the problems would arise. I did the outlined text in kind of a roundabout manner. I have an overlay actor that handles effects like the highlight ring, transitions, and text. The text actor writes its text onto the overlay image, but instead of writinig it once in one color, it first writes it 4 times in white, and then once more in black. Using small offsets, it gives the outline effect that i intended.
Hehe, that final level took a while to design :) Glad you guys like it!
I believe the font still works because i am using Greenfoots default font, not others that can only be found on linux/windows ect...
Its giving me an error
java.security.AccessControlException: access denied (java.lang.RuntimePermission exitVM.0)
at java.security.AccessControlContext.checkPermission(Unknown Source)
at java.security.AccessController.checkPermission(Unknown Source)
at java.lang.SecurityManager.checkPermission(Unknown Source)
at java.lang.SecurityManager.checkExit(Unknown Source)
at javax.swing.JFrame.setDefaultCloseOperation(Unknown Source)
at SnakeGame.<init>(SnakeGame.java:29)
at SnakeGame.main(SnakeGame.java:59)
at Button1.act(Button1.java:19)
at greenfoot.core.Simulation.runOneLoop(Simulation.java:288)
at greenfoot.core.Simulation.run(Simulation.java:158)
Seems your doing things that applets wont allow, for security reasons?
Yeah, the physics is not perfect, and since the terrain is so dynamic (you influence a big part!) there are sometimes weird things that happen. It mostly happens when there are small gaps between objects or walls.
2009/11/30
Global Men
2009/11/30
Water Works
2009/11/30
Water Works
2009/11/27
Simple Games
2009/11/26
Water Works
2009/11/26
Water Works
2009/11/26
Water Works
2009/11/26
Water Works
2009/11/25
boundless-actor-test