Problem with jail
#9

Code :

Код:
//==============================================================================
public OnPlayerSpawn(playerid)
{
    if (!GetPVarInt(playerid, "color")) SetPVarInt(playerid, "color", 18643);
    
    if(PlayerInfo[playerid][pJailed])
    {
             //Set player's coordinates back to jail
    }
    else
    {
            //The rest of your code
    }
    
    PlayerPlaySound(playerid, 1069, 0.0, 0.0, 0.0);
    FlashZoneForPlayer(playerid);
    SetPlayerInterior(playerid, 0);
    SetPlayerVirtualWorld(playerid, 0);
    SetPlayerScore(playerid, PlayerInfo[playerid][pKills]);
    SetPlayerSkillLevel(playerid,0,999);
	SetPlayerSkillLevel(playerid,1,999);
	SetPlayerSkillLevel(playerid,2,999);
	SetPlayerSkillLevel(playerid,3,999);
	SetPlayerSkillLevel(playerid,4,999);
	SetPlayerSkillLevel(playerid,5,999);
	SetPlayerSkillLevel(playerid,6,999);
	SetPlayerSkillLevel(playerid,7,999);
	SetPlayerSkillLevel(playerid,8,999);
	SetPlayerSkillLevel(playerid,9,999);
	SetPlayerSkillLevel(playerid,10,999);
	for (new i = 0; i < MAX_TURFS; i++) GangZoneShowForPlayer(playerid, turfs[i][turfID], turfs[i][TurfColor]);
	SetPlayerToTeamColor(playerid);
	SetPlayerSpawn(playerid);
	if(PlayerInfo[playerid][pMember] == TEAM_GROVE)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_BALLAS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_VAGOS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_AZTECAS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_TRIADS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_YAKUZA)
	{
        GivePlayerGun(playerid, 8); //katana
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_CRIPZ)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_BADBOYS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_POLICE)
	{
        GivePlayerGun(playerid, 3); //palka
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_LVPD)
	{
        GivePlayerGun(playerid, 3); //palka
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_JIZZY)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
    else if(PlayerInfo[playerid][pMember] == TEAM_BLOODS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_BIKERBOYS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_ASIANTRIADS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_MIB)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_RUS)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_ARMY)
	{
        GivePlayerGun(playerid, 4); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_AFARMY)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
	}
	else if(PlayerInfo[playerid][pMember] == TEAM_CIA)
	{
        GivePlayerGun(playerid, 5); //knife
	    GivePlayerGun(playerid, 24); //Deagle
	    GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32); //Tec9
	    GivePlayerGun(playerid, 31); //M4
	    GivePlayerGun(playerid, 34); //SNIPER
 	}
	else if(PlayerInfo[playerid][pMember] == TEAM_CIVILIAN)
	{
        GivePlayerGun(playerid, 26); //Automatic Shotgun
	    GivePlayerGun(playerid, 32);//tec9
	    GivePlayerGun(playerid, 24);//deagle
	}
	if(PlayerInfo[playerid][aDuty] == 1)
	{
		SendClientMessage(playerid, COLOR_GREEN,"Ти си на администраторска смяна, използвай командата /aduty за да излезеш от администраторската смяна!");
		SetPlayerColor(playerid, COLOR_ADMIN);
		SetPlayerHealth(playerid, 100);
		SetPlayerArmour(playerid, 100);
	}
	if(PlayerInfo[playerid][pJailed] == 1)
	{
   		SetPlayerWantedLevel(playerid, 0);
	    SetPlayerInterior(playerid, 3);
		SetPlayerPos(playerid,974.01,-9.59,1001.14);
		SendClientMessage(playerid, COLOR_LIGHTRED, "Ти излежа присъдата си в затвора,може да се върнеш към света без решетки.");
		return 1;
	}
	return 1;
}
Reply


Messages In This Thread
Problem with jail - by Ruffian - 09.09.2012, 15:24
Re: Problem with jail -.- - by AaronKillz - 09.09.2012, 15:27
Re: Problem with jail -.- - by antonio112 - 09.09.2012, 15:47
Re: Problem with jail -.- - by Ruffian - 09.09.2012, 15:56
Re: Problem with jail -.- - by Guitar - 09.09.2012, 15:59
Re: Problem with jail -.- - by antonio112 - 09.09.2012, 16:00
Re: Problem with jail -.- - by Ruffian - 09.09.2012, 16:00
Re: Problem with jail -.- - by antonio112 - 09.09.2012, 16:02
Re: Problem with jail -.- - by Ruffian - 09.09.2012, 16:03
Re: Problem with jail -.- - by antonio112 - 09.09.2012, 16:06

Forum Jump:


Users browsing this thread: 2 Guest(s)