Ok here is what I done to test this. I made a new map. Made 2 regions and then made a trigger that moved unit from region 1 to region 2 upon entering the region.
------------------------------------------------------------------------------------
function Trig_test_Actions takes nothing returns nothing
call SetUnitPositionLoc( GetTriggerUnit(), GetRectCenter(gg_rct_Region_001) )
endfunction
//===========================================================================
function InitTrig_test takes nothing returns nothing
set gg_trg_test = CreateTrigger( )
call TriggerRegisterEnterRectSimple( gg_trg_test, gg_rct_Region_000 )
call TriggerAddAction( gg_trg_test, function Trig_test_Actions )
endfunction
------------------------------------------------------------------------------------
I just copy and pasted everything into the custom text panel like you said on this new map. and i get these 3 compile errors.
"set gg_trg_test = CreateTrigger( )" -Expected a variable Name
"call TriggerRegisterEnterRectSimple( gg_trg_test, gg_rct_Region_000 )" - Expected a Name
"call TriggerAddAction( gg_trg_test, function Trig_test_Actions )"-Expected a name.
so those 3 erros no those 3 lines is the error im getting. And thats on a brand new map with nothing on it but the 2 regions i made. I declared no variables. By the way thanks for the help.