Warcraft III resources & community, 2003–2006 · archived

Compile Error ???

13 posts
#1

Compile Error ???

I don't use jass, but my trigger keeps giving me a Compile error "Excepted a function name"

and then:

function Trig__Ice_Chamber_Destination_Actions takes nothing returns nothing
call WaygateSetDestinationLocBJ( udg_ICeChamber[GetConvertedPlayerId(GetOwningPlayer(GroupPickRandomUnit(GetUnitsInRectMatching(gg_rct_Ice_Region, Condition(function Trig__Ice_Chamber_Destination_Func001001001001001002)))))], GetUnitLoc(udg_Wendigo[GetConvertedPlayerId(GetOwningPlayer(GroupPickRandomUnit(GetUnitsInRectMatching(gg_rct_Ice_Region, Condition(function Trig__Ice_Chamber_Destination_Func001002001001001001002)))))]) )
endfunction

//===========================================================================
function InitTrig__Ice_Chamber_Destination takes nothing returns nothing
set gg_trg__Ice_Chamber_Destination = CreateTrigger( )
call TriggerRegisterEnterRectSimple( gg_trg__Ice_Chamber_Destination, gg_rct_Ice_Region )
call TriggerAddAction( gg_trg__Ice_Chamber_Destination, function Trig__Ice_Chamber_Destination_Actions )
endfunction
#2
#1 - please use JASS tags if its JASS
#2 - please post it as GUI if its GUI ( like this, for example )
#3 - the WaygateSetDestinationLocBJ function has a comma instead of a bracket at the end...
#3
Whoooo... I understood -1% of all this mess heheh
let me organize this...
function Trig__Ice_Chamber_Destination_Actions takes nothing returns nothing
call WaygateSetDestinationLocBJ( udg_ICeChamber[GetConvertedPlayerId(GetOwningPlayer(GroupPickRandomUnit(GetUnitsInRectMatching(gg_rct_Ice_Region, Condition(function Trig__Ice_Chamber_Destination_Func001001001001001002)))))], GetUnitLoc(udg_Wendigo[GetConvertedPlayerId(GetOwningPlayer(GroupPickRandomUnit(GetUnitsInRectMatching(gg_rct_Ice_Region, Condition(function Trig__Ice_Chamber_Destination_Func001002001001001001002)))))]) )
endfunction

//===========================================================================
function InitTrig__Ice_Chamber_Destination takes nothing returns nothing
set gg_trg__Ice_Chamber_Destination = CreateTrigger( )
call TriggerRegisterEnterRectSimple( gg_trg__Ice_Chamber_Destination, gg_rct_Ice_Region )
call TriggerAddAction( gg_trg__Ice_Chamber_Destination, function Trig__Ice_Chamber_Destination_Actions )
endfunction


(that's what I call a huge line)
now I can analize it better. The only thing I didn't understand (let's say I'm optimist to say "olny") is that I'm not seeing the Conditional Function Trig__Ice_Chamber_Destination_Func001002001001001001002. Maybe PurplePoot can explain it better
#4

Compile Error ???

#1 I didn't write that mess, the world editor did when I built the trigger with the combo boxes it provides
#2 I don't know Jass, my programming skills go as far as Basic and HTML
#3 I just wanna know why it is giving me an error in Jass, when I didn't use any Jass, and how to fix the error

ty for your time
#5
Ok, I was just saying that JASS without JASS tags are difficult to read. You could click the "jass" button while posting, that way the code is easier to understant.

Does the trigger ONLY have that code? If yes, try remaking the action that changes the destination, because by my eyes it's missing a function...
#6
Marcel - Thats the lovely, decipherable name for Filters in Converted GUI-JASS. He didnt seem to include it in this. ( Hello, if you dont have this at all, then thats your problem, Unscrewed )

and...

#1 - You still can use JASS tags - theyre part of the SITE, not Wc3
#2 - Again, why did you Convert to Custom Text?
#3 - The only compile errors I got had to do with the fact i didnt have the variables/functions you used, so make sure you do. ( before, it looked like the comma was replacing a bracked cuz while posting, the Topic Review breaks that monster into 4 lines. )
#7
PurplePoot
#2 - Again, why did you Convert to Custom Text


I didn't, it is still a normal trigger
It just keeps giving me the errors in jass

and I will double check, but I'm sure I have all of the varibles
#8
Ahh yeahh I thing I got it!!
You copied this code from the script that appears with the error, huh?

So, I always solved that problem by remaking the trigger. Maybe if you copy it, delete the original and paste, the problem can be gone.
#9
coppy/paste did not fix it

so, I'm just going to trigger it differently
#10
Last Post DatePosted: Sun Oct 29, 2006 3:36 pm


Meh.

Anyways, raw GUI without any custom script tags will NOT give errors.
#11
Sometimes I got an error using only (and just only) GUI, but with regions and some other things... Then I just cut and pasted the region and OK!
#12
Here's some things to try:

Make sure all the variables it's refering to exist. Typically if you open the trigger up again in the GUI editor, and nothing is in red, then they're fine.

Remake the trigger completely, without any copy and pasting. Then delete the old trigger.

Check the regions being selected. Change them to something else temporarily and see if that makes a difference. Then change it back to the original region.

Other than that, I'm not sure what could be the problem. GUI code usually doesn't give compile errors, but I've seen it give errors before. You could check the trigger immediately before it as well, maybe it's the real culprit.
#13
My new trigger works fine