本帖最后由 蘑菇 于 2014-3-15 12:32 编辑
function c takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'AUan' ) ) then
return false
endif
return true
endfunction
function d takes nothing returns nothing
call BB()
endfunction
//===========================================================================
function InitTrig_a takes nothing returns nothing
set b = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( b, EVENT_PLAYER_UNIT_SPELL_EFFECT )
call AA()
//AA()只运行了一次
call TriggerAddCondition( b, Condition( function c) )
call TriggerAddAction( b, d )
/*如果在这里记录条件和动作只显示一次,不知在d里再次输入{。。。。}算不算动态注册
{ set ? = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( ?, EVENT_PLAYER_UNIT_SPELL_EFFECT ) call TriggerAddCondition( ?, Condition( function ??) )
call TriggerAddAction( ?, 动作)
call saveTriggerCondition(??)
call saveTriggerAction(?)}
*/
endfunction
|