tbox1911 / Liberation-RX

ArmA 3 - Liberation RX - Mission
GNU General Public License v3.0
64 stars 61 forks source link

How to show MOTD in the game? #136

Closed rushfly closed 1 year ago

rushfly commented 1 year ago

The MOTD I defined in server.cfg can't displayed in game. And I sure the format of message is right. Or should I figure it out through another way?

Varrkan82 commented 1 year ago

If you're sure the format is right - it should be displayed. How you suppose it should be shown?

tbox1911 commented 1 year ago

as an example, here what I use in my server.cfg

motd[] = { "","", "","", "","", "","", "Welcome to my Liberation Arma 3 Server","", "","", "You are looking for fun ?- Join us Now !", "","", "Only firendly people allowed !!","", "","" }; motdInterval = 5;

note: The display of the motd is fully managed by the arma server, the mission itself has nothing to do

Varrkan82 commented 1 year ago

Just notice - MOTD displayed as a line in a text chat. Line length is limited. motdInterval is a parameter, which regulates an interval between displaying an each line of text.

rushfly commented 1 year ago

Thank you for all of your answers! I have some other questions. What is the length limit for a line? Does it support non-ASCII character sets?

tbox1911 commented 1 year ago

I don't know the max size, I think it's ascii only, but you can try others character sets. plz report if it work

Varrkan82 commented 1 year ago

Thank you for all of your answers! I have some other questions. What is the length limit for a line? Does it support non-ASCII character sets?

Chat messages are transferred as a String. From this https://community.bistudio.com/wiki/String we see it has a limit in 10M characters and encoded with Unicode. It supports non-ASCII symbols, but message length decreased dramatically if you do so. From my experience - it will be limited just around a 30-50 symbols per line. Just to be honest - I've never tried to check a real length using ASCII symbols ))