[Ajuda] quem loga ve carros spawnados na rua!
#1

Galera eu estou com um problema tipo assim,quem loga no servidor,ve todos os carros de 2 orgs spanados na mesma rua,tanto й q alguns sгo espanados no mesmo lugar e ficam grudados,ai c eu do /rc eles voltam pra hq,ai pra mim fica tudo normal,porem se alguem entrar no servidor,vai ver os carros spawnados na rua atй eu da /rc de novo,ja pra mim os carros estгo na hq pq eu dei /rc antes do cara entra,segue as prints:

Й ISSO QUE A PESSOA VE QUANDO LOGA,ESSE Й O LUGAR ONDE DEVIA TAR OS CARROS:


E QUANDO A PESSOA DECE PRA RUA,ELA VE ISSO:



E O CERTO Й ASSIM:



AI EU DO /RC FICA TUDO NORMALZIM OS CARRO NAS HQ SУ Q AI SE ALGUEM ENTRA PRA PESSOA Q ENTRO OS CARROS FICAM NA RUA ATЙ DAR /RC E PRA MIM OS CARRO TГO NO LUGAR,COMO RESOLVER ISSO?

E Й SУMENTE OS CARROS DESSAS 2 ORG Q FICAM NA RUA O RESTO DAS ORG TA NORMALZINHO E SENDO Q EU NUNCA MECHI NO PCC (CARROS BEGE)
Reply
#2

dб uma olhada na callback de login.
Reply
#3

no onmplayerspawn sу tem isso:

