1package com.runehive.game.world.entity.combat.projectile;
3import com.runehive.game.Animation;
4import com.runehive.game.Graphic;
5import com.runehive.game.Projectile;
6import com.runehive.game.engine.GameEngine;
7import com.runehive.game.world.World;
8import com.runehive.game.world.entity.combat.CombatImpact;
9import com.runehive.game.world.entity.mob.Mob;
11import java.util.HashMap;
13import java.util.Optional;
14import java.util.OptionalInt;
18 public static final Map<String, CombatProjectile>
definitions =
new HashMap<>();
91 if (
"Ice Barrage".equals(
name) ||
"Ice Burst".equals(
name)
92 ||
"Smoke Barrage".equals(
name) ||
"Smoke Burst".equals(
name)) {
115 return Optional.ofNullable(
effect);
123 return Optional.ofNullable(
start);
127 return Optional.ofNullable(
end);
132 return OptionalInt.empty();
139 return OptionalInt.empty();
Class that models a single animation used by an entity.
Represents a single graphic that can be used by entities.
static int clientTicksToServerTicks(final int clientTicks)
Represents the game world.
static void sendProjectile(Projectile projectile, Position position, int instance, int lock, byte offsetX, byte offsetY)
Sends a world projectile.
Optional< Graphic > getStart()
static CombatProjectile getDefinition(String name)
Optional< Animation > getAnimation()
final Animation animation
int sendProjectile(Mob attacker, Mob defender)
final CombatImpact effect
Optional< CombatImpact > getEffect()
OptionalInt getHitsplatDelay()
CombatProjectile(String name, int maxHit, CombatImpact effect, Animation animation, Graphic start, Graphic end, Projectile projectile)
Optional< Projectile > getProjectile()
Optional< Graphic > getEnd()
final Projectile projectile
OptionalInt getHitDelay()
static final Map< String, CombatProjectile > definitions
CombatProjectile(String name, int maxHit, CombatImpact effect, Animation animation, Graphic start, Graphic end, Projectile projectile, int hitDelay, int hitsplatDelay)
Represents a combat impact hit effect.