options: passiveChance: 50 passiveCooldown: 20 seconds blindTime: 5 seconds glowTime: 5 seconds abilityCooldown: 60 seconds abilityDamage: 32 # GIVE ITEM command /aydencrossbow: trigger: give player crossbow named "&5✦ &dAyden's Crossbow &5✦" with lore "&8&m-------------------------", "&d☯ Passive: &5Blind Spot", "&7➤ 50% chance on arrow hit", "&7➤ Blind + reveal enemies", "&7➤ Deals &d2x arrow damage", "&7➤ Cooldown: &d20s", "", "&5⚡ Ability: &dWarden's Favor", "&7➤ Double Shift to unleash", "&7➤ Warden Sonic Power", "&7➤ Cooldown: &d60s", "&8&m-------------------------" # =============================== # PASSIVE # =============================== on damage of player: attacker is a projectile shooter of attacker is a player set {_p} to shooter of attacker if lore of {_p}'s tool contains "Blind Spot": if {blindcd::%{_p}%} is set: stop chance of {@passiveChance}%: set {blindcd::%{_p}%} to true # 2x DAMAGE set damage to damage * 2 apply blindness to victim for {@blindTime} apply glowing to victim for {@glowTime} # PURPLE PARTICLES loop 15 times: spawn 3 of redstone dust colored purple at victim send action bar "&d☯ Blind Spot activated!" to {_p} wait {@passiveCooldown} delete {blindcd::%{_p}%} # =============================== # DOUBLE SHIFT # =============================== on toggle sneak: if player is sneaking: if {shift::%player%} is set: delete {shift::%player%} trigger ayden ability for player else: set {shift::%player%} to true wait 10 ticks delete {shift::%player%} # =============================== # ABILITY # =============================== function ayden ability(p: player): if p's tool is not crossbow: stop if lore of p's tool does not contain "Warden's Favor": stop if {abilitycd::%p%} is set: send action bar "&cWarden's Favor on cooldown!" to p stop if p's tool is not charged: send action bar "&cLoad your crossbow!" to p stop set {abilitycd::%p%} to true set {_t} to target entity of p within 30 blocks if {_t} is set: damage {_t} by {@abilityDamage} apply slowness 4 to {_t} for 3 seconds apply glowing to {_t} for 3 seconds # LIGHT SONIC EFFECT play sound "entity.warden.sonic_boom" at p spawn 20 of soul at {_t} send action bar "&5⚡ Warden's Favor used!" to p # COOLDOWN TIMER (ACTION BAR) loop 60 times: set {_time} to 60 - loop-number send action bar "&5Cooldown: &d%{_time}%s" to p wait 1 second delete {abilitycd::%p%}