Код:
public OnPlayerSpawn(playerid)
{
    LoadPlayerVehicle(playerid);
    TextDrawShowForPlayer(playerid, TextGrana[playerid]);
    SetPlayerVirtualWorld(playerid, void);  //Por enquanto й isso
    SetPVarInt(playerid, "Universo", void);
    AntiDeAMX();
    /*if(playerid == 0)//Policial Charles by Sonic_FreeStyle & Shadow_FreeStyle
    {
        SetPlayerSkin(playerid, 281);
        new Text3D:charleslabel[MAX_PLAYERS];
        new bot1string[256];
        format(bot1string, sizeof(bot1string), "Policial_Charles");
        charleslabel[playerid] = Create3DTextLabel(bot1string, COP_COLOR, 30.0, 40.0, 50.0, 3.0, 0, 0);
        Attach3DTextLabelToPlayer(charleslabel[playerid], playerid, 0.0, 0.0, 0.7);
    }*/
    for(new x = 0; x < MAX_PLAYERS; x++)
    {
        if(IsPlayerInFavela(x) || IsPlayerInBoca2(x) || IsPlayerInQuadra(x) || IsPlayerInPark(x)
 		|| IsPlayerInBoca1(x) || IsPlayerInBoca3(x) || IsPlayerInRiacho(x) || IsPlayerInIndustria(x)
 		|| IsPlayerInFonteSF(x) || IsPlayerInShoppingSF(x) || IsPlayerInPraiaSF(x)
 		|| IsPlayerInAeroSF(x) || IsPlayerInConstrucaoSF(x) || IsPlayerInRiacho(x)
 		|| IsPlayerInCasarao(x) || IsPlayerInEstacao(x))
 		{}
 		else
		{
		    TextDrawHideForPlayer(x, MortoInfo[x]);
		}
	}
    if (PlayerInfo[playerid][pLevel] > 0)
	{
      new Text3D:nivellabel[MAX_PLAYERS];
      new string[256];
      new nomedocaba[MAX_PLAYER_NAME];
      Delete3DTextLabel(nivellabel[playerid]);
      GetPlayerName(playerid, nomedocaba, MAX_PLAYER_NAME);
      format(string, sizeof(string), "Nivel: %d",PlayerInfo[playerid][pLevel]);
      nivellabel[playerid] = Create3DTextLabel(string, 0x33FF00FF, 30.0, 40.0, 50.0, 3.0, 0, 0);
      Attach3DTextLabelToPlayer(nivellabel[playerid], playerid, 0.0, 0.0, 0.7);
	}
    CheckInfoOrg(playerid);
    TextDrawHideForAll(Reloginho1);
    TextDrawShowForPlayer(playerid, Reloginho1);
    TextDrawHideForAll(Reloginho2);
	TextDrawShowForPlayer(playerid, Reloginho2);
    new plname[MAX_PLAYER_NAME];
    new string[256];
    if(sincronizando[playerid] == 1)
	{
		return 1;
	}
	if(EntrounoEvento == 1)
    {
		ResetPlayerWeapons(playerid);
		SetPlayerHealth(playerid,100);
		return 1;
    }
	InitLockDoors(playerid);
	STDPlayer[playerid] = 0;
	gTeam[playerid] = PlayerInfo[playerid][pTeam]; //Set the Team
	if (gTeam[playerid] == 4) //medic / criminal reset team
	{
		gTeam[playerid] = 3;
	}
	if(gPlayerLogged[playerid] == 0)
	{
        GetPlayerName(playerid, plname, sizeof(plname));
		format(string, sizeof(string), "Contas/%s.ini", plname);
        if(fexist(string))
		{
		ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT, "{FFFF00}Login RHB", "{33CCFF}******************************************\n{33FF00}Bem Vindo ao [RHB] Rpg Heroes Brasil [RPG v1.0] \n{33FF00}Sua conta foi Registrada! \n\n{33FF00}Por favor logue na sua conta!!\n{33CCFF}******************************************", "Logar", "Sair");
		//TextDrawShowForPlayer(playerid, RHBText);//Mostrar RHB Text Draw Sonic_FreeStyle & Shadow_FreeStyle
		}
		else
		{

ShowPlayerDialog(playerid, 2, DIALOG_STYLE_INPUT, "{FFFF00}Registrar RHB", "{33CCFF}******************************************\n{33FF00}Bem Vindo ao [RHB] Rpg Heroes Brasil [RPG v1.0] \n{33FF00}Sua conta nao esta registrada! \n\n{33FF00}Por favor, registre-se!!\n{33CCFF}******************************************", "Registrar", "Sair");
		//TextDrawShowForPlayer(playerid, RHBText);//Mostrar RHB Text Draw Sonic_FreeStyle & Shadow_FreeStyle
		}
		return 1;
 	}
	if(gTeam[playerid] == 11 && PlayerInfo[playerid][pLider] < 1)
	{
	    MedicBill[playerid] = 0;
	    new rand = random(sizeof(CIV));
		SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк nгo foi aprovado pelo lнder, agora й um Civil!");
		PlayerInfo[playerid][pTeam] = 3;
		gTeam[playerid] = 3;
		SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
		PlayerInfo[playerid][pModel] = CIV[rand];
		SpawnPlayer(playerid);
		MedicBill[playerid] = 0;
	}
	if(gTeam[playerid] == 5)
	{
	    if(PlayerInfo[playerid][pMembro] < 1)
	    {
	        MedicBill[playerid] = 0;
	        new rand = random(sizeof(CIV));
			SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк nгo faz parte de uma familia, agora й um Civil!");
			PlayerInfo[playerid][pTeam] = 3;
			gTeam[playerid] = 3;
            SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
			PlayerInfo[playerid][pModel] = CIV[rand];
			SpawnPlayer(playerid);
			MedicBill[playerid] = 0;
		}
	}
	if(gTeam[playerid] == 10)
	{
	    if(PlayerInfo[playerid][pMembro] != 8)
	    {
	        MedicBill[playerid] = 0;
	        new rand = random(sizeof(CIV));
			SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк nгo faz parte de uma agencia, й um Civil!");
			PlayerInfo[playerid][pTeam] = 3;
			gTeam[playerid] = 3;
            SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
			PlayerInfo[playerid][pModel] = CIV[rand];
			SpawnPlayer(playerid);
			MedicBill[playerid] = 0;
		}
	}
	if(gTeam[playerid] == 2 && PlayerInfo[playerid][pMembro] > 3)
	{
	    MedicBill[playerid] = 0;
		new rand = random(sizeof(CIV));
		SendClientMessage(playerid, COLOR_LIGHTRED, "Voce nгo faz parte da PM / PC / Exйrcito, й um Civil!");
		PlayerInfo[playerid][pTeam] = 3;
		gTeam[playerid] = 3;
		SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
		PlayerInfo[playerid][pModel] = CIV[rand];
		SpawnPlayer(playerid);
		MedicBill[playerid] = 0;
	}
	if(gTeam[playerid] == 3)
	{
	    if(PlayerInfo[playerid][pLider] > 0)
	    {
			SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк faz parte de uma familia, foi forзado a trocar de roupa!");
			MedicBill[playerid] = 0;
			new model = PlayerInfo[playerid][pChar];
			if(PlayerInfo[playerid][pMembro] == 1) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 2) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 3) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 4) { SetSpawnInfo(playerid, 1, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 1; gTeam[playerid] = 4; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 5) { SetSpawnInfo(playerid, 5, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 5; gTeam[playerid] = 5; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 6) { SetSpawnInfo(playerid, 5, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 5; gTeam[playerid] = 6; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 8) { SetSpawnInfo(playerid, 10, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 10; gTeam[playerid] = 8; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 9) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 9; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 10) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 10; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 11) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 15) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 15; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 16) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 17) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 18) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 18; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 19) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 19; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 20) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 20; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 22) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 22; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 23) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 23; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 24) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 24; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 1) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 2) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 3) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 4) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 4; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 5) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 5; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 6) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 6; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 7) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 8) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 8; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 9) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 9; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 10) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 10; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 11) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 15) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 15; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 16) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 17) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 18) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 18; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 19) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 19; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 20) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 20; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 22) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 22; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 23) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 23; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 24) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 24; PlayerInfo[playerid][pModel] = model; }
			//SetSpawnInfo(playerid, team, model,0.0,0.0,0.0,0,0,0,0,0,0,0);
			SpawnPlayer(playerid);
		}
	}
	if(PlayerInfo[playerid][pChar] > 0) { SetPlayerSkin(playerid, PlayerInfo[playerid][pChar]); }
	else { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
	SetPlayerWeapons(playerid);
	SetPlayerSpawn(playerid);
	SetPlayerToTeamColor(playerid);
	PlayerFixRadio(playerid);
/*	for(new i = 0; i < sizeof(Turfs); i++)
	{
	    GangZoneShowForPlayer(playerid, i, TurfInfo[i][zCOLOR]);
	}*/
	if(MapIconsShown[playerid] != 0)
	{
	    MapIconsShown[playerid] = 0;
	    for(new i = 0; i < sizeof(BizzInfo); i++)
		{
			SetPlayerMapIcon(playerid,i + 20,BizzInfo[i][bEntranceX],BizzInfo[i][bEntranceY],BizzInfo[i][bEntranceZ],36,COLOR_LIGHTRED);
		}
		for(new i = 0; i < sizeof(SBizzInfo); i++)
		{
		    SetPlayerMapIcon(playerid,i + 20,SBizzInfo[i][sbEntranceX],SBizzInfo[i][sbEntranceY],SBizzInfo[i][sbEntranceZ],36,COLOR_LIGHTRED);
		}
	}
	//TextDrawShowForPlayer(playerid, RHBText);
	return 1;
}
Reply
#4

