Bug do /carandiru
#1

Sempre que boto alguém no Carandiru da a mensagem Bem Vindo Ao Carandiru e dai já estou solto.

E também quero que aparece a mensagem que alguém foi botado no Carandiru.

Код:
if(strcmp(cmd, "/carandiru",true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
	        new tempo[20];
	        new tempo2;
	        if(PlayerInfo[playerid][pAdmin] < 2)
	        {
	            SendClientMessage(playerid, COLOR_GREY, "   Você não esta autorizado para usar este comando!");
	            return true;
	        }
	        tmp = strtok(cmdtext, idx);
	        tempo = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "USE: /carandiru [id] [ Tempo ]");
				return true;
			}
			if(!strlen(tempo))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "USE: /carandiru [id] [ Tempo ]");
				return true;
			}
			if(PlayerInfo[giveplayerid][pAdmin] >= 1339 && PlayerInfo[playerid][pAdmin] < SUB_GERENTE)
			{
				SendClientMessage(playerid, COLOR_GRAD1, "Você não pode dar carandiru para um Admin Dono !");
				return true;
			}
   if(admtrampando[playerid] < 1 && PlayerInfo[playerid][pAdmin] != DONO)
			{
				SendClientMessage(playerid, COLOR_GRAD1, "Você não está trabalhando! (/trabalhar)");
				return true;
			}
			giveplayerid = ReturnUser(tmp);
			tempo2 = strval(tempo);
		    if(IsPlayerConnected(giveplayerid))
		    {
		        if(giveplayerid != INVALID_PLAYER_ID)
		        {
		            GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
					GetPlayerName(playerid, sendername, sizeof(sendername));
					format(string, sizeof(string), "* Você Colocou o(a) %s No Carandiru.", giveplayer);
					SendClientMessage(playerid, COLOR_LIGHTRED, string);
					if(admtrampando[playerid] == 1 && admhide[playerid] == 1)
					{
						SendClientMessage(giveplayerid, COLOR_LIGHTRED, "* Você foi colocado no Carandiru Pelo Admin BEL.");
					}
					else
					{
						format(string, sizeof(string), "* Você foi colocado no Carandiru Pelo Admin %s.", PlayerName(playerid));
						SendClientMessage(giveplayerid, COLOR_LIGHTRED, string);
					}
					GameTextForPlayer(giveplayerid, "~b~Bem Vindo ao ~n~~r~Carandiru", 5000, 3);
					ResetPlayerWeaponsEx(giveplayerid);
					WantedPoints[giveplayerid] = 0;
      				SetPlayerWantedLevel(giveplayerid, 0);
					PlayerInfo[giveplayerid][pJailed] = 2;
					PlayerInfo[giveplayerid][pJailTime] = tempo2 * 60;
		            SetPlayerPos(giveplayerid, 107.2300,1920.6311,18.5208);
					SetPlayerWorldBounds(giveplayerid, 337.5694,101.5826,1940.9759,1798.7453); //285.3481,96.9720,1940.9755,1799.0811
		        }
			}
			else
			{
			    SendClientMessage(playerid, COLOR_GREY, "   O jogador está offline !");
			    return true;
			}
	    }
	    return true;
	}
Reply


Messages In This Thread
Bug do /carandiru - by Ever_SH - 05.10.2012, 00:05
Re: Bug do /carandiru - by Wendell - 05.10.2012, 00:20

Forum Jump:


Users browsing this thread: 1 Guest(s)