if(isPackage(newPing))
deactivatepackage(newPing);
package newPing
{
function NMH_Type::Send(%this)
{
%w=firstWord(%this.getValue()) ;
if(%w $= "/myping" || %w$= "/ping")
{
onTraceRecieved("<font:impact:20>\c4Ping\c6: "@serverconnection.getPing());
canvas.popDialog(NewMessageHud);
return;
}
Parent::send(%this);
if(%w $= "!myping" || %w $= "!ping")
commandtoserver('messagesent',"Ping: "@serverconnection.getPing());
}
};
activatepackage(newPing);
!ping and !myping will send a chat message of your ping
/ping and /myping will send only you message saying your ping
Please don't be an idiot with this.. only use /ping or /myping
I included the !ping only for you to learn...
to package, place the text with the fancy font in a file and save it as "client.cs" in an add-on called "Client_Ping"
make sure you have a file called "description.txt" in that folder as well