Set Player Skin
#10

Look at this:

pawn Код:
public OnPlayerSpawn(playerid)
{
    // Anti F4 Bug - Logging/Registering
    if(!PlayerInfo[playerid][pLoggedIn] && !IsPlayerNPC(playerid))
    {
        if(IsPlayerNPC(playerid)) return 1;
        SetPlayerSkin(playerid, 29);
        SetPlayerPos(playerid, 1975.203002, 3779.311523, -50.243506);
        SetPlayerCameraPos(playerid, 1975.203002, 3779.311523, 100.243506);
        SetPlayerCameraLookAt(playerid, 1975.203002, 3779.311523, -0.243506);
        SetSpawnInfo(playerid, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
        new file[64];
        format(file, sizeof(file), "users/%s.ini", RPNU(playerid));
        // Player isn't banned
        if(dini_Int(file, "AdminAccount") == 1)
        {
            format(file, sizeof(file), "users/%s.ini",RPNU(playerid));
            SetPlayerName(playerid, dini_Get(file, "OldName"));
            format(file, sizeof(file), "users/%s.ini", RPNU(playerid));
            ShowDialog(playerid, 2);
        }
        if(!dini_Exists(file))
        {
            ShowDialog(playerid, 1);
            return 1;
        }
        else
        {
            ShowDialog(playerid, 2);
        }
        return 1;
    }
    // Actual Spawning
    ResetPlayerWeapons(playerid);
    if(IsPlayerNPC(playerid)) //Checks if the player that just spawned is an NPC.
    {
      new npcname[MAX_PLAYER_NAME];
      GetPlayerName(playerid, npcname, sizeof(npcname)); //Getting the NPC's name.
      if(!strcmp(npcname, "BusDriver", true)) //Checking if the NPC's name is BusDriver
      {
        PutPlayerInVehicle(playerid, NPCBus, 0); //Putting the NPC into the vehicle we created for it.
        return 1;
      }
      return 1;
    }
    if(PlayerInfo[playerid][pLoggedIn] && PlayerInfo[playerid][pSpawn])
    {
        FalseBan[playerid] = 0;
        SetTimerEx("FalseBanFix", 6000, false, "i", playerid);
        SpawnChar(playerid);
    }
    return 1;
}
Reply


Messages In This Thread
Set Player Skin - by Fiore - 22.10.2012, 16:55
Re: Set Player Skin - by Mustafa6155 - 22.10.2012, 16:58
Re: Set Player Skin - by DeathTone - 22.10.2012, 16:59
Re: Set Player Skin - by Fiore - 22.10.2012, 17:20
Re: Set Player Skin - by lorizz - 22.10.2012, 19:18
Re: Set Player Skin - by Alex Magaсa - 22.10.2012, 19:25
Re: Set Player Skin - by KevinPRINCE - 22.10.2012, 21:10
Re: Set Player Skin - by Fiore - 22.10.2012, 22:30
Re: Set Player Skin - by lorizz - 23.10.2012, 14:25
Re: Set Player Skin - by Fiore - 23.10.2012, 15:00

Forum Jump:


Users browsing this thread: 1 Guest(s)