Me ayudan con esto? xD
#1

Weno, miren uso el sistema de ConNexiONMeX i Infierno i tngo el bug de /SayOn, /SayOff i tmbn cuando pongo /kick id razon qiero q me aparesca la id... yo puc esto

Код:
dcmd_kick(playerid,params[])
{
    if(PlayerInfo[playerid][Nivel] >= 2)
	{
   		new id;
   		new razon;
	   	if(sscanf(params, "uz", id, razon))
	   	{
	   		SendClientMessage(playerid, Naranja, "Usa: /Kick <ID> <Razуn>");
		}
		else if(IsPlayerConnected(id) && id != INVALID_PLAYER_ID && id != playerid) return SendClientMessage(playerid, Rojo, "[[Info]] Jugador no Conectado");
		else
		{
 			new string[256],Nombre[24],ANombre[24]; GetPlayerName(playerid,Nombre,24); GetPlayerName(id,ANombre,24);
	 		format(string,256,"*** %s (id:%d) Fue expulsado por un admin. Razуn: %s",Nombre,id,razon);
			SendClientMessageToAll(0xAA3333AA,string);
			Kick(playerid);
		}
	} else {
 	SendClientMessage(playerid, Rojo,"[[Info]] Lo sentimos no eres Admin");
 	}
 	return 1;
}
Pero no me sale la id :S me dice id 168 algo asi, lo mismo para /ban aver si me ayudan
Reply
#2

pawn Код:
dcmd_kick(playerid,params[])
{
     if(PlayerInfo[playerid][Nivel] >= 2)
     {
          new id;
          new razon[80];
          if(sscanf(params, "us[80]", id, razon))//es "u" user - "s" string y la longitud de la string
          {
               SendClientMessage(playerid, Naranja, "Usa: /Kick <ID> <Razуn>");
          }
          else if(IsPlayerConnected(id) && id != INVALID_PLAYER_ID && id != playerid) return SendClientMessage(playerid, Rojo, "[[Info]] Jugador no Conectado");
          else
          {
               new string[128],Nombre[MAX_PLAYER_NAME],ANombre[MAX_PLAYER_NAME];//porquй usar strings de 256 si lo mбximo de SendClientMessage son 128 celdas
               GetPlayerName(id,Nombre,sizeof(Nombre));//ha quien quieres kickear
               GetPlayerName(playerid,ANombre,sizeof(ANombre));//el admin que kickea, no al revйs
               format(string,sizeof(string),"*** %s (id:%d) Fue expulsado por un admin. Razуn: %s",Nombre,id,razon);
               SendClientMessageToAll(0xAA3333AA,string);
               Kick(playerid);
          }
     } else {
          SendClientMessage(playerid, Rojo,"[[Info]] Lo sentimos no eres Admin");
     }
     return 1;
}
Prueba a ver.
Reply
#3

Peor :S cuando pongo kick id razon me vuelve a salir el mensaje como si pusiera solamente /kick o /kick id :/
se bugeo :S
Reply
#4

Pues no sй, a mi me funciona perfectamente.
Reply
#5

We, alguien mas? :S
Reply
#6

Este fs esta bugueado por donde lo veas, bajate el ladmin original traducilo y agregale todo esto, lo conectas con el top de infierno y ya.
Reply
#7

Gracias xeno, ya me di cuenta pero crei q yo era el unico :S
Por lo puesto todo lo contrario lo q si tngo un ladmin mio q me llevo meses hacerlo a mi modo pero no c como unirlo con el top
Reply
#8

parece dificil
pero es facil unirlos solo es cosa de entenderle
y comprender donde va cada funcion :S
Reply
#9

pawn Код:
dcmd_kick(playerid,params[])
{
     if(PlayerInfo[playerid][Nivel] >= 2)
     {
          new id;
          new razon[80];
          if(sscanf(params, "us[80]", id, razon))//es "u" user - "s" string y la longitud de la string
          {
               SendClientMessage(playerid, Naranja, "Usa: /Kick <ID> <Razуn>");
          }
          else if(IsPlayerConnected(id) && id != INVALID_PLAYER_ID && id != playerid) return SendClientMessage(playerid, Rojo, "[[Info]] Jugador no Conectado");
          else
          {
               new string[128],Nombre[MAX_PLAYER_NAME],ANombre[MAX_PLAYER_NAME];//porquй usar strings de 256 si lo mбximo de SendClientMessage son 128 celdas
               GetPlayerName(id,Nombre,sizeof(Nombre));//ha quien quieres kickear
               GetPlayerName(playerid,ANombre,sizeof(ANombre));//el admin que kickea, no al revйs
               format(string,sizeof(string),"*** %s (id:%d) Fue expulsado por un admin. Razуn: %s",Nombre,id,razon);
               SendClientMessageToAll(0xAA3333AA,string);
               Kick(playerid);//talvez si se expulsara a "id" y no a "playerid" funcionaria
          }
     } else {
          SendClientMessage(playerid, Rojo,"[[Info]] Lo sentimos no eres Admin");
     }
     return 1;
}
Reply
#10

Quote:
Originally Posted by [M]xFire
Посмотреть сообщение
pawn Код:
dcmd_kick(playerid,params[])
{
     if(PlayerInfo[playerid][Nivel] >= 2)
     {
          new id;
          new razon[80];
          if(sscanf(params, "us[80]", id, razon))//es "u" user - "s" string y la longitud de la string
          {
               SendClientMessage(playerid, Naranja, "Usa: /Kick <ID> <Razуn>");
          }
          else if(IsPlayerConnected(id) && id != INVALID_PLAYER_ID && id != playerid) return SendClientMessage(playerid, Rojo, "[[Info]] Jugador no Conectado");
          else
          {
               new string[128],Nombre[MAX_PLAYER_NAME],ANombre[MAX_PLAYER_NAME];//porquй usar strings de 256 si lo mбximo de SendClientMessage son 128 celdas
               GetPlayerName(id,Nombre,sizeof(Nombre));//ha quien quieres kickear
               GetPlayerName(playerid,ANombre,sizeof(ANombre));//el admin que kickea, no al revйs
               format(string,sizeof(string),"*** %s (id:%d) Fue expulsado por un admin. Razуn: %s",Nombre,id,razon);
               SendClientMessageToAll(0xAA3333AA,string);
               Kick(playerid);//talvez si se expulsara a "id" y no a "playerid" funcionaria
          }
     } else {
          SendClientMessage(playerid, Rojo,"[[Info]] Lo sentimos no eres Admin");
     }
     return 1;
}
Tambiйn, se me pasу.
Pero el dice que ni le kickea ni nada.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)