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.world.World;
8import com.runehive.game.world.entity.combat.CombatType;
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.Mob;
20import com.runehive.game.world.entity.mob.npc.Npc;
21import com.runehive.game.world.entity.mob.prayer.Prayer;
22import com.runehive.game.world.position.Position;
23import com.runehive.net.packet.out.SendMessage;
24import com.runehive.util.RandomUtils;
25import com.runehive.util.Utility;
27import static com.runehive.game.world.entity.combat.CombatUtil.createStrategyArray;
28import static com.runehive.game.world.entity.combat.CombatUtil.randomStrategy;
63 if (!defender.
getCombat().isAttacking()) {
79 attacker.
move(destination);
130 hit.setAccurate(
false);
136 return roll + 50_000;
170 attacker.
speak(
"Time To HEAL!");
180 hit.setAccurate(
false);
186 return roll + 50_000;
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 sendGraphic(Graphic graphic, Position position, int instance)
Sends a graphic to the world.
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)
void hit(Npc attacker, Mob defender, Hit hit)
CombatStrategy< Npc > currentStrategy
NpcMagicStrategy(CombatProjectile combatProjectile)
static NpcMeleeStrategy get()
NpcRangedStrategy(CombatProjectile combatProjectile)
Jisticiar magic strategy.
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)
void attack(Npc attacker, Mob defender, Hit hit)
void attack(Npc attacker, Mob defender, Hit hit)
CombatHit[] getHits(Npc attacker, Mob defender)
int modifyAccuracy(Npc attacker, Mob defender, int roll)
void start(Npc attacker, Mob defender, Hit[] hits)
void hit(Npc attacker, Mob defender, Hit hit)
int getAttackDelay(Npc attacker, Mob defender, FightType fightType)
void block(Mob attacker, Npc defender, Hit hit, CombatType combatType)
void finishOutgoing(Npc attacker, Mob defender)
Porazdir()
Constructs a new Porazdir.
static final CombatStrategy< Npc >[] NON_MELEE
boolean canAttack(Npc attacker, Mob defender)
static final CombatStrategy< Npc >[] MAGIC_STRATEGIES
static final CombatStrategy< Npc >[] FULL_STRATEGIES
void speak(String forceChat)
Sets the mob's forced chat.
void animate(int animation)
void move(Position position)
Moves the mob to a set position.
Optional< Graphic > graphic
Represents a non-player character in the in-game world.
Combat< Npc > getCombat()
The combat of the mob.
void send(OutgoingPacket encoder)
void deactivate(Prayer... prayers)
Sends the dectivate prayer packet to the client.
Represents a single tile on the game world.
The OutgoingPacket that sends a message to a Players chatbox in the client.
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)
static< T > T randomElement(Collection< T > collection)
Picks a random element out of any array type.
Represents different priorities for updating.
VERY_HIGH
A very high priority.
The enumerated type whose elements represent the fighting types.