Rizalgar Posted December 30, 2018 Share Posted December 30, 2018 (edited) Okay, TripleSixes is a busy person, which is entirely understandable... SO! I'm here to ask you guys :smile:. Am I calling this from the wrong location or something? I cannot seem to get it to Unequip the spell when not having the proper items. The only thing I can think of is calling an If statement for each required item, but he used the same formula in his other spells and they worked without a hitch. So, any clues, super awesome scripters in the Skyrim community? Before it gets asked, everything in the script works flawlessly minus the Unequip, it's the only thing here I'm having trouble with. Part not working is asterisked. Scriptname RS_Spell_FireBolt_Script extends activemagiceffect {Fire Bolt script} Spell Property FireBolt Auto MiscObject Property AirRune Auto MiscObject Property ChaosRune Auto MiscObject Property FireRune Auto Event OnSpellCast(Form akSpell) EndEvent Event OnEffectStart(Actor akTarget, Actor akCaster) If akCaster == Game.GetPlayer() Int AirRuneCt = Game.GetPlayer().GetItemCount(AirRune) Int ChaosRuneCt = Game.GetPlayer().GetItemCount(ChaosRune) Int FireRuneCt = Game.GetPlayer().GetItemCount(FireRune) ***** If AirRuneCt < 3 && ChaosRuneCt < 1 && FireRuneCt < 4 Game.GetPlayer().UnequipSpell(FireBolt, 0) Game.GetPlayer().UnequipSpell(FireBolt, 1) ***** Else Game.GetPlayer().RemoveItem(AirRune, 3) Game.GetPlayer().RemoveItem(ChaosRune, 1) Game.GetPlayer().RemoveItem(FireRune, 4) Int damage = Utility.RandomInt(1,12) akTarget.DamageActorValue("Health", damage) Float BaseXP = 22.5 Float ModMagicXP = ((BaseXP) + damage) rsFrameworkMenu.rsXPGain("magic", ModMagicXP) EndIf EndIf EndEvent Edited December 30, 2018 by Rizalgar Link to comment Share on other sites More sharing options...
Rizalgar Posted December 30, 2018 Author Share Posted December 30, 2018 Can be closed. Link to comment Share on other sites More sharing options...
Recommended Posts