From 964c95b572ed55c8d1f41d68bb13a64135c44da3 Mon Sep 17 00:00:00 2001 From: randy Date: Wed, 13 Nov 2024 15:21:17 -0700 Subject: [PATCH] Fixed noncombat spells getting the 33% chance to not use runes. --- .../main/core/game/node/entity/combat/spell/MagicSpell.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Server/src/main/core/game/node/entity/combat/spell/MagicSpell.java b/Server/src/main/core/game/node/entity/combat/spell/MagicSpell.java index 6259add5a..86b7e1260 100644 --- a/Server/src/main/core/game/node/entity/combat/spell/MagicSpell.java +++ b/Server/src/main/core/game/node/entity/combat/spell/MagicSpell.java @@ -201,9 +201,9 @@ public abstract class MagicSpell implements Plugin { if (!checkLevelRequirement(caster, message)) { return false; } + /* Snowscape custom. Removing this allows guthix staff to autocast claws of guthix. if (caster instanceof Player) { CombatSpell spell = ((Player) caster).getProperties().getAutocastSpell(); - /* Snowscape custom. Removing this allows guthix staff to autocast claws of guthix. if (spell != null) { boolean slayer = ((Player) caster).getEquipment().get(3).getName().contains("layer's staff"); boolean voidKnight = ((Player) caster).getEquipment().get(3).getName().contains("knight mace"); @@ -212,8 +212,8 @@ public abstract class MagicSpell implements Plugin { return false; } } - */ } + */ if((spellId == 12 || spellId == 30 || spellId == 56) && caster instanceof Player){ if (caster.getAttribute("entangleDelay", 0) > GameWorld.getTicks()) { caster.asPlayer().sendMessage("You have recently cast a binding spell."); @@ -223,7 +223,7 @@ public abstract class MagicSpell implements Plugin { if (caster instanceof Player) { Player p = (Player) caster; //if(p.getEquipment().get(3) != null && p.getEquipment().get(3).getId() == 14726){ - if(RandomFunction.getRandom(100) > 33){ + if(this instanceof CombatSpell && RandomFunction.getRandom(100) > 33){ //p.sendMessage("Your staff negates the rune requirement of the spell."); return true; }