Jump to content
Sign in to follow this  
Lorenzo

Need help for little questions about scripting

Recommended Posts

hello all,

for a missions i reach good infos about the principe of scripting, i have D/L some documentations but i can't find it .

i have 4 little questions ..

1-i reach how to make a condition like this :

if( a==TRUE ){

action 1

}else{

action 2

}

or the same but in different syntax :

a==TRUE ? action 1 : action 2 ;

i have make differents tests but nothing work .. you know the good syntax ??

------------

2-i reach too, how make a trigger who can detect one and only one precise unit ....

------------

3-other problem ..... how can i move a waypoint with GetPos and SetPos .... i don't find how, i can't assign a variable name to waypoint like trigger or unit ...

------------

4-the last question  smile.gif --> when i put in a variable an array  like this :

array=GetPos unit

i have in array X,Y and Z .... but HOW i can make addition or other calculation just on Z confused.gif

i have try this array[z] and array['z'] but nothing work , you know the good syntax ??

----------

----------

thank's for help .

Share this post


Link to post
Share on other sites

1.

Correct syntax:

?a : action1, goto "next"

action2

#next

2. group (f2) the trigger with the specific unit.

3. the commands are called getwppos and setwppos

Correct syntax:

getwppos [unit, waypointnumber]

the first waypoint is number 0

[unit, waypointnumber] setwppos [positionarray]

4. maybe you should use the select command

array select 2 (for the 3rd value in array)

Share this post


Link to post
Share on other sites

thank's (too biggrin.gif )

there's a good level, help and lively atmosphere on this forum, i like this smile.gif

i just find it smile.gif, it's not in my language but it's good cause i need to work a little english before go Canada biggrin.gif

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×