Quote:
Originally Posted by Sonic Hero
Посмотреть сообщение
no onmplayerspawn sу tem isso:

Код:
public OnPlayerSpawn(playerid)
{
    LoadPlayerVehicle(playerid);
    TextDrawShowForPlayer(playerid, TextGrana[playerid]);
    SetPlayerVirtualWorld(playerid, void);  //Por enquanto й isso
    SetPVarInt(playerid, "Universo", void);
    AntiDeAMX();
    /*if(playerid == 0)//Policial Charles by Sonic_FreeStyle & Shadow_FreeStyle
    {
        SetPlayerSkin(playerid, 281);
        new Text3D:charleslabel[MAX_PLAYERS];
        new bot1string[256];
        format(bot1string, sizeof(bot1string), "Policial_Charles");
        charleslabel[playerid] = Create3DTextLabel(bot1string, COP_COLOR, 30.0, 40.0, 50.0, 3.0, 0, 0);
        Attach3DTextLabelToPlayer(charleslabel[playerid], playerid, 0.0, 0.0, 0.7);
    }*/
    for(new x = 0; x < MAX_PLAYERS; x++)
    {
        if(IsPlayerInFavela(x) || IsPlayerInBoca2(x) || IsPlayerInQuadra(x) || IsPlayerInPark(x)
 		|| IsPlayerInBoca1(x) || IsPlayerInBoca3(x) || IsPlayerInRiacho(x) || IsPlayerInIndustria(x)
 		|| IsPlayerInFonteSF(x) || IsPlayerInShoppingSF(x) || IsPlayerInPraiaSF(x)
 		|| IsPlayerInAeroSF(x) || IsPlayerInConstrucaoSF(x) || IsPlayerInRiacho(x)
 		|| IsPlayerInCasarao(x) || IsPlayerInEstacao(x))
 		{}
 		else
		{
		    TextDrawHideForPlayer(x, MortoInfo[x]);
		}
	}
    if (PlayerInfo[playerid][pLevel] > 0)
	{
      new Text3D:nivellabel[MAX_PLAYERS];
      new string[256];
      new nomedocaba[MAX_PLAYER_NAME];
      Delete3DTextLabel(nivellabel[playerid]);
      GetPlayerName(playerid, nomedocaba, MAX_PLAYER_NAME);
      format(string, sizeof(string), "Nivel: %d",PlayerInfo[playerid][pLevel]);
      nivellabel[playerid] = Create3DTextLabel(string, 0x33FF00FF, 30.0, 40.0, 50.0, 3.0, 0, 0);
      Attach3DTextLabelToPlayer(nivellabel[playerid], playerid, 0.0, 0.0, 0.7);
	}
    CheckInfoOrg(playerid);
    TextDrawHideForAll(Reloginho1);
    TextDrawShowForPlayer(playerid, Reloginho1);
    TextDrawHideForAll(Reloginho2);
	TextDrawShowForPlayer(playerid, Reloginho2);
    new plname[MAX_PLAYER_NAME];
    new string[256];
    if(sincronizando[playerid] == 1)
	{
		return 1;
	}
	if(EntrounoEvento == 1)
    {
		ResetPlayerWeapons(playerid);
		SetPlayerHealth(playerid,100);
		return 1;
    }
	InitLockDoors(playerid);
	STDPlayer[playerid] = 0;
	gTeam[playerid] = PlayerInfo[playerid][pTeam]; //Set the Team
	if (gTeam[playerid] == 4) //medic / criminal reset team
	{
		gTeam[playerid] = 3;
	}
	if(gPlayerLogged[playerid] == 0)
	{
        GetPlayerName(playerid, plname, sizeof(plname));
		format(string, sizeof(string), "Contas/%s.ini", plname);
        if(fexist(string))
		{
		ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT, "{FFFF00}Login RHB", "{33CCFF}******************************************\n{33FF00}Bem Vindo ao [RHB] Rpg Heroes Brasil [RPG v1.0] \n{33FF00}Sua conta foi Registrada! \n\n{33FF00}Por favor logue na sua conta!!\n{33CCFF}******************************************", "Logar", "Sair");
		//TextDrawShowForPlayer(playerid, RHBText);//Mostrar RHB Text Draw Sonic_FreeStyle & Shadow_FreeStyle
		}
		else
		{

ShowPlayerDialog(playerid, 2, DIALOG_STYLE_INPUT, "{FFFF00}Registrar RHB", "{33CCFF}******************************************\n{33FF00}Bem Vindo ao [RHB] Rpg Heroes Brasil [RPG v1.0] \n{33FF00}Sua conta nao esta registrada! \n\n{33FF00}Por favor, registre-se!!\n{33CCFF}******************************************", "Registrar", "Sair");
		//TextDrawShowForPlayer(playerid, RHBText);//Mostrar RHB Text Draw Sonic_FreeStyle & Shadow_FreeStyle
		}
		return 1;
 	}
	if(gTeam[playerid] == 11 && PlayerInfo[playerid][pLider] < 1)
	{
	    MedicBill[playerid] = 0;
	    new rand = random(sizeof(CIV));
		SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк nгo foi aprovado pelo lнder, agora й um Civil!");
		PlayerInfo[playerid][pTeam] = 3;
		gTeam[playerid] = 3;
		SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
		PlayerInfo[playerid][pModel] = CIV[rand];
		SpawnPlayer(playerid);
		MedicBill[playerid] = 0;
	}
	if(gTeam[playerid] == 5)
	{
	    if(PlayerInfo[playerid][pMembro] < 1)
	    {
	        MedicBill[playerid] = 0;
	        new rand = random(sizeof(CIV));
			SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк nгo faz parte de uma familia, agora й um Civil!");
			PlayerInfo[playerid][pTeam] = 3;
			gTeam[playerid] = 3;
            SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
			PlayerInfo[playerid][pModel] = CIV[rand];
			SpawnPlayer(playerid);
			MedicBill[playerid] = 0;
		}
	}
	if(gTeam[playerid] == 10)
	{
	    if(PlayerInfo[playerid][pMembro] != 8)
	    {
	        MedicBill[playerid] = 0;
	        new rand = random(sizeof(CIV));
			SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк nгo faz parte de uma agencia, й um Civil!");
			PlayerInfo[playerid][pTeam] = 3;
			gTeam[playerid] = 3;
            SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
			PlayerInfo[playerid][pModel] = CIV[rand];
			SpawnPlayer(playerid);
			MedicBill[playerid] = 0;
		}
	}
	if(gTeam[playerid] == 2 && PlayerInfo[playerid][pMembro] > 3)
	{
	    MedicBill[playerid] = 0;
		new rand = random(sizeof(CIV));
		SendClientMessage(playerid, COLOR_LIGHTRED, "Voce nгo faz parte da PM / PC / Exйrcito, й um Civil!");
		PlayerInfo[playerid][pTeam] = 3;
		gTeam[playerid] = 3;
		SetSpawnInfo(playerid, gTeam[playerid], CIV[rand],0.0,0.0,0.0,0,0,0,0,0,0,0);
		PlayerInfo[playerid][pModel] = CIV[rand];
		SpawnPlayer(playerid);
		MedicBill[playerid] = 0;
	}
	if(gTeam[playerid] == 3)
	{
	    if(PlayerInfo[playerid][pLider] > 0)
	    {
			SendClientMessage(playerid, COLOR_LIGHTRED, "Vocк faz parte de uma familia, foi forзado a trocar de roupa!");
			MedicBill[playerid] = 0;
			new model = PlayerInfo[playerid][pChar];
			if(PlayerInfo[playerid][pMembro] == 1) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 2) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 3) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 4) { SetSpawnInfo(playerid, 1, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 1; gTeam[playerid] = 4; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 5) { SetSpawnInfo(playerid, 5, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 5; gTeam[playerid] = 5; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 6) { SetSpawnInfo(playerid, 5, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 5; gTeam[playerid] = 6; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 8) { SetSpawnInfo(playerid, 10, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 10; gTeam[playerid] = 8; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 9) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 9; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 10) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 10; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 11) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 15) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 15; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 16) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 17) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 18) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 18; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 19) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 19; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 20) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 20; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 22) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 22; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 23) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 23; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pMembro] == 24) { SetSpawnInfo(playerid, 12, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 24; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 1) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 2) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 3) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 4) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 4; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 5) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 5; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 6) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 6; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 7) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 8) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 8; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 9) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 9; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 10) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 10; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 11) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 15) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 15; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 16) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 17) { SetSpawnInfo(playerid, 2, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 18) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 18; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 19) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 19; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 20) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 20; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 22) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 22; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 23) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 23; PlayerInfo[playerid][pModel] = model; }
			else if(PlayerInfo[playerid][pLider] == 24) { SetSpawnInfo(playerid, 11, model,0.0,0.0,0.0,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 24; PlayerInfo[playerid][pModel] = model; }
			//SetSpawnInfo(playerid, team, model,0.0,0.0,0.0,0,0,0,0,0,0,0);
			SpawnPlayer(playerid);
		}
	}
	if(PlayerInfo[playerid][pChar] > 0) { SetPlayerSkin(playerid, PlayerInfo[playerid][pChar]); }
	else { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
	SetPlayerWeapons(playerid);
	SetPlayerSpawn(playerid);
	SetPlayerToTeamColor(playerid);
	PlayerFixRadio(playerid);
/*	for(new i = 0; i < sizeof(Turfs); i++)
	{
	    GangZoneShowForPlayer(playerid, i, TurfInfo[i][zCOLOR]);
	}*/
	if(MapIconsShown[playerid] != 0)
	{
	    MapIconsShown[playerid] = 0;
	    for(new i = 0; i < sizeof(BizzInfo); i++)
		{
			SetPlayerMapIcon(playerid,i + 20,BizzInfo[i][bEntranceX],BizzInfo[i][bEntranceY],BizzInfo[i][bEntranceZ],36,COLOR_LIGHTRED);
		}
		for(new i = 0; i < sizeof(SBizzInfo); i++)
		{
		    SetPlayerMapIcon(playerid,i + 20,SBizzInfo[i][sbEntranceX],SBizzInfo[i][sbEntranceY],SBizzInfo[i][sbEntranceZ],36,COLOR_LIGHTRED);
		}
	}
	//TextDrawShowForPlayer(playerid, RHBText);
	return 1;
}
Manda o Comando /RC.
Reply
#5

