RuneHive-Game
Loading...
Searching...
No Matches
VestaLongsword.java
Go to the documentation of this file.
1package com.runehive.game.world.entity.combat.strategy.player.special.melee;
2
3import com.runehive.game.Animation;
4import com.runehive.game.UpdatePriority;
5import com.runehive.game.world.entity.combat.attack.FightType;
6import com.runehive.game.world.entity.combat.hit.Hit;
7import com.runehive.game.world.entity.combat.strategy.player.PlayerMeleeStrategy;
8import com.runehive.game.world.entity.mob.Mob;
9import com.runehive.game.world.entity.mob.player.Player;
10
11public class VestaLongsword extends PlayerMeleeStrategy {
12 private static final Animation ANIMATION = new Animation(7515, UpdatePriority.HIGH);
13 private static final VestaLongsword INSTANCE = new VestaLongsword();
14
15 private VestaLongsword() { }
16
17 @Override
18 public void start(Player attacker, Mob defender, Hit[] hits) {
19 super.start(attacker, defender, hits);
20 }
21
22 @Override
23 public void hitsplat(Player attacker, Mob defender, Hit hit) {
24 super.hitsplat(attacker, defender, hit);
25 }
26
27 @Override
28 public void onKill(Player attacker, Mob defender, Hit hit) {
29 }
30
31 @Override
32 public int getAttackDelay(Player attacker, Mob defender, FightType fightType) {
33 return 3;
34 }
35
36 @Override
37 public Animation getAttackAnimation(Player attacker, Mob defender) {
38 return ANIMATION;
39 }
40
41 @Override
42 public int modifyAccuracy(Player attacker, Mob defender, int roll) {
43 return roll * 5 / 4;
44 }
45
46 @Override
47 public int modifyDamage(Player attacker, Mob defender, int damage) {
48 return 3 / 2;
49 }
50
51 public static VestaLongsword get() {
52 return INSTANCE;
53 }
54
55}
Class that models a single animation used by an entity.
A Hit object holds the damage amount and hitsplat data.
Definition Hit.java:10
int getAttackDelay(Player attacker, Mob defender, FightType fightType)
Handles the mob class.
Definition Mob.java:66
This class represents a character controlled by a player.
Definition Player.java:125
Represents different priorities for updating.
The enumerated type whose elements represent the fighting types.