fireplace Posted February 9, 2014 Report Share Posted February 9, 2014 Is there anyway of showing when a players joins the game? You get a message when a player battlelogs, which is in server_onPlayerDisconnect.sqf. // Message whole server when player combat logs _message = format["PLAYER COMBAT LOGGED: %1",_playerName]; [nil, nil, rTitleText, _message, "PLAIN"] call RE; Would it be possible to have like _message = format["PLAYER %1",_playerName joined the game]; Whenever someone loads in, even from lobby? I'm not even sure when to start looking tbh :-/ Link to comment Share on other sites More sharing options...
0 Judge Bread Posted February 10, 2014 Report Share Posted February 10, 2014 This doesn't seem impossible. There are probably a few ways to do this. You could use the server_playerLogin file to set a variable and publicly broadcast it to all players and then use a public variable event handler to write the information in chat. OR use something like this http://epochmod.com/forum/index.php?/topic/1026-server-side-hintglobalchat-fix-deathmsg-fix/ to directly send a message to all players when a player logs in. Link to comment Share on other sites More sharing options...
0 Achmed Posted February 10, 2014 Report Share Posted February 10, 2014 If you remove the system channel from being disabled then it will show in there. to do this, edit your description.ext file and remove channel 6 from the disabled channels disableChannels[]={0,2,6}; Link to comment Share on other sites More sharing options...
0 Skaronator Posted February 10, 2014 Report Share Posted February 10, 2014 This should work fine. Add it to your server functions server_onPlayerConnect = { private ["_playerUID","_playerName"]; _playerUID = _this select 0; _playerName = _this select 1; _message = format["PLAYER CONNECTED: %1",_playerName]; [nil, nil, rTitleText, _message, "PLAIN"] call RE; }; onPlayerConnected {[_uid,_name] call server_onPlayerConnect;}; Link to comment Share on other sites More sharing options...
0 fireplace Posted February 10, 2014 Author Report Share Posted February 10, 2014 This should work fine. Add it to your server functions server_onPlayerConnect = { private ["_playerUID","_playerName"]; _playerUID = _this select 0; _playerName = _this select 1; _message = format["PLAYER CONNECTED: %1",_playerName]; [nil, nil, rTitleText, _message, "PLAIN"] call RE; }; onPlayerConnected {[_uid,_name] call server_onPlayerConnect;}; Didn't seem to work, on first connecting I got "PLAYER CONNECTED _ _Server_ _". I tried logging off back to desktop and logging back on and no message came up at all. Was cool seeing player connected come up when I first logged on through! Link to comment Share on other sites More sharing options...
0 fr1nk Posted February 10, 2014 Report Share Posted February 10, 2014 If you remove the system channel from being disabled then it will show in there. to do this, edit your description.ext file and remove channel 6 from the disabled channels disableChannels[]={0,2,6}; This is probably the quickest/easiest way. Link to comment Share on other sites More sharing options...
Question
fireplace
Is there anyway of showing when a players joins the game? You get a message when a player battlelogs, which is in server_onPlayerDisconnect.sqf.
Would it be possible to have like
_message = format["PLAYER %1",_playerName joined the game];
Whenever someone loads in, even from lobby? I'm not even sure when to start looking tbh :-/
Link to comment
Share on other sites
5 answers to this question
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now