Anyone know?
Int BuildUpLevel = 0Function AdToBuildup(int Powerlevel)EndFunctionAuto State OutOfCombat event OnStateBegin() BuildUpLevel = 0 ; Code to disable all but "Starter" abilities here. EndEvent Function AddToBuildUp(int PowerLevel) ; Needs to be defined in all states. EndFunction Event OnCombatStateChanged(Actor Who, Int What) BuildUpLevel = 3 - What ; Gets +2 if entering combat, but only +1 if "searching" GoToState("CombatStart") EndEventEndStateState CombatStart Function AddToBuildUp(int PowerLevel) ; Call this from each of the High (3) low (1) and mid(2) level effects. BuildUpState += PowerLevel If BuildUpState >= 5 GoToState("CombatLevel5") EndIf EndFunctionEndStateState CombatLevel5 event OnStateBegin() ; Code to enable mid level abilities here. EndEvent Function AddToBuildUp(int PowerLevel) BuildUpState += PowerLevel If BuildUpState >= 15 GoToState("CombatLevel15") EndIf EndFunctionEndStateState CombatLevel15 event OnStateBegin() ; Code to enable High level abilities here. EndEvent Function AddToBuildUp(int PowerLevel) BuildUpState += PowerLevel If BuildUpState >= 20 GoToState("CombatStart") EndIf EndFunctionEndStateScriptname SpellCoolDown extends ActiveMagicEffect Int Property time Auto SPELL Property Move Auto event OnEffectStart(Actor akTarget, Actor akCaster) akCaster.removespell(Move) akCaster.UnequipSpell(Move, 1) akCaster.UnequipSpell(Move, 0) Utility.Wait(time) akCaster.addspell(Move)endEvent
Scriptname GiveSpells extends ActorSpell Property Spell01 AutoSpell Property Spell02 AutoSpell Property Spell03 AutoSpell Property Spell04 AutoInt Property Time AutoEvent OnCombatStateChanged (Actor akTarget, int aeCombatState) if (aeCombatState == 1) Self.AddSpell (Spell01) Self.AddSpell (Spell02) Self.AddSpell (Spell03) Self.AddSpell (Spell04) endIfendEventEvent OnSpellCast (Form akSpell) Self.RemoveSpell (akSpell as Spell) Utility.Wait (Time) Self.AddSpell (akSpell as Spell)endEvent