1package com.runehive.game.world.entity.combat.strategy.npc.boss.magearena;
3import com.runehive.game.Animation;
4import com.runehive.game.Graphic;
5import com.runehive.game.Projectile;
6import com.runehive.game.UpdatePriority;
7import com.runehive.game.task.impl.ForceMovementTask;
8import com.runehive.game.world.World;
9import com.runehive.game.world.entity.combat.CombatUtil;
10import com.runehive.game.world.entity.combat.attack.FightType;
11import com.runehive.game.world.entity.combat.hit.CombatHit;
12import com.runehive.game.world.entity.combat.hit.Hit;
13import com.runehive.game.world.entity.combat.projectile.CombatProjectile;
14import com.runehive.game.world.entity.combat.strategy.CombatStrategy;
15import com.runehive.game.world.entity.combat.strategy.npc.MultiStrategy;
16import com.runehive.game.world.entity.combat.strategy.npc.NpcMagicStrategy;
17import com.runehive.game.world.entity.combat.strategy.npc.NpcMeleeStrategy;
18import com.runehive.game.world.entity.combat.strategy.npc.NpcRangedStrategy;
19import com.runehive.game.world.entity.mob.Direction;
20import com.runehive.game.world.entity.mob.Mob;
21import com.runehive.game.world.entity.mob.npc.Npc;
22import com.runehive.game.world.entity.mob.player.ForceMovement;
23import com.runehive.game.world.pathfinding.path.SimplePathChecker;
24import com.runehive.game.world.position.Position;
25import com.runehive.net.packet.out.SendMessage;
26import com.runehive.util.Utility;
28import static com.runehive.game.world.entity.combat.CombatUtil.createStrategyArray;
29import static com.runehive.game.world.entity.combat.CombatUtil.randomStrategy;
108 hit.setAccurate(
false);
114 return roll + 50_000;
148 attacker.
speak(
"Time To HEAL!");
158 hit.setAccurate(
false);
164 return roll + 50_000;
184 hit.setAccurate(
false);
210 int dx = current.
getX() - best.
getX();
211 int dy = current.
getY() - best.
getY();
213 int y = dy / (dx == 0 ? dy : dx);
225 hit.setAccurate(
false);
Class that models a single animation used by an entity.
Represents a single graphic that can be used by entities.
Represents the game world.
static void schedule(Task task)
Submits a new event.
static void sendProjectile(Projectile projectile, Position position, int instance, int lock, byte offsetX, byte offsetY)
Sends a world projectile.
A collection of util methods and constants related to combat.
static void areaAction(Mob mob, Consumer< Mob > action)
Executes an action for mobs within a 3x3 square, including the source mob.
A wrapper for a Hit object, adding additional variables for hit and hitsplat delays.
A Hit object holds the damage amount and hitsplat data.
static CombatProjectile getDefinition(String name)
final CombatHit nextRangedHit(T attacker, Mob defender)
CombatHit nextMeleeHit(T attacker, Mob defender)
final CombatHit nextMagicHit(T attacker, Mob defender)
boolean withinDistance(T attacker, Mob defender)
CombatStrategy< Npc > currentStrategy
NpcMagicStrategy(CombatProjectile combatProjectile)
static NpcMeleeStrategy get()
NpcRangedStrategy(CombatProjectile combatProjectile)
void start(Npc attacker, Mob defender, Hit[] hits)
void hit(Npc attacker, Mob defender, Hit hit)
void attack(Npc attacker, Mob defender, Hit hit)
CombatHit[] getHits(Npc attacker, Mob defender)
Jisticiar magic strategy.
CombatHit[] getHits(Npc attacker, Mob defender)
void hit(Npc attacker, Mob defender, Hit hit)
void start(Npc attacker, Mob defender, Hit[] hits)
void attack(Npc attacker, Mob defender, Hit hit)
int modifyAccuracy(Npc attacker, Mob defender, int roll)
void attack(Npc attacker, Mob defender, Hit hit)
void start(Npc attacker, Mob defender, Hit[] hits)
void hit(Npc attacker, Mob defender, Hit hit)
int modifyAccuracy(Npc attacker, Mob defender, int roll)
CombatHit[] getHits(Npc attacker, Mob defender)
CombatHit[] getHits(Npc attacker, Mob defender)
void hit(Npc attacker, Mob defender, Hit hit)
void attack(Npc attacker, Mob defender, Hit hit)
static TeleGrab TELE_GRAB
static final CombatStrategy< Npc >[] NON_MELEE
void finishOutgoing(Npc attacker, Mob defender)
static LightingRain LIGHTNING_RAIN
int getAttackDelay(Npc attacker, Mob defender, FightType fightType)
boolean canAttack(Npc attacker, Mob defender)
Derwen()
Constructs a new Derwen.
static final CombatStrategy< Npc >[] MAGIC_STRATEGIES
static final CombatStrategy< Npc >[] FULL_STRATEGIES
void speak(String forceChat)
Sets the mob's forced chat.
void interact(Mob mob)
Sets the mob interacting with another mob.
void animate(int animation)
final boolean isPlayer()
Check if an entity is a player.
Optional< Graphic > graphic
Represents a non-player character in the in-game world.
void send(OutgoingPacket encoder)
Represents a PathFinder which is meant to be used to check projectiles passage in a straight line.
static boolean checkLine(Interactable source, Interactable target)
Represents a single tile on the game world.
int getY()
Gets the absolute y coordinate.
int getX()
Gets the absolute x coordinate.
Position transform(int diffX, int diffY, int diffZ)
Creates a new location based on this location.
The OutgoingPacket that sends a message to a Players chatbox in the client.
Handles miscellaneous methods.
static int random(int bound)
static Position findBestInside(Interactable source, Interactable target)
Represents different priorities for updating.
VERY_HIGH
A very high priority.
The enumerated type whose elements represent the fighting types.