[HELP] SPAWN
#1

I go on a account, login and i were in the sky. Zhe cordinates are okay, i realy dont know.
sorry very bad english :P

http://i.imgur.com/PYeQU.png

pawn Код:
public OnPlayerSpawn(playerid)
{
//------------------------------------------------------------------------------
        InitLockDoors(playerid);
        STDPlayer[playerid] = 0;
        if(IsPlayerNPC(playerid)) return 1;
//------------------------------------------------------------------------------

        if(PlayerInfo[playerid][pMember] == 0 || PlayerInfo[playerid][pLeader] == 0)
        {
            SetPlayerToTeamColor(playerid);
            SetPlayerInterior(playerid,0);
            SetPlayerPos(playerid, 1715.8232,-1931.6327,13.5680);
            SetPlayerFacingAngle(playerid, 180);
            PlayerInfo[playerid][pInt] = 0;
            return 1;
        }
        if (gTeam[playerid] == 4) //medic / criminal reset team
        {
                gTeam[playerid] = 3;
        }
        if(gPlayerLogged[playerid] == 0)
        {
        SendClientMessage(playerid, COLOR_LIGHTRED, "**Moras se logirati prije spawna **");
        KickPlayer[playerid] = 1;
        }
        if(gTeam[playerid] == 11 && PlayerInfo[playerid][pLeader] < 1)
        {
            MedicBill[playerid] = 0;
            new rand = random(sizeof(CIV));
                SendClientMessage(playerid, COLOR_LIGHTRED, "Ti nisi jedan lider ti si ponovo civil !");
                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)
            {
                MedicBill[playerid] = 0;
                new rand = random(sizeof(CIV));
                        SendClientMessage(playerid, COLOR_LIGHTRED, "Nisi clan Family-e, sada si Civil !");
            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)
            {
                MedicBill[playerid] = 0;
                new rand = random(sizeof(CIV));
                        SendClientMessage(playerid, COLOR_LIGHTRED, "You are not a Member of this Agency, you are now a Civilian !");
            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)
        {
            MedicBill[playerid] = 0;
                new rand = random(sizeof(CIV));
                SendClientMessage(playerid, COLOR_LIGHTRED, "You haven't applied for being an Officer / FBI / National Guard, you are now a Civilian !");
                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(PlayerInfo[playerid][pChar] > 0) { SetPlayerSkin(playerid, PlayerInfo[playerid][pChar]); }
        else { SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); }
        SetPlayerWeapons(playerid);
        SetPlayerSpawn(playerid);
        SetPlayerToTeamColor(playerid);
        for(new i = 0; i < sizeof(Turfs); i++)
        {
            GangZoneShowForPlayer(playerid, i, TurfInfo[i][zColor]);
        }
        return 1;
}



public CKLog(string[])
{
        new entry[256];
        format(entry, sizeof(entry), "%s\n",string);
        new File:hFile;
        hFile = fopen("ck.log", io_append);
        fwrite(hFile, entry);
        fclose(hFile);
}

public PayLog(string[])
{
        new entry[256];
        format(entry, sizeof(entry), "%s\n",string);
        new File:hFile;
        hFile = fopen("pay.log", io_append);
        fwrite(hFile, entry);
        fclose(hFile);
}

public KickLog(string[])
{
        new entry[256];
        format(entry, sizeof(entry), "%s\n",string);
        new File:hFile;
        hFile = fopen("kick.log", io_append);
        fwrite(hFile, entry);
        fclose(hFile);
}

public BanLog(string[])
{
        new entry[256];
        format(entry, sizeof(entry), "%s\n",string);
        new File:hFile;
        hFile = fopen("ban.log", io_append);
        fwrite(hFile, entry);
        fclose(hFile);
}

public AdmWarnLog(string[])
{
        new entry[256];
        format(entry, sizeof(entry), "%s\n",string);
        new File:hFile;
        hFile = fopen("admwarn.log", io_append);
        fwrite(hFile, entry);
        fclose(hFile);
}
Reply


Messages In This Thread
[HELP] SPAWN - by Edin Black - 19.07.2012, 18:05
Re: [HELP] SPAWN - by nepstep - 19.07.2012, 18:09
Respuesta: [HELP] SPAWN - by farCry.xD - 19.07.2012, 18:14
Re: [HELP] SPAWN - by Edin Black - 19.07.2012, 18:21
Re: Respuesta: [HELP] SPAWN - by Edin Black - 19.07.2012, 18:35
Re: [HELP] SPAWN - by XStormiest - 19.07.2012, 18:42
Re: [HELP] SPAWN - by Edin Black - 19.07.2012, 18:55
Re: [HELP] SPAWN - by nepstep - 19.07.2012, 19:05
Re: [HELP] SPAWN - by Edin Black - 19.07.2012, 19:26
Re: [HELP] SPAWN - by nepstep - 19.07.2012, 19:29

Forum Jump:


Users browsing this thread: 1 Guest(s)