- Joined
- Jun 11, 2009
- Messages
- 151
PHP:
function Trig_Tunnel_Home_Conditions takes nothing returns boolean
return(GetSpellAbilityId()=='A0ET')
endfunction
--->function Kobold Mine Shaft takes nothing returns boolean<---
return(GetUnitTypeId(GetFilterUnit())=='e015')
endfunction
function Trig_Tunnel_Home_Actions nothing returns nothing
call ShowUnitHide( GetTriggerUnit() )
local unit u=GetTriggerUnit()
local unit t
local group g=CreateGroup()
local boolexpr b=Condition(function Kobold Mine Shaft)
call GroupEnumUnitsOfPlayer(g,GetOwningPlayer(u),b)
call DestroyBoolExpr(b)
set t=GroupPickRandomUnit(g)
call DestroyGroup(g)
call SetUnitVertexColor(u, 255, 255, 255, 100)
call PolledWait (1.00)
call DestroyEffect(AddSpecialEffect("Doodads\LordaeronSummer\Terrain\LoardaeronRockChunks\LoardaeronRockChunks1.mdl",GetUnitX(u),GetUnitY(u)))
call SetUnitPositionLoc(u,GetUnitLoc(t))
call DestroyEffect(AddSpecialEffect("Doodads\LordaeronSummer\Terrain\LoardaeronRockChunks\LoardaeronRockChunks1.mdl",GetUnitX(u),GetUnitY(u)))
call SetUnitVertexColor(u, 255, 255, 255, 255)
call ShowUnitShow( GetTriggerUnit() )
call SelectUnitForPlayerSingle( GetTriggerUnit(), GetOwningPlayer(GetTriggerUnit()) )
set t=null
set u=null
set g=null
set b=null
endfunction
function InitTrig_Tunnel_Home takes nothing returns nothing
set gg_trg_Tunnel_Home = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Tunnel_Home, EVENT_PLAYER_UNIT_SPELL_CAST )
call TriggerAddCondition( gg_trg_Tunnel_Home, Condition( function Trig_Tunnel_Home_Conditions ) )
call TriggerAddAction( gg_trg_Tunnel_Home, function Trig_Tunnel_Home_Actions )
endfunction
Around the top the one i wrote ---> <---
every time i save this pops up. "Line 5252: Expected: "Takes"
And i can't figure out how to fix it.