Sign in to follow this  
CryoGenesis

JApplet Paint Flashing? (SOLVED)

Recommended Posts

CryoGenesis    528
My java applet paint method produces a lot of flashing :/ I know one way round this would be double buffering but I thought all Swing things were double buffered automatically(JFrame for example).
I'm creating a game for my website, which is my first web game because I've never been too bothered about applets, and the JApplet creates flashing. When switched to normal applet the flashing is even worse.
The JApplet class doesn't have any this.createBufferStrategy or this.getBufferStrategy methods so would I have to code these things into the JApplet?
Thanks in advance.
p.s: whoever helps me and the solution works I will put a thank you with your username in the menu screen of the game and any other web games I make.

Edit:
Solved it.
Just create graphics from an image then draw everything onto graphics then draw the image in the paint method.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this