1package com.runehive.content.skill.impl.runecrafting;
3import com.runehive.game.world.entity.mob.player.Player;
4import com.runehive.game.world.entity.skill.Skill;
5import com.runehive.game.world.items.Item;
24 player.message(
"You need a runecrafting level of " + pouch.
level +
" to use this pouch!");
28 int inventory =
player.inventory.computeAmountForId(7936);
31 player.message(
"You have no rune essences in your inventory to fill this pouch!");
37 System.out.println(essence);
41 player.inventory.remove(7936, essence);
42 player.message(
"You have filled your pouch with " + essence +
" rune essences!");
51 player.inventory.add(7936, essence);
52 player.message(
"You have emptied your pouch.");
boolean death(Item item)
Handles player dying with a rune pouch.
final Player player
The player instance.
void deposit(RunecraftPouchData pouch)
Deposits essence into the player's runecraft pouch.
RunecraftPouch(Player player)
Constructs a new RunecraftPouch.
void withdraw(RunecraftPouchData pouch)
Withdraws essence from the player's rune essence pouch.
This class represents a character controlled by a player.
Represents a trainable and usable skill.
static final int RUNECRAFTING
The runecrafting skill id.
The container class that represents an item that can be interacted with.
final int getId()
Gets the identification of this item.
Holds the runecrafting pouch data.
final int level
The level required to use the runecrafting pouch.
abstract int deposit(Player player, int amount)
What happens to the runecrafting pouch when a player fills it.
static RunecraftPouchData forItem(int item)
Gets the runecrafting pouch data based on the item identification.
abstract void empty(Player player)
Empties the runecrafting pouch.
abstract int withdraw(Player player)
What happens to the runecrafting pouch when a player empties it.
final int capacity
The capacity that the runecrafting pouch can hold.