Код:
//Spawn Carros
    if(strcmp(cmd, "/respawncarros", true) == 0 || strcmp(cmd, "/rc", true) == 0)
	{
	    if(IsPlayerConnected(playerid))
	    {
	        if(PlayerInfo[playerid][pAdmin] < 3)
			{
			    SendClientMessage(playerid, COLOR_GRAD1, "   Vocк nгo estб autorizado a usar este comando !");
			    return 1;
			}
			if(admadministrando[playerid] < 1)
			{
				SendClientMessage(playerid, COLOR_GRAD1, "Vocк nгo estб trabalhando! (/profadmin)");
				return 1;
			}
   			GetPlayerName(playerid, playername, sizeof(playername));
   			//format(string, sizeof(string), "[RHB]] O Admin %s recolocou todos os veiculos para seus locais de origem.", playername);
			SendClientMessageToAll(COLOR_WHITE,string);
			SendClientMessage(playerid,COLOR_GRAD1,"Carros Respanados Com Susseso!");
			new bool:unwanted[CAR_AMOUNT];
			for(new player=0; player<MAX_PLAYERS; player++)
     		{
            	if(IsPlayerInAnyVehicle(player)) { unwanted[GetPlayerVehicleID(player)]=true; }
     		}
			for(new car = 1; car <= CAR_RESPAW; car++)
			{
				if(!unwanted[car]) SetVehicleToRespawn(car);
			}
		}
		return 1;
	}
