xAnaMorphine
Active Member
- Reaction score
- 43
After 3 hours of intensive searching and trying in the WE :banghead: , I gave up.
Now I want to ask you guys , if you could answer and tell me how to get a simple Spellbook working <3.
That's how it looks like:
It leaks, and I know why, but I don't know how to fix it :O
It attaches the skill to the Hero skill panel but not into the Spellbook, why? :nuts:
Now I want to ask you guys , if you could answer and tell me how to get a simple Spellbook working <3.
That's how it looks like:
Code:
function Trig_TestSkill2_Conditions takes nothing returns boolean
if ( not ( GetTriggerUnit() == GetLevelingUnit() ) ) then
return false
endif
if ( not ( GetUnitLevel(GetLevelingUnit()) == 3 ) ) then
return false
endif
return true
endfunction
function Trig_TestSkill2_Actions takes nothing returns nothing
call UnitAddAbilityBJ( 'AHbz', GetTriggerUnit() )
call UnitRemoveAbilityBJ( 'AHbz', GetTriggerUnit() )
call UnitAddAbilityBJ( 'A004', GetTriggerUnit() )
endfunction
//===========================================================================
function InitTrig_TestSkill2 takes nothing returns nothing
set gg_trg_TestSkill2 = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_TestSkill2, EVENT_PLAYER_HERO_LEVEL )
call TriggerAddCondition( gg_trg_TestSkill2, Condition( function Trig_TestSkill2_Conditions ) )
call TriggerAddAction( gg_trg_TestSkill2, function Trig_TestSkill2_Actions )
endfunction
It leaks, and I know why, but I don't know how to fix it :O
It attaches the skill to the Hero skill panel but not into the Spellbook, why? :nuts: