Well, I've made a gambling class, but I cannot get it to work right.
Here is the void in the class:
Code:
public void options(int amount, int money) {
if (!Engine.playerItems.addItem(player, 955, money)) {
player.getActionSender().sendMessage(player, "You need at least " + money + "m cash to use this feature.");
return;
}
playGame();
}
Here is the case at ObjectOption1:
Code:
case 1590:
Gambling.options(1000000, 1);
break;
The error:
Code:
non-static method options(int, int) cannot be referenced from a static context Gambling.options(1000000, 1);
Thanks for the helpers will rep.