mais acho q nao й isso pq eu nunca mechi no /rc,e й tenso q no onplayerspawn e coisas de login eu tbm nunca mechi eu sу editei mudei coordenadas de uns carro abandonado,mais isso comeзou recentimente
Reply
#6

pawn Код:
for(new car = 1; car <= MAX_VEHICLES; car++)
            {
                if(!unwanted[car]) SetVehicleToRespawn(car);
            }
Tenta trocar por Isto.
Reply
#7

QUAAAAAAAAAASE QUE DEU CERTO KKKKKK ALGUNS CARROS FICAM EM SEUS LUGARES JA ALGUNS FICAM QUASE EM SEUS LUGARES (VIATURAS) E OUTROS FICAM TOTALMENTE FORA (NA RUA)

1° SS REPARE Q AS MOTOS ESTAO CAIDAS E O SUPERGT FOI SPANADO DE PONTA CABEЗA ATRAS DESSE CORETO,AGORA NAO SEI SE ELE FOI SPAWNADO DE PONTA CABEЗA OU SE ELE CAIU EMBAIXO E CAPOTO



2° SS NA HQ DO PCC SУ FICO NO LUGAR A VAN E O HELI:


3° SS O RESTO...

Reply
#8

pawn Код:
for(new car = 0; car < MAX_VEHICLES; car++)
            {
                if(!unwanted[car]) SetVehicleToRespawn(car);
            }

Coloque assim, e tente.
Reply
#9

nгo й o mesmo cуdigo q vc mando .-.
Reply
#10

Quote:
Originally Posted by Sonic Hero
Посмотреть сообщение
nгo й o mesmo cуdigo q vc mando .-.
Nгo '-', Tente daquele Modo.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)