Tar-Quaeron
New Member
- Reaction score
- 0
Could anybody tell me what is wrong with this?
Thx so much,
JASS:
function VenomSplash takes nothing returns nothing
call CreateNUnitsAtLocFacingLocBJ(1, 039;h00Z039;, GetOwningPlayer(GetAttacker()), GetUnitLoc(GetEnumUnit()), GetUnitLoc(GetEnumUnit()))
call UnitApplyTimedLifeBJ(1.00, 039;BTLF039;, GetLastCreatedUnit())
call IssueTargetOrderBJ(GetLastCreatedUnit(), "attack", GetEnumUnit())
endfunction
function Ennemy takes nothing returns boolean
//Apparently there is a problem with this line
return ( IsUnitEnnemy(GetFilterUnit(), GetOwningPlayer(GetAttacker())) == true )
endfunction
//and this line
function Murloc_Venom_Actions takes nothing returns nothing
local unit VenomAff
if GetUnitTypeId(GetAttacker()) == 039;o00W039; then
set VenomAff = GetAttackedUnitBJ()
call SetUnitMoveSpeed(VenomAff, 0.925 * GetUnitMoveSpeed(VenomAff))
call ForGroupBJ(GetUnitsInRangeOfLocMatching(90.00, GetUnitLoc(VenomAff), Condition(function Ennemy)), function VenomSplash)
call TriggerSleepAction(6)
call SetUnitMoveSpeed(VenomAff, 1.081 * GetUnitMoveSpeed(VenomAff))
endif
if GetUnitTypeId(GetAttacker()) == 039;o00X039; then
set VenomAff = GetAttackedUnitBJ()
call SetUnitMoveSpeed(VenomAff, 0.85 * GetUnitMoveSpeed(VenomAff))
call TriggerSleepAction(6)
call SetUnitMoveSpeed(VenomAff, 1.176 * GetUnitMoveSpeed(VenomAff))
endif
if GetUnitTypeId(GetAttacker()) == 039;o00Y039; then
set VenomAff = GetAttackedUnitBJ()
call SetUnitMoveSpeed(VenomAff, 0.775 * GetUnitMoveSpeed(VenomAff))
call TriggerSleepAction(6)
call SetUnitMoveSpeed(VenomAff, 1.2903 * GetUnitMoveSpeed(VenomAff))
endif
endfunction
//===========================================================================
function InitTrig_Murloc_Venom takes nothing returns nothing
set gg_trg_Murloc_Venom = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ(gg_trg_Murloc_Venom, EVENT_PLAYER_UNIT_ATTACKED)
call TriggerAddAction(gg_trg_Murloc_Venom, function Murloc_Venom_Actions)
endfunction
Thx so much,