So i got this error and i'm trying to solve what's wrong..
Error
Code:
The method handlePlankMake(Player, Item) in the type Lunars is not applicable for the arguments (Player) Magic.java
Method
Magic class
Code:
case 344243: //plankmake
Lunars.handlePlankMake(player);
break;
Lunars class method:
Code:
public static void handlePlankMake(Player player, Item item) {
player.getInterfaceManager().openGameTab(7);
if (!player.canAlch()) {
return;
}
int index = getPlankIdx(item.getId());
if (index == -1) {
player.getPackets().sendGameMessage("You can only cast this spell on a log.");
return;
}
if (!player.getInventory().containsItem(logs[index], 1))
return;
if (!Magic.checkSpellRequirements(player, 86, true, Magic.NATURE_RUNE, 1, Magic.ASTRAL_RUNE, 2, Magic.EARTH_RUNE, 15))
return;
player.setNextAnimation(new Animation(6298));
player.setNextGraphics(new Graphics(1063, 0, 50));
player.getInventory().deleteItem(logs[index], 1);
player.getInventory().addItem(planks[index], 1);
player.getSkills().addXp(Skills.MAGIC, 90);
}