16.09.2015, 02:51
PHP код:
CMD:criarclan(playerid, params[])
{
new nomeclan[13], tagclan[4], stringclan[128], String[128];
if(sscanf(params, "s[4]s[13]", tagclan, nomeclan)) return SendClientMessage(playerid, -1, " Use: /criarclan [TAG] [Nome] ");
//if(sscanf(tagclan) > 4) { return SendClientMessage(playerid, -1, "{1E90FF} A TAG Estб Muito Grande. Max 4 Letras"); }
format(stringclan, sizeof(stringclan), "{00688B}[CLANS]{FFFFFF} Tag:[{00688B}%s{FFFFFF}] Clan:[{00688B}%s{FFFFFF}] Criado Com Sucesso Por {00688B}%s", tagclan, nomeclan, PlayerName(playerid));
SendClientMessageToAll(-1, stringclan);
if(DOF2_FileExists(String))
{
SendClientMessage(playerid, -1, " Esta TAG De Clan Ja Existe ");
}
format(String, sizeof(String), PASTA_CLANS, tagclan);
DOF2::CreateFile(String);
DOF2::SetString(String,"Nome Do Clan", nomeclan);
DOF2::SetString(String,"Criador", PlayerName(playerid));
DOF2::SetString(String,"Vaga01", "Ninguem");
DOF2::SetString(String,"Vaga02", "Ninguem");
DOF2::SetString(String,"Vaga03", "Ninguem");
DOF2::SetString(String,"Vaga04", "Ninguem");
DOF2::SetString(String,"Vaga05", "Ninguem");
DOF2::SaveFile();
return 1;
}