Jump to content

[RELEASE] Custom Admin Messages


Reaper5150

Recommended Posts

Simple little script I made allowing admins to send a server wide message to players when they login.

 

[Install]

Can be customized to your liking!

Get a sound you like and convert it to .ogg file and place where your sounds are.

Create .sqf and name something like adminlogin.sqf

Simply call from your init.sqf at the bottom put  execVM "scripts\adminlogin.sqf";

 

[The script]

/////////////////////////////////////////////////////////
/////////Written by Reaper5150/////////////////
/////////////////////////////////////////////////////////

private ["_uid","_adlogin"];

waitUntil {(getPlayerUID player) != ""};
_uid = getPlayerUID player;

_adlogin = [
    "0", // <<your admins uids and names after the "//"
    "0", //
    "0", //
    "0" // Don't add comas at the end
];

if (_uid in _adlogin) then { 
[nil, player, rSAY, "Alert", 50000] call RE; <<YOUSOUND.OGG <<Lower "50000" to 100-200 if you choose
[nil, nil, rTitleText, format["<Server name here>: AN ADMIN HAS JUST LOGGED IN:"], "PLAIN"] call RE; // Message the whole server
sleep 10;
[nil, nil, rTitleText, format["<ADMIN MESSAGE>: YOU WILL BE WATCHED FOR USE OF CHEATS AND RULE BREAKING!!!"], "PLAIN"] call RE; // Message the whole server
sleep 10;
[nil, nil, rTitleText, format["<ADMIN MESSAGE>: IF YOU REQUIRE ASSISTANCE? PLEASE ASK THE ADMIN FOR HELP!"], "PLAIN"] call RE; // Message the whole server
};

 

[In description.ext] add

class CfgSounds {
    sounds[] = {Alert};
        class Alert {
            name="Alert";
            sound[]={dayz_code\sounds\Alert.ogg,0.9,1};
            titles[] = {};
        };

 

 

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...