OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Multiplayer => Topic started by: demon of evil on 19 Dec 2002, 19:57:17

Title: need a script
Post by: demon of evil on 19 Dec 2002, 19:57:17
hi there

I need a script for mp that the one who activated the script his name will be in white in the middle of the screen.

this is used for a race mission and the one who wins will be displayed on the screen like this: player has won the race

bye
Title: Re:need a script
Post by: Ranger on 20 Dec 2002, 19:37:52
I don't know how to display a player's real name (e.g., Ranger), but I do know how to display a player's group name (e.g., Alpha Black 1).

For the latter, if that'll suffice for you, you need to use the format command.  E.g.:

Code: [Select]
hint format ["%1 has won the race!",_this]

Where _this is the parameter that was passed into your script.

You can also use this with the titleText command.

Code: [Select]
titleText [format [""%1 has won the race!"",_this], "PLAIN"]