A
alzidaney
Guest
Ok newbie to this forum and to JASS as well. I'm making use of someone's free code posted in the free trigger code thread.
His definition for the code function I used is as follows
Now, below here is what I attempted to do with the function. (OBviously its wrong. Its part of the whole trigger code btw.)
The error shows in the line
It says that "Expected Code Statement". Im lost. Totally. I tried searching around this forum but to no avail.
His definition for the code function I used is as follows
Code:
function GetNearestUnitMatching takes real sourceX, real sourceY, real range, boolexpr cond, boolean considerdead returns unit
Now, below here is what I attempted to do with the function. (OBviously its wrong. Its part of the whole trigger code btw.)
Code:
function IsEnemy takes nothing returns boolean
local unit nextunit = GetEnumUnit()
return GetOwningPlayer(nextunit) == GetOwningPlayer(udg_Summoned)
endfunction
function Trig_Tornado_Effect_Actions takes nothing returns nothing
local unit nearest
//local boolexpr bolexpr =
nearest = call GetNearestUnitMatching(GetLocationX(GetUnitLoc(GetSummonedUnit())), GetLocationY(GetUnitLoc(GetSummonedUnit())), 125, Condition(IsEnemy) , false)
endfunction
The error shows in the line
Code:
nearest = call GetNearestUnitMatching(GetLocationX(GetUnitLoc(GetSummonedUnit())), GetLocationY(GetUnitLoc(GetSummonedUnit())), 125, Condition(IsEnemy) , false)
It says that "Expected Code Statement". Im lost. Totally. I tried searching around this forum but to no avail.