Original Post
Hi, Im currently wanting to design and create my own little game engine in java that will display the games in a window(not applet). I know i will need to create methods that will paint the screen but i am unsure as to how I draw it to a buffer then to screen. I previously made a simple game engine using the windows GDI and from my experience I realised that the need for double buffering is required. I will have methods for things such as cleanup, initialization, drawing the game screen and also things like a game cycle. I have been looking on the net and can find some good tutorials about creating pong however these all refer to how it is done in an applet which is not really what i want.(Im not wanting to make pong BTW, I just looked at them so I could see how the drawing technique was done.) I can figure out that i think i need to use the paintComponent() method but i am unsure on how i would go about putting this in my own method that I can call when I want to draw the screen. Maybe I have got a little confused with my C++ and Java on how things have got drawn to screen?? Does anyone know of a good example on how to draw something double buffered to the screen in java? Any help would be much appreciated Thanks in advance Matt