Code:
new g_Switch; //First we create a socalled variable.
public plugin_init()
{
register_plugin("Show Motd", "1.0", "SavSin/Raphero");
register_clcmd("say /motd", "motd");
register_clcmd("say /recruit", "recruit");
register_clcmd("say /rules", "rules");
//fill in the variable we made before...
g_Switch = register_cvar("amx_motd","1");
}
public motd(id)
{
//If we have recieved a positive value(either 1 or higher)
if(get_pcvar_num(g_Switch))
{
show_motd(id, "czero/motd.txt", "Motd");
return;
}
}
__________________