Jump to content
  • 0

Mission Messages and help


MG-Maximus

Question

Hi,

 

I'm looking to change messages that appear on screen in my server so that they dont clog up the center of screen and distract players who just want to battle. At the moment im using WAI and believe that it uses the rTitleText format to display in the centre of the screen. What would the format be for displaying this in the top centre of the screen maybe with color? (i've seen this on other servers).

 

Furthermore, when you have the gear menu open and a message pops up (e.g, scan area from gps) the message is hidden by the gear menu and if you drag the gear menu up, all other right click options now have a large gap when you select them. How would i go about altering these messages so that they either appear at the top or just below the gear menu or similar?

 

Any help much appreciated.

 

Thanks

Max

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

For colored text you would need to use BIS_fnc_dynamicText.

You cannot remote execute that function like you can with titleText so you would have to create a clientside publicVariableEventHandler. I'll give a brief example-

 

Serverside, replace the standard rTitleText calls with this-

myPublicVariable = "Some text for the mission!";   // Can be structured text, so you can use colors, change the size, font etc.
publicVariable "myPublicVariable"; // Send the string to clients.

Clientside, in a new file-

"myPublicVariable" addPublicVariableEventHandler
{
    private ["_text"];
    _text = _this select 1; // _this select 0 contains the actual name of the variable, so it's no use for us here.
    [_text,x position,y position,duration, fade in time] spawn BIS_fnc_dynamicText;
};

I'm quite sure this will work as is, but please, be sure to check if it works properly before blindly commiting to it. That is if you decide to use this.

Because everyone's screen size and/or resolution may be different use the safezone variables to help you position the text properly.

If you're unfamiliar with the format of stuctured text head here and for hexadecimal color codes for structured text check this site out.

Link to comment
Share on other sites

  • 0

Works great ty Cordlass. Do you where i would get the call for epoch messages that display in the centre so that I could change the coordinates for them too? Also, would you happen to know the code for displaying messages in side chat. I'm just trying to test different ones to tidy up the messages a bit and clear the interface. Thanks!

Link to comment
Share on other sites

  • 0

The standard Epoch on-screen messages use titleText. This only has two possible positions, "PLAIN" in the middle of the screen or "PLAIN DOWN" near the bottom of the screen. As for finding the calls for the Epoch messages to appear, sheeeesh, there's a lot of them spread among a lot of files, I have no idea of the exact places of pretty much any of them. I understand why you'd love to tidy them up a bit though, I hate the titleText function. So ugly!  As for sideChat, there you go.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...