[AJUDA] Sistema de hospital bug.
#1

PRIMEIRAMENTE sim eu usei e li o search , segundo, bom eu testei esse code, o que acontece й que, se um colega meu morre eu que vou para o hospital, era para quem morreu ir...
OBS: Uso godfather.
codigo:
TOPO:
[pawn]
new spawnado[MAX_PLAYERS];
No OnPlayerSpawn.
pawn Код:
public OnPlayerSpawn(playerid)
{
        PlayerPlaySound(playerid, 1057, Xs, Ys, Zs);
        SetPlayerSkillLevel(playerid, WEAPONSKILL_MICRO_UZI, 450);
        if(IsPlayerNPC(playerid)) //Checa se o jogador й um NPC.
        {
                new npcname[MAX_PLAYER_NAME];
                GetPlayerName(playerid, npcname, sizeof(npcname)); //Obtendo o nome do(s) NPC(s).
                if(!strcmp(npcname, "Tio_Xico", true)) //Checando se o nome do NPC й MeuPrimeiroNPC
                {
                    SetPlayerSkin(playerid, 94);
                    return 1;
                }
                if(!strcmp(npcname, "Policial_Dp", true)) //Checando se o nome do NPC й MeuPrimeiroNPC
                {
                    PutPlayerInVehicle(playerid, Random, 0);
                    SetPlayerSkin(playerid, 281);
                    GivePlayerWeapon(playerid, 30, 200);
                    return 1;

                }
            }


    TextDrawShowForPlayer(playerid, Time), TextDrawShowForPlayer(playerid, Date);
    TextDrawShowForPlayer(playerid, TextdrawB);
    TextDrawShowForPlayer(playerid, tGP2[playerid]);

    InitLockDoors(playerid);
    SetPlayerHealth(playerid, 100);
    STDPlayer[playerid] = 0;
    gTeam[playerid] = PlayerInfo[playerid][pTeam]; //Set the Team
    gGas[playerid] = 1;
    for(new i=0;i<sizeof(Turfs);i++)
    {
        for(new gangid; gangid < MAX_PLAYERS; gangid++)
        {
            if(TurfInfo[i][zMemberDie] == playerid)
            {
                if(PlayerInfo[gangid][pMember] == PlayerInfo[playerid][pMember])
                {
                    if(i == 0){GangZoneFlashForPlayer(gangid, i, TEAM_GROVE_COLOR);}
                    if(i == 1){GangZoneFlashForPlayer(gangid, i, COLOR_YELLOW);}
                    if(i == 2){GangZoneFlashForPlayer(gangid, i, TEAM_BALLAS_COLOR);}
                    if(i == 3){GangZoneFlashForPlayer(gangid, i, TEAM_AZTECAS_COLOR);}
                    if(i == 4){GangZoneFlashForPlayer(gangid, i, TEAM_COMANDO_COLOR);}
                    if(i == 5){GangZoneFlashForPlayer(gangid, i, TEAM_PCC_COLOR);}
                }
                if(i == 0){GangZoneFlashForPlayer(gangid, i, TEAM_GROVE_COLOR);}
                if(i == 1){GangZoneFlashForPlayer(gangid, i, COLOR_YELLOW);}
                if(i == 2){GangZoneFlashForPlayer(gangid, i, TEAM_BALLAS_COLOR);}
                if(i == 3){GangZoneFlashForPlayer(gangid, i, TEAM_AZTECAS_COLOR);}
                if(i == 4){GangZoneFlashForPlayer(gangid, i, TEAM_COMANDO_COLOR);}
                if(i == 5){GangZoneFlashForPlayer(gangid, i, TEAM_PCC_COLOR);}
                TurfInfo[i][zMemberDie] = -1;
            }
        }
    }
    if (gTeam[playerid] == 4) //medic / criminal reset team
    {
        gTeam[playerid] = 3;
    }
    if(gTeam[playerid] == 11 && PlayerInfo[playerid][pLeader] < 1)
    {
        Hospital[playerid] = 0;
        new rand = random(sizeof(CIV));
        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);
    }
    if(gTeam[playerid] == 5)
    {
        if(PlayerInfo[playerid][pMember] < 1)
        {
            Hospital[playerid] = 0;
            new rand = random(sizeof(CIV));
            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);
        }
    }
    if(gTeam[playerid] == 10)
    {
        if(PlayerInfo[playerid][pMember] != 8)
        {
            Hospital[playerid] = 0;
            new rand = random(sizeof(CIV));
            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);
        }
    }
    if(gTeam[playerid] == 2 && PlayerInfo[playerid][pMember] > 3)
    {
        Hospital[playerid] = 0;
        new rand = random(sizeof(CIV));
        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);
    }
    if(gTeam[playerid] == 3)
    {
        if(PlayerInfo[playerid][pMember] > 0 || PlayerInfo[playerid][pLeader] > 0)
        {
            Hospital[playerid] = 0;
            new model = PlayerInfo[playerid][pChar];
            if(PlayerInfo[playerid][pMember] == 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][pMember] == 2) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 3) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 4) { SetSpawnInfo(playerid, 1, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 1; gTeam[playerid] = 1; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 5) { SetSpawnInfo(playerid, 5, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 6) { SetSpawnInfo(playerid, 5, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 8) { SetSpawnInfo(playerid, 10, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 10; gTeam[playerid] = 10; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 9) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 7) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 11) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 16) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 12) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 13) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 14) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 14; gTeam[playerid] = 14; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 10) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 18) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 19) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 20) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 21) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 21; gTeam[playerid] = 21; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 22) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 22; gTeam[playerid] = 22; PlayerInfo[playerid][pModel] = model; }
       

            else if(PlayerInfo[playerid][pLeader] == 1) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 2) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 3) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 4) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 5) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 6) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 7) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 8) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 9) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 11) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 14) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 16) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 12) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 13) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 10) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 14) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 18) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 19) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 20) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 21) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 22) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; 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][pMember] == 11)
    {
        SetPlayerSkin(playerid, 217);
    }

    if(PlayerInfo[playerid][pChar] > 0) { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
    else { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
    SetPlayerWeapons(playerid);
    SetPlayerSpawn(playerid);
    SetPlayerToTeamColor(playerid);
    PlayerFixRadio(playerid);
    for(new i = 0; i < sizeof(Turfs); i++)
    {
        GangZoneShowForAll(i, TurfInfo[i][zColor]);
    }
    return 1;
}
No SetPlayerSpawn:
pawn Код:
forward SetPlayerSpawn(playerid);
public SetPlayerSpawn(playerid)
{
if(IsPlayerConnected(playerid))
{
if(spawnado[playerid] > 1)
{
    SendClientMessage(playerid, COLOR_ALLDEPT,"Vocк estб sendo curado");
    SetPlayerPos(playerid,1251.3319,317.5681,-10.7564);
    SetPlayerInterior(playerid, 1);
    SetTimer("HospitalDentro", 500, false);
    SetTimer("HospitalTimer", 12000, false);
    spawnado[playerid] = 1;
}
if(Cadeia[playerid] > 1)
{
SetPlayerInterior(playerid, 6);
SetPlayerPos(playerid,264.6288,77.5742,1001.0391);
SendClientMessage(playerid, COLOR_OOC, "Vocк nгo cumpriu com sua pena, dados: LSPD HQ");
}
 //Essa foi a parte que eu mexi (/\)
E no OnPlayerDeath
pawn Код:
spawnado[playerid]++;
se quiserem que eu poste as publics que criei para facilitar postem, e se puderem ajudar postem tambйm por favor.
Reply
#2

Use SetTimerEx...
Reply
#3

Pode me ajudar ja que sou novo em pawn?
e pelo o q eu li, o SetTimer serve para playerid, ou seja, no caso playerid й quem morre...
Reply
#4

Posta a callback "OnPlayerDeath".
Reply
#5

Ah, e ele buga na cadeia e paint ball, help
pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    spawnado[playerid]++;
    //empresa
    SBizzInfo[14][sbTill] += 50;
    ExtortionSBiz(14, 50);

    Conce[playerid] = 0;
    new name[MAX_PLAYER_NAME];
    new string[256];
    new playercash;
    new victimteam;
    new Float:px,Float:py,Float:pz;
    new killerteam;

    victimteam = gTeam[playerid];
    burgerexit[playerid] = 0;
    Hospital[playerid] = 1;
    storeexit[playerid] = 0;
    PlayerInfo[playerid][pInvWeapon] = 0;
    PlayerInfo[playerid][pInvAmmo] = 0;
    cherifeexit[playerid] = 0;
    killerteam = gTeam[killerid];
    gPlayerSpawned[playerid] = 0;
    GetPlayerName(playerid, name, sizeof(name));
    PlayerInfo[playerid][pLocal] = 255;
    GetPlayerPos(playerid, px, py, pz);
    if(IsPlayerInMorro(playerid))
    {
        MorreuNoMorro[playerid] = 1;
        SetTimerEx("MorreuMorroTimer", 600000, false, "i", playerid);
    }
    if(IsPlayerInShop(playerid))
    {
        MorreuNoShop[playerid] = 1;
        SetTimerEx("MorreuShopTimer", 600000, false, "i", playerid);
    }
    if(IsPlayerInSkate(playerid))
    {
        MorreuNoSkate[playerid] = 1;
        SetTimerEx("MorreuSkateTimer", 600000, false, "i", playerid);
    }
    if(IsPlayerInPier(playerid))
    {
        MorreuNoPier[playerid] = 1;
        SetTimerEx("MorreuPierTimer", 600000, false, "i", playerid);
    }
    if(IsPlayerInAero(playerid))
    {
        MorreuNoAero[playerid] = 1;
        SetTimerEx("MorreuAeroTimer", 600000, false, "i", playerid);
    }
    if(killerid != 255)
    {
        new killername[MAX_PLAYER_NAME];
        new victimname[MAX_PLAYER_NAME];
        if(GetPlayerState(killerid) == 2)
        {
            GetPlayerName(killerid, killername, sizeof(killername));
            GetPlayerName(playerid, victimname, sizeof(killername));
            SendClientMessage(killerid, COLOR_YELLOW2, "[Atenзгo] Nгo abuse de [DRIVE BY].");
            format(string, sizeof(string), "[Aviso] %s fez Drive By em %s !!!", killername,victimname);
            SendClientMessageToAll(COLOR_SALMAO, string);
            PlayerInfo[killerid][pKills] += 1;
            WantedPoints[killerid] += 1;
            SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
            return 1;
        }
    }
    if (gPlayerCheckpointStatus[playerid] > 4 && gPlayerCheckpointStatus[playerid] < 11)
    {
        DisablePlayerCheckpoint(playerid);
        gPlayerCheckpointStatus[playerid] = CHECKPOINT_NONE;
    }
    new caller = Mobile[playerid];
    if(caller != 255)
    {
        if(caller < 255)
        {
            SendClientMessage(caller,  COLOR_YELLOW, " Ninguйm na linha...");
            CellTime[caller] = 0;
            CellTime[playerid] = 0;
            Mobile[caller] = 255;
        }
        Mobile[playerid] = 255;
        CellTime[playerid] = 0;
    }
    ClearCrime(playerid);
    if(PlayerPaintballing[playerid] != 0)
    {
        PlayerPaintballKills[killerid] ++;
        if(PlayerPaintballKills[killerid] > PaintballWinnerKills)
        {
            new killer[MAX_PLAYER_NAME];
            PaintballWinner = killerid;
            PaintballWinnerKills = PlayerPaintballKills[killerid];
            GetPlayerName(killerid, killer, sizeof(killer));
            for(new i = 0; i < MAX_PLAYERS; i++)
            {
                if(IsPlayerConnected(i))
                {
                    if(PlayerPaintballing[i] != 0)
                    {
                        format(string, sizeof(string), "%s estб liderando o paintball com %d pontos.",killer,PaintballWinnerKills);
                        SendClientMessage(i, COLOR_YELLOW, string);
                    }
                }
            }
        }
        return 1;
    }
    if(PlayerInfo[playerid][pHeadValue] > 0)
    {
        if(IsPlayerConnected(killerid))
        {
            if(PlayerInfo[killerid][pMember] == 8)
            {
                if(GoChase[killerid] == playerid)
                {
                    ConsumingMoney[killerid] = 1;
                    new killer[MAX_PLAYER_NAME];
                    GetPlayerName(killerid, killer, sizeof(killer));
                    GivePlayerGP(killerid, PlayerInfo[playerid][pHeadValue]);
                    format(string,128,"O assassino %s cumpriu o contrato а cabeзa de %s e adquiriu um valor de R$%d",killer,name,PlayerInfo[playerid][pHeadValue]);
                    SendClientMessageToAll(TEAM_GROVE_COLOR, string);
                    WantedPoints[killerid] += 1;
                    SetPlayerCriminal(killerid,255, "Homicнdio de primeiro grau");
                    SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
                    PlayerInfo[playerid][pHeadValue] = 0;
                    GotHit[playerid] = 0;
                    GetChased[playerid] = 999;
                    GoChase[killerid] = 999;
                }
            }
        }
    }
    if(PlayerInfo[playerid][pCabecaValue] > 0)
    {
        if(IsPlayerConnected(killerid))
        {
            if(PlayerInfo[killerid][pMember] == 22)
            {
                if(GoChasee[killerid] == playerid)
                {
                    ConsumingMoney[killerid] = 1;
                    new killer[MAX_PLAYER_NAME];
                    GetPlayerName(killerid, killer, sizeof(killer));
                    GivePlayerGP(killerid, PlayerInfo[playerid][pCabecaValue]);
                    format(string,128,"O Terrorista %s cometeu um atentado а %s e adquiriu um valor de R$%d",killer,name,PlayerInfo[playerid][pCabecaValue]);
                    SendClientMessageToAll(COLOR_YELLOW, string);
                    WantedPoints[killerid] += 1;
                    SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
                    SetPlayerCriminal(killerid,255, "Homicнdio de primeiro grau");
                    PlayerInfo[playerid][pCabecaValue] = 0;
                    GotHitt[playerid] = 0;
                    GetChasedd[playerid] = 999;
                    GoChasee[killerid] = 999;
                }
            }
        }
    }
    if(victimteam >= 4)
    {
        if(IsPlayerConnected(killerid))
        {
            //new killer[MAX_PLAYER_NAME];
            //GetPlayerName(killerid, killer, sizeof(killer));
            new slice = 100; //$100
            playercash = GetPlayerGP(playerid);
            if(gTeam[killerid] != 2 && gTeam[killerid] != 21)
            {
              WantedPoints[killerid] += 1;
              SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
            }
            if(SafeTime[playerid] <= 0)
            {
                if(gTeam[killerid] != gTeam[playerid])
                {
                    if(GetPlayerState(killerid) == 1)
                    {
                        PlayerInfo[killerid][pKills] = PlayerInfo[killerid][pKills] + 2;
                    }
                    else
                    {
                        PlayerInfo[killerid][pKills]++;
                    }
                    PlayerInfo[playerid][pKills]--;
                }
            }
            /*if (strlen(deathreason) > 0)// patch
            {
                if (((gTeam[killerid]) == 1) || ((gTeam[killerid]) == 3 && civnokill) || gTeam[killerid] == gTeam[playerid])//med kill criminal
                {
                    format(string, sizeof(string), ".: %s murdered %s. (%s) :.", killer, name, deathreason);
                }
                else
                {
                    format(string, sizeof(string), ".: %s murdered %s. (%s) for R$ %d :.", killer, name, deathreason, slice);
                }

            }
            else
            {
                if (((gTeam[killerid]) == 1) || ((gTeam[killerid]) == 3 && civnokill || gTeam[killerid] == gTeam[playerid]))
                {
                    format(string, sizeof(string), ".: %s murdered %s :.", killer, name);
                }
                else
                {
                    format(string, sizeof(string), ".: %s murdered %s for R$ %d :.", killer, name, slice);
                }
            }*/

            if (((gTeam[killerid]) == 1) || ((gTeam[killerid]) == 3 && civnokill) || (gTeam[killerid] == gTeam[playerid] && gTeam[playerid] != 4))
            {
                slice = 0;
            }
            if (((gTeam[killerid]) != 4) && ((gTeam[killerid]) == gTeam[playerid]))//no team kill
            {
                slice = 0;
            }
            if (playercash > 0)
            {
                GivePlayerGP(playerid, -slice);
            }
            else
            {
                slice = slice+500;
            }
            GivePlayerGP(killerid, slice);
            //GameTextForPlayer(playerid, dmessage, 5000, 2);
            PlayerPlaySound(killerid, 1083, 0.0, 0.0, 0.0);
            if (((gTeam[killerid]) == 3) && reason != 49)
            {
                SetPlayerCriminal(killerid,255, "Homicнdio de primeiro grau");
                TextDrawHideForPlayer(killerid,tGP2[killerid]);
                TextDrawShowForPlayer(killerid,tGP3[killerid]);
            }
            else if (((gTeam[killerid]) == 3) && reason == 49)
            {
                SetPlayerCriminal(killerid,255, "Drive By");
            }
        }
    }
    else if (victimteam == 2)
    {
        if(IsPlayerConnected(killerid))
        {
            //new killer[MAX_PLAYER_NAME];
            //GetPlayerName(killerid, killer, sizeof(killer));
            // Cop kill
            PlayerInfo[playerid][pKills]--;
            if (gTeam[killerid] == 2)//cops kill cop
            {
                //format(string,128,".: Officer %s murdered Officer %s (%s) and was sued for R$ %d :.",killer,name,deathreason,suecost);
                PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
                GivePlayerGP(killerid, -suecost);
                GivePlayerGP(playerid, suecost+100);//+100pays hospital bill
            }
            else
            {
                //format(string,128,".: %s murdered Officer %s (%s) :.",killer,name,deathreason);
            }
            if (gTeam[killerid] >= 3)
            {
                WantedPoints[killerid] += 1; //+ 2 wanted point
                SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
                if(reason != 49)
                {
                    SetPlayerCriminal(killerid,255, "Homicнdio de primeiro grau");
                }
                else if (reason == 49)
                {
                    SetPlayerCriminal(killerid,255, "Drive By");
                }
            }
            if(gTeam[killerid] >= 5 && SafeTime[playerid] <= 0)
            {
                if(GetPlayerState(killerid) == 1)
                {
                    PlayerInfo[killerid][pKills] = PlayerInfo[killerid][pKills]+2;
                }
                else
                {
                    PlayerInfo[killerid][pKills]++;
                }
                WantedPoints[killerid]+=1;
                SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
            }
            //BroadCast(COLOR_RED, string);
        }
    }
    else if (victimteam == 3)
    {
        if(IsPlayerConnected(killerid))
        {
            //new killer[MAX_PLAYER_NAME];
            //GetPlayerName(killerid, killer, sizeof(killer));
            // Civ kill
            if ((gTeam[killerid]) == 2)//cops kill civ
            {
                if(WantedPoints[playerid] < 1)
                {
                    //format(string,128,".: Officer %s murdered %s (%s) and was sued for R$ %d :.",killer,name,deathreason,suecost);
                    PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
                    GivePlayerGP(killerid, -suecost);
                    GivePlayerGP(playerid, suecost+100);//+100pays hospital bill
                }
            }
            else
            {
                //format(string,128,".: %s murdered %s (%s) :.",killer,name,deathreason);
                WantedPoints[killerid] += 1;
                SetPlayerWantedLevel(killerid, WantedPoints[killerid]);
            }
            if (((gTeam[killerid]) >= 3 || (gTeam[killerid]) == 1) && reason != 49)
            {
                SetPlayerCriminal(killerid,255, "Homicнdio de primeiro grau");
            }
            else if (((gTeam[killerid]) >= 3 || (gTeam[killerid]) == 1) && reason == 49)
            {
                SetPlayerCriminal(killerid,255, "Drive By");
            }
            //BroadCast(COLOR_RED, string);
        }
    }
    else if (victimteam == 1)
    {
        if(IsPlayerConnected(killerid))
        {
            //new killer[MAX_PLAYER_NAME];
            //GetPlayerName(killerid, killer, sizeof(killer));
            // Civ kill
            if ((gTeam[killerid]) == 2)//cops kill civ
            {
                //format(string,128,".: Officer %s murdered Paramedic %s (%s) and was sued for R$ %d :.",killer,name,deathreason,suecost);
                PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
                GivePlayerGP(killerid, -suecost);
                GivePlayerGP(playerid, suecost+100);//+100pays hospital bill
            }
            else if ((gTeam[killerid]) == 1)//med kill civ
            {
                //format(string,128,".: Paramedic %s murdered %s (%s) and was sued for R$ %d :.",killer,name,deathreason,suecost);
                PlayerPlaySound(killerid, 1084, 0.0, 0.0, 0.0);
                GivePlayerGP(killerid, -suecost);
                GivePlayerGP(playerid, suecost+100);//+100pays hospital bill
            }
            else
            {
           
                //format(string,128,".: %s murdered %s (%s) :.",killer,name,deathreason);
            }
            if (((gTeam[killerid]) == 4) && reason != 49)
            {
                SetPlayerCriminal(killerid,255, "Homicнdio de primeiro grau");
            }
            else if (((gTeam[killerid]) == 3) && reason == 49)
            {
                SetPlayerCriminal(killerid,255, "Drive By");
            }
            //BroadCast(COLOR_RED, string);
        }
    }
    if (victimteam >= 3 && WantedPoints[playerid] > 0 && killerteam == 2)
    {
        SetPlayerFree(playerid,killerid, "Morto !");
    }
        killerid = INVALID_PLAYER_ID;
        SetPlayerColor(playerid,COLOR_GRAD2);
        return 1;
    }

public OnPlayerSpawn(playerid)
{
        PlayerPlaySound(playerid, 1057, Xs, Ys, Zs);
        SetPlayerSkillLevel(playerid, WEAPONSKILL_MICRO_UZI, 450);
        if(IsPlayerNPC(playerid)) //Checa se o jogador й um NPC.
        {
                new npcname[MAX_PLAYER_NAME];
                GetPlayerName(playerid, npcname, sizeof(npcname)); //Obtendo o nome do(s) NPC(s).
                if(!strcmp(npcname, "Tio_Xico", true)) //Checando se o nome do NPC й MeuPrimeiroNPC
                {
                    SetPlayerSkin(playerid, 94);
                    return 1;
                }
                if(!strcmp(npcname, "Policial_Dp", true)) //Checando se o nome do NPC й MeuPrimeiroNPC
                {
                    PutPlayerInVehicle(playerid, Random, 0);
                    SetPlayerSkin(playerid, 281);
                    GivePlayerWeapon(playerid, 30, 200);
                    return 1;

                }
            }


    TextDrawShowForPlayer(playerid, Time), TextDrawShowForPlayer(playerid, Date);
    TextDrawShowForPlayer(playerid, TextdrawB);
    TextDrawShowForPlayer(playerid, tGP2[playerid]);

    InitLockDoors(playerid);
    SetPlayerHealth(playerid, 100);
    STDPlayer[playerid] = 0;
    gTeam[playerid] = PlayerInfo[playerid][pTeam]; //Set the Team
    gGas[playerid] = 1;
    for(new i=0;i<sizeof(Turfs);i++)
    {
        for(new gangid; gangid < MAX_PLAYERS; gangid++)
        {
            if(TurfInfo[i][zMemberDie] == playerid)
            {
                if(PlayerInfo[gangid][pMember] == PlayerInfo[playerid][pMember])
                {
                    if(i == 0){GangZoneFlashForPlayer(gangid, i, TEAM_GROVE_COLOR);}
                    if(i == 1){GangZoneFlashForPlayer(gangid, i, COLOR_YELLOW);}
                    if(i == 2){GangZoneFlashForPlayer(gangid, i, TEAM_BALLAS_COLOR);}
                    if(i == 3){GangZoneFlashForPlayer(gangid, i, TEAM_AZTECAS_COLOR);}
                    if(i == 4){GangZoneFlashForPlayer(gangid, i, TEAM_COMANDO_COLOR);}
                    if(i == 5){GangZoneFlashForPlayer(gangid, i, TEAM_PCC_COLOR);}
                }
                if(i == 0){GangZoneFlashForPlayer(gangid, i, TEAM_GROVE_COLOR);}
                if(i == 1){GangZoneFlashForPlayer(gangid, i, COLOR_YELLOW);}
                if(i == 2){GangZoneFlashForPlayer(gangid, i, TEAM_BALLAS_COLOR);}
                if(i == 3){GangZoneFlashForPlayer(gangid, i, TEAM_AZTECAS_COLOR);}
                if(i == 4){GangZoneFlashForPlayer(gangid, i, TEAM_COMANDO_COLOR);}
                if(i == 5){GangZoneFlashForPlayer(gangid, i, TEAM_PCC_COLOR);}
                TurfInfo[i][zMemberDie] = -1;
            }
        }
    }
    if (gTeam[playerid] == 4) //medic / criminal reset team
    {
        gTeam[playerid] = 3;
    }
    if(gTeam[playerid] == 11 && PlayerInfo[playerid][pLeader] < 1)
    {
        Hospital[playerid] = 0;
        new rand = random(sizeof(CIV));
        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);
    }
    if(gTeam[playerid] == 5)
    {
        if(PlayerInfo[playerid][pMember] < 1)
        {
            Hospital[playerid] = 0;
            new rand = random(sizeof(CIV));
            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);
        }
    }
    if(gTeam[playerid] == 10)
    {
        if(PlayerInfo[playerid][pMember] != 8)
        {
            Hospital[playerid] = 0;
            new rand = random(sizeof(CIV));
            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);
        }
    }
    if(gTeam[playerid] == 2 && PlayerInfo[playerid][pMember] > 3)
    {
        Hospital[playerid] = 0;
        new rand = random(sizeof(CIV));
        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);
    }
    if(gTeam[playerid] == 3)
    {
        if(PlayerInfo[playerid][pMember] > 0 || PlayerInfo[playerid][pLeader] > 0)
        {
            Hospital[playerid] = 0;
            new model = PlayerInfo[playerid][pChar];
            if(PlayerInfo[playerid][pMember] == 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][pMember] == 2) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 3) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 2; gTeam[playerid] = 2; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 4) { SetSpawnInfo(playerid, 1, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 1; gTeam[playerid] = 1; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 5) { SetSpawnInfo(playerid, 5, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 6) { SetSpawnInfo(playerid, 5, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 8) { SetSpawnInfo(playerid, 10, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 10; gTeam[playerid] = 10; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 9) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 7) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 11) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 12; gTeam[playerid] = 12; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 16) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 12) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 13) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 14) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 14; gTeam[playerid] = 14; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 10) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 18) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 19) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 20) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 21) { SetSpawnInfo(playerid, 2, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 21; gTeam[playerid] = 21; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pMember] == 22) { SetSpawnInfo(playerid, 12, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 22; gTeam[playerid] = 22; PlayerInfo[playerid][pModel] = model; }
       

            else if(PlayerInfo[playerid][pLeader] == 1) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 2) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 3) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 4) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 5) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 6) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 7) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 8) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 9) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 11) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 14) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 16) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 16; gTeam[playerid] = 16; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 12) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 13) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 7; gTeam[playerid] = 7; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 10) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 14) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 18) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 19) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 20) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 21) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; PlayerInfo[playerid][pModel] = model; }
            else if(PlayerInfo[playerid][pLeader] == 22) { SetSpawnInfo(playerid, 11, model,1446.3839,-2287.1284,13.5469,0,0,0,0,0,0,0); PlayerInfo[playerid][pTeam] = 11; gTeam[playerid] = 11; 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][pMember] == 11)
    {
        SetPlayerSkin(playerid, 217);
    }

    if(PlayerInfo[playerid][pChar] > 0) { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
    else { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
    SetPlayerWeapons(playerid);
    SetPlayerSpawn(playerid);
    SetPlayerToTeamColor(playerid);
    PlayerFixRadio(playerid);
    for(new i = 0; i < sizeof(Turfs); i++)
    {
        GangZoneShowForAll(i, TurfInfo[i][zColor]);
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)