mirror of
https://github.com/2006-Scape/apollo.git
synced 2026-07-04 00:38:11 +00:00
Add ranged combat support
* Clean up the CombatAction and Attack code to make it easier to use for range. * Add collision detection to the distance checks before attacking in the CombatAction. * Create a Ruby DSL for defining projectile types and fix the ProjectileUpdateOperation so it uses the correct position offset. * Fix the packet structure of the HintIconMessageEncoder.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
##
|
||||
# The delay a <i>Mob</i> must wait before attacking again.
|
||||
declare_attribute(:attack_delay, 0)
|
||||
# The number of ticks since a <i>Mob<i>s last attack.
|
||||
declare_attribute(:attack_timer, 100)
|
||||
|
||||
##
|
||||
# A flag indicating whether this <i>Mob</i> is currently in combat.
|
||||
@@ -22,6 +22,10 @@ declare_attribute(:combat_style, 0, :persistent)
|
||||
# A flag indicating whether the special bar is flagged for the next attack.
|
||||
declare_attribute(:using_special, false, :persistent)
|
||||
|
||||
##
|
||||
# A flag indicating whether auto retaliation is enabled.
|
||||
declare_attribute(:auto_retaliate, true, :persistent)
|
||||
|
||||
##
|
||||
# An integer between 0 and 100 indicating the amount of special energy a <i>Player</i> has.
|
||||
declare_attribute(:special_energy, 100, :persistent)
|
||||
|
||||
Reference in New Issue
Block a user