JASS boulder trigger help

l-hate_you

New Member
Reaction score
6
ok so basically this is the trigger (im not extremely good at JASS btw)

function Trig_Suffering_Pit_Move_Boulder_Copy_Conditions takes nothing returns boolean
if ( not ( GetSpellAbilityId() == 'A002' ) ) then
return false
endif
return true
endfunction

function Trig_Suffering_Pit_Move_Boulder_Copy_Func002C takes nothing returns boolean
if ( not ( GetRandomInt(1, 10) <= 8 ) ) then
return false
endif
return true
endfunction

function Trig_Suffering_Pit_Move_Boulder_Copy_Func003C takes nothing returns boolean
if ( not ( CountUnitsInGroup(GetUnitsOfPlayerAndTypeId(GetOwningPlayer(GetSpellAbilityUnit()), 'e001')) != 2 ) ) then
return false
endif
return true
endfunction

function Trig_Suffering_Pit_Move_Boulder_Copy_Actions takes nothing returns nothing
loop
exitwhen ( Trig_Suffering_Pit_Move_Boulder_Copy_Func003C() )
loop
exitwhen ( Trig_Suffering_Pit_Move_Boulder_Copy_Func002C() )
call TriggerSleepAction( 0.40 )
endloop
call IssuePointOrderLocBJ( GroupPickRandomUnit(GetUnitsOfPlayerAndTypeId(GetOwningPlayer(GetSpellAbilityUnit()), 'e001')), "move", PolarProjectionBJ(GetUnitLoc(GetSpellAbilityUnit()), GetRandomReal(100.00, 500.00), GetRandomReal(1.00, 360.00)) )
endloop
if ( Trig_Suffering_Pit_Move_Boulder_Copy_Func003C() ) then
return
else
endif
endfunction

//===========================================================================
function InitTrig_Suffering_Pit_Move_Boulder_Jass_2 takes nothing returns nothing
set gg_trg_Suffering_Pit_Move_Boulder_Jass_2 = CreateTrigger( )
call TriggerRegisterAnyUnitEventBJ( gg_trg_Suffering_Pit_Move_Boulder_Jass_2, EVENT_PLAYER_UNIT_SPELL_CAST )
call TriggerAddCondition( gg_trg_Suffering_Pit_Move_Boulder_Jass_2, Condition( function Trig_Suffering_Pit_Move_Boulder_Copy_Conditions ) )
call TriggerAddAction( gg_trg_Suffering_Pit_Move_Boulder_Jass_2, function Trig_Suffering_Pit_Move_Boulder_Copy_Actions )
endfunction

OK, so I made this spell in a blank map and this trigger is a part of it. It picks the boulder units that belong to the caster of the spell (after being created from a separate trigger) and randomly move them around the 500 radius of the caster. They both have permenant immolation so they deal damage as they roll over enemies. This trigger works very well, but I would like to know why when I go to change the boulder unit's raw code from the old map to the new map im importing it into, it makes a big funky error.. so basically i took this JASS trigger, put it into my new map with the same map, but when I change the "e001"s to "h00B:hpea"s and save it, I get a gigantic error that includes like every line of code in the trigger..? :banghead: if you need any more info to unravel the problem please tell me..
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top