1package com.runehive.game.world.entity.mob;
3import com.runehive.game.task.Task;
4import com.runehive.game.world.World;
5import com.runehive.game.world.entity.combat.CombatConstants;
6import com.runehive.net.packet.out.SendScreenshot;
18 protected final T
mob;
43 mob.getCombat().reset();
44 mob.getPoisonDamage().set(0);
51 Mob killer =
mob.getCombat().getDamageCache().calculateProperKiller().orElse(
null);
55 killer.
getCombat().preKill(
mob,
mob.getCombat().getDamageCache().lastHit);
61 if (killer !=
null && killer.
getCombat().isAttacking(
mob)) {
62 mob.getCombat().preDeath(killer,
mob.getCombat().getDamageCache().lastHit);
83 killer.
getCombat().onKill(
mob,
mob.getCombat().getDamageCache().lastHit);
84 mob.getCombat().onDeath(killer,
mob.getCombat().getDamageCache().lastHit);
86 mob.getCombat().getDamageCache().clear();
synchronized final void cancel()
Cancels all subsequent executions.
Task(boolean instant, int delay)
Creates a new Task.
int delay
The cyclic delay.
Represents the game world.
static void sendKillFeed(final Mob killer, final Mob victim)
Sends a kill feed notification.
static final int COMBAT_LOGOUT_COOLDOWN
The amount of time it takes in milliseconds it takes to logout.
final void execute()
A function representing the unit of work that will be carried out.
void onSchedule()
A function executed on registration.
abstract void postDeath(Mob killer)
The last part of the death process where the character is reset.
MobDeath(T mob, int delay)
Creates a new MobDeath.
abstract void preDeath(Mob killer)
The part of the death process where the character is prepared for the rest of the death tick.
void onCancel(boolean logout)
A function executed on cancellation.
int counter
The counter that will determine which part of the death process we are on.
abstract void death()
The main part of the death process where the killer is found for the character.
abstract Combat<? extends Mob > getCombat()
The combat of the mob.
final boolean isPlayer()
Check if an entity is a player.
void send(OutgoingPacket encoder)