Java Gui (Reload Class)
Hello,
im making a game in java and i have come to a point where i need to reload the entire class frmMain which is impleting JFrame so in my basic program i'm calling my Main class(frmMain) and it does all the key listening and everything for that i have another class from the Main class it calls the key listening and it deoes certain things VK_UP VK_DOWN VK_RIGHT VK_LEFT is pressed and so on but when they are pressed at the end i want to reload the Main class in other words reload the gui again
i'm not using any painted objects so i assume repain() doesnt work the way the game works is it just a Grid panel with pictures and their locations are changed acording the key pressed and get saved in a file blah blah blah .. i wanted to know if can call the Main class again when this keys are pressed ( i have exit button in there too)
thank you for your help
-Axar
|