So I'm trying to re-do my old add-on v18 broke, and I'm trying to re-create the color change command.
$SIAversion = "0.2";
$SIAbuild = "6-6";
$line1c = "FF3344";
$line2c = "FFEE00";
$line3c = "44CC77";
$line4c = "3388FF";
messageAll('',"Executed Server Info Announcer 2 version " @ $SIAversion @ " (build " @ $SIAbuild @ ")");
function getHostsName()
{
$hostsname = $pref::Player::NetName;
}
getHostsName();
function DoSIAAnnounce(%client)
{
$bricks = $Server::BrickCount;
$players = $Server::PlayerCount @ "/" @ $Pref::Server::MaxPlayers;
for(%i = 0; %i < ClientGroup.getCount(); %i++)
{
%cl = ClientGroup.getObject(%i);
%cl.perce = %cl.brickGroup.getCount()/$Server::BrickCount*100;
%cl.perce = mFloatLength(%cl.perce,1);
messageClient(%cl,"","<color:" @ $line1c @ "> >> " @ $hostsname @ "'s " @ $Server::Name);
messageClient(%cl,"","<color:" @ $line2c @ "> >> There are " @ $bricks @ " bricks in the server, " @ %cl.perce @ "% of which are yours.");
messageClient(%cl,"","<color:" @ $line3c @ "> >> There are " @ $players @ " players in the server.");
messageClient(%cl,"","<color:" @ $line4c @ "> >> You have a " @ %cl.getPing() @ " ms. delay with the server.");
}
}
-----> function servercmdSetSIAColor(%client,%servername,%brickcount,%playercount,%playerlag)
{
if(%client.isHost)
{
$line1c = %servername;
$line2c = %brickcount;
$line3c = %playercount;
$line4c = %playerlag;
messageAll('',"<color:00ffff>" @ $hostsname @ " has changed the announcer colors to " @ %servername @ ", " @ %brickcount @ ", " @ %playercount @ ", and " @ %playerlag @ ".");
}
}
And it does absolutely nothing.