Hello I am trying to write a program where im using an MVC
pattern but im having problems with my action listener, i want to when i press the button the action listener picks up that is what a dice object pressed and then call a method in the model which takes a dice object as a parameter.
in my viewClass i have this code
the dice creates a single dice object from a class which is called dice.
in my Controller i have the code
in my model i have this method
the reason in the controller i have .getActionCommand().equals("") is because when i press the dice button i dont seem to get anything. i was wondering if there was a way of representing the dice.so i could then pass it to the rollDice method