OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: TheCaptain on 04 Sep 2002, 10:01:12
-
It sure ain't in the official command ref.
I know you can add radio commands using triggers, but I want to use them in my scripts, and I want the radio messages to only be active when certain conditions are met. I've seen it used in maps, but I'm not sure if this adding/removing is done with triggers or scripts... can someone shed some light on this? I'd use the search feature, but the forums mysteriously disappeared ;)
By the way, code snippets don't link properly as of yet...
-
Does unitname sidechat "text" not work?
-
if you mean text message the command is
player sidechat "blah blah"
or
player groupchat...
if you mean alpha, bravo... messages you need the command
0 setRadioMessagge "blah blah"
0 is for alpha, 1 for bravo and so on
when you execute it in your radio command list the text blah blah will appear and if you call it it'll send alpha code.
And yes, the both are in the command reference ;D
Hope this helps!
-
simmonRussi is right in Almost everything :P
but its
1 for alpha
2 for bravo
etc
;D
LCD OUT
-
Now, I know you can *add* messages to the map screen, I just don't know how to get rid of them.
Do you do setradio message with blank quotes?
-
simmonRussi is right in Almost everything :P
but its
1 for alpha
2 for bravo
etc
;D
LCD OUT
And its setradiomsg and not setradioMessagge.
If you want it to be blank then use 1 setradiomsg "null"
8)PEACE
-
For the avoidance of doubt, you can do all the good stuff mentioned above in triggers or scripts. A radio message (like when you press 0-0-1 to bring in the tanks) activates a trigger (Radio Alpha in this case) which of course you can use to start a script.
It is quite possible to use conditions in scripts to make the radio messages appear/disappear. (In general of course you will have to use a trigger to make sure the script is running at the time.) Check out the bottom of the official command ref for hints on how to do this. Basically you use a questionmark and a colon for "If ... then" commands. So in your script you would have something like
? dude1 distance tank2 <=17:1 setradiomsg "Help!"
but don't quote me on the syntax.
I didn't know you could add messages to the map screen, how do you do that? If you mean objectives appearing you can make them come and go as much as you like, can't remember the commands but there's a very good wee tute, by snYpir I think, on this site.
-
What about something along the lines of:
For instance you make the scripts ahead of time...just in case a certain trigger gets set.. say a POW extract goes wrong and 'Prisoner1' dies.. you could have a trigger that states:
Condition: not (alive prisoner1)
On activation: [] exec "Prisonerded.sqs"
which all that would be is:
;if prisoner is dead call HQ
aP sideRadio "prisonerded'
exit
If he is not dead then the trigger is never activated..
Is that what you are talking about or something different??
Hope that helps.
YankeeTanker.