Nombre de armas en giveallweapon -
BenjaminT4L - 20.12.2014
Cуmo puedo poner el nombre de las armas en espaсol al dar una arma?
Que dijiera
* Admin BenjaminT4L ha dado recortadas a todos los jugadores!
Код:
dcmd_giveallweapon(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 3) {
new tmp[256], tmp2[256], Index, ammo, weap, WeapName[32], string[128]; tmp = strtok(params,Index), tmp2 = strtok(params,Index);
if(!strlen(tmp) ) return SendClientMessage(playerid, red, "USAGE: /giveallweapon [weapon id/weapon name] [ammo]");
if(!strlen(tmp2) || !IsNumeric(tmp2) || strval(tmp2) <= 0 || strval(tmp2) > 99999) ammo = 500;
if(!IsNumeric(tmp)) weap = GetWeaponIDFromName(tmp); else weap = strval(tmp);
if(!IsValidWeapon(weap)) return SendClientMessage(playerid,red,"* Arma invбlida");
CMDMessageToAdmins(playerid,"GIVEALLWEAPON");
for(new i = 0; i < MAX_PLAYERS; i++) {
if(IsPlayerConnected(i)) {
PlayerPlaySound(i,1057,0.0,0.0,0.0);
GivePlayerWeapon(i,weap,ammo);
}
}
GetWeaponName(weap, WeapName, sizeof(WeapName) );
format(string,sizeof(string),"{7FFF00}* Admin %s ha dado %s a todos los jugadores!", pName(playerid), WeapName, weap, ammo);
return SendClientMessageToAll(blue, string);
} else return SendClientMessage(playerid,red,"* No tienes el sucifiente nivel para usar este comando!");
}
Re: Nombre de armas en giveallweapon -
RedSamp - 20.12.2014
Asi:
pawn Код:
dcmd_giveallweapon(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 3) {
new tmp[256], tmp2[256], Index, ammo, weap, WeapName[32], string[128]; tmp = strtok(params,Index), tmp2 = strtok(params,Index);
if(!strlen(tmp) ) return SendClientMessage(playerid, red, "USAGE: /giveallweapon [weapon id/weapon name] [ammo]");
if(!strlen(tmp2) || !IsNumeric(tmp2) || strval(tmp2) <= 0 || strval(tmp2) > 99999) ammo = 500;
if(!IsNumeric(tmp)) weap = GetWeaponIDFromName(tmp); else weap = strval(tmp);
if(!IsValidWeapon(weap)) return SendClientMessage(playerid,red,"* Arma invбlida");
CMDMessageToAdmins(playerid,"GIVEALLWEAPON");
for(new i = 0; i < MAX_PLAYERS; i++) {
if(IsPlayerConnected(i)) {
PlayerPlaySound(i,1057,0.0,0.0,0.0);
GivePlayerWeapon(i,weap,ammo);
}
}
GetWeaponName(weap, WeapName, sizeof(WeapName) );
format(string,sizeof(string),"{7FFF00}* Admin %s ha dado %s a todos los jugadores!", pName(playerid), WeapName, weap, ammo);
return SendClientMessageToAll(blue, string);
} else return SendClientMessage(playerid,red,"* No tienes el sucifiente nivel para usar este comando!");
}
Respuesta: Nombre de armas en giveallweapon -
jotajeda - 20.12.2014
Facil,
https://sampwiki.blast.hk/wiki/GetWeaponName
Respuesta: Nombre de armas en giveallweapon -
fabianlamas33 - 20.12.2014
їUsas el sistema ladmin?
Si lo usas, debes mirar en el inicio algo asн.. CTRL + F: WeapName(pegar ese y enter) y lo cambias mediante eso..