Problems separating GUI from Logic
Hell, i am having problems with a dice game that i am making.
First i made the logic of the game, then i made the GUI (NetBeans gui builder), and i want to have the logic update the gui with information about whats going on in the game.
I create a gui object in my logic class and i would like to call setter methods on it in order to post numbers into jLabels in the gui.
one thing im having trouble with is that there is a roll button and start game button in the gui so those need to be able to access the logic to start the game and get dice values.
Everytime i try to set values in the gui from the logic, it gives me null pointer exceptions and i have no idea why. can anyone help me figure out a better way to have this work?
I realize this is a very broad question and probably will not get any responses but i dont know what to do now