1package com.runehive.content.skill.impl.firemaking;
3import com.runehive.Config;
4import com.runehive.content.skillcape.SkillCape;
5import com.runehive.content.activity.randomevent.RandomEventHandler;
6import com.runehive.content.clanchannel.content.ClanTaskKey;
7import com.runehive.content.event.impl.ItemOnItemInteractionEvent;
8import com.runehive.content.event.impl.ObjectInteractionEvent;
9import com.runehive.content.pet.PetData;
10import com.runehive.content.pet.Pets;
11import com.runehive.content.prestige.PrestigePerk;
12import com.runehive.game.action.Action;
13import com.runehive.game.action.policy.WalkablePolicy;
14import com.runehive.game.world.entity.mob.player.Player;
15import com.runehive.game.world.entity.skill.Skill;
16import com.runehive.game.world.items.Item;
17import com.runehive.game.world.object.GameObject;
18import com.runehive.util.RandomUtils;
19import com.runehive.util.Utility;
34 Item first =
event.getFirst();
35 Item second =
event.getSecond();
40 if (first.
getId() == 590) {
43 }
else if (second.
getId() == 590) {
70 if (
event.getOpcode() != 0 ||
event.getObject().getId() != 5249) {
75 player.
message(
"Please step out of the fire!");
94 player.
message(
"You need a firemaking level of " +
firemaking.getLevel() +
" to light this log!");
114 return "Bonfire action";
118 protected void execute() {
123 if (!
object.active()) {
128 player.
message(
"You have no more logs!");
157 protected void onCancel(
boolean logout) {
The class that contains setting-related constants for the server.
static final double FIREMAKING_MODIFICATION
The experience modification for firemaking.
static void trigger(Player player)
final DialogueFactory execute()
Retrieves the next dialogue in the chain and executes it.
final DialogueFactory sendStatement(String... lines)
Appends a StatementDialogue to the current dialogue chain.
Handles spawning, rewarding and picking up of pets.
static void onReward(Player player, int item, int chance)
Handles calculating the chance of a player receiving a skilling pet.
boolean hasPerk(PrestigePerk perk)
Handles the firemaking action.
boolean useItem(Player player, ItemOnItemInteractionEvent event)
static double getBonus(Player player)
boolean clickObject(Player player, ObjectInteractionEvent event)
Action< Player > bonfireAction(Player player, GameObject object, FiremakingData firemaking, int toBurn)
Firemaking(int level, double experience)
Represents an action an entity can execute.
public< A extends Action<?> > void execute(A action)
final SkillManager skills
void animate(int animation)
void activateSkilling(int amount)
This class represents a character controlled by a player.
final Inventory inventory
void forClan(Consumer< ClanChannel > action)
void message(String message)
final Equipment equipment
DialogueFactory dialogueFactory
final PlayerAssistant playerAssistant
static String getName(int skill)
Gets the name for a skill id.
double experience
The current skill experience.
int level
The current level of the skill.
Skill(int skill, int level, double experience)
Constructs a new Skill.
void addExperience(int id, double experience)
Adds experience to a given skill.
int getMaxLevel(int id)
Gets the highest possible level of a skill.
The container class that represents an item that can be interacted with.
final int getId()
Gets the identification of this item.
final int computeAmountForId(int id)
Computes the total quantity of the Items in this container with id.
boolean remove(Item item)
Attempts to withdraw item from this container.
final int getId(int index)
Gets the item id located on index.
boolean contains(int id)
Determines if this container contains id.
final boolean containsAll(int... identifiers)
Determines if this container contains all identifiers.
boolean equals(Object obj)
A static-util class that provides additional functionality for generating pseudo-random numbers.
static boolean success(double value)
Determines if a pseudorandomly generated double rounded to two decimal places is below or equal to va...
Handles miscellaneous methods.
static int random(int bound)
Handles the perk rewards from prestiging.
static Optional< FiremakingData > forId(int id)
static boolean isEquipped(Player player, SkillCape cape)
A queue policy determines whether the action can occur while walking.
NON_WALKABLE
This indicates actions cannot occur while walking.
Represents a game object.