error 054: unmatched closing brace ("}")
#1

The line is the very last peice of code at the bottom where the "}" is

error 054: unmatched closing brace ("}")

pawn Код:
PayDay(i)
{
    new string[128];
    new interest;
    if(PlayerInfo[i][pLevel] > 0)
    {
        if(GetPVarType(i, "debtMsg"))
        {
            if(GetPlayerCash(i) < 0 && PlayerInfo[i][pJailTime] < 1 && !IsACop(i) && PlayerInfo[i][pWantedLevel] < 6)
            {
                format(string,sizeof(string),"You're failing to pay your debt of $%d - now the police are on the look out for you.",GetPlayerCash(i));
                SendClientMessage(i, COLOR_LIGHTRED, string);
                PlayerInfo[i][pCrimes]++;
                SetPlayerWantedLevel(i, ++PlayerInfo[i][pWantedLevel]);
            }
            else DeletePVar(i, "debtMsg");
        }
        if(0 <= PlayerInfo[i][pRenting] < sizeof HouseInfo)
        {
            if(HouseInfo[PlayerInfo[i][pRenting]][hRentFee] > PlayerInfo[i][pAccount])
            {
                PlayerInfo[i][pRenting] = INVALID_HOUSE_ID;
                SendClientMessage(i, COLOR_WHITE, "You have been evicted from your residence for failing to pay rent fees.");
            }
            else
            {
                HouseInfo[PlayerInfo[i][pRenting]][hSafeMoney] += HouseInfo[PlayerInfo[i][pRenting]][hRentFee];
                PlayerInfo[i][pAccount] -= HouseInfo[PlayerInfo[i][pRenting]][hRentFee];
            }
        }
        if(PlayerInfo[i][pPlayTime] >= 4500)
        {
            if(GetPVarType(i, "AdvisorDuty"))
            {
                PlayerInfo[i][pDutyHours]++;
            }
            SendClientMessage(i, COLOR_WHITE, "________ BANK STATEMENT ________");
            format(string, sizeof(string), "  Paycheck: $%d  |  Tax: $%d (%d percent)", PlayerInfo[i][pPayCheck], (PlayerInfo[i][pPayCheck] / 100) * TaxValue, TaxValue);
            SendClientMessage(i, COLOR_GRAD1, string);
            interest = (PlayerInfo[i][pAccount] + 1) / 1000;
            if(PlayerInfo[i][pTaxiLicense] == 1)
            {
                PlayerInfo[i][pAccount] -= (PlayerInfo[i][pPayCheck] / 100) * 5;
                Tax += (PlayerInfo[i][pPayCheck] / 100) * 5;
                format(string, sizeof(string), "  Taxi licensing fee (5 percent): $%d", (PlayerInfo[i][pPayCheck] / 100) * 5);
                SendClientMessage(i, COLOR_GRAD2, string);
            }
            PlayerInfo[i][pAccount] -= (PlayerInfo[i][pPayCheck] / 100) * TaxValue;
            Tax += (PlayerInfo[i][pPayCheck] / 100) * TaxValue;
            PlayerInfo[i][pAccount] += interest;
            format(string, sizeof(string), "  Interest gained: $%d", interest);
            SendClientMessage(i, COLOR_GRAD3, string);
            SendClientMessage(i, COLOR_GRAD4, "______________________________________");
            format(string, sizeof(string), "  New balance: $%d  |  Rent paid: $%d", PlayerInfo[i][pAccount], (0 <= PlayerInfo[i][pRenting] < sizeof HouseInfo) ? (HouseInfo[PlayerInfo[i][pRenting]][hRentFee]) : (0));
            SendClientMessage(i, COLOR_GRAD5, string);

            GivePlayerCash(i, PlayerInfo[i][pPayCheck]);
            if((1 <= PlayerInfo[i][pMember] <= 12 || PlayerInfo[i][pMember] == 16) && PlayerInfo[i][pMember] != 8 && 0 <= PlayerInfo[i][pRank] <= 6)
            {
                if(TaxSystem > 0)
                {
                    TaxSystem -= FactionPay[PlayerInfo[i][pMember] - 1][PlayerInfo[i][pRank]];
                    GivePlayerCash(i, FactionPay[PlayerInfo[i][pMember] - 1][PlayerInfo[i][pRank]]);
                    format(string,sizeof(string),"  Government pay: $%d", FactionPay[PlayerInfo[i][pMember] - 1][PlayerInfo[i][pRank]]);
                    SendClientMessage(i, COLOR_GRAD2, string);
                }
                else SendClientMessage(i,COLOR_RED,"The government is in debt; no money is available for pay.");
            }
            GameTextForPlayer(i, "~y~PayDay~n~~w~Paycheck", 5000, 1);
            PlayerInfo[i][pPlayTime] = 0;
            PlayerInfo[i][pPayCheck] = 0;
            }
        }
        else SendClientMessage(i, COLOR_LIGHTRED, "* You haven't played long enough to obtain a paycheck.");
    }
}
Reply
#2

pawn Код:
PayDay(i)
{
    new string[128];
    new interest;
    if(PlayerInfo[i][pLevel] > 0)
    {
        if(GetPVarType(i, "debtMsg"))
        {
            if(GetPlayerCash(i) < 0 && PlayerInfo[i][pJailTime] < 1 && !IsACop(i) && PlayerInfo[i][pWantedLevel] < 6)
            {
                format(string,sizeof(string),"You're failing to pay your debt of $%d - now the police are on the look out for you.",GetPlayerCash(i));
                SendClientMessage(i, COLOR_LIGHTRED, string);
                PlayerInfo[i][pCrimes]++;
                SetPlayerWantedLevel(i, ++PlayerInfo[i][pWantedLevel]);
            }
            else DeletePVar(i, "debtMsg");
        }
        if(0 <= PlayerInfo[i][pRenting] < sizeof HouseInfo)
        {
            if(HouseInfo[PlayerInfo[i][pRenting]][hRentFee] > PlayerInfo[i][pAccount])
            {
                PlayerInfo[i][pRenting] = INVALID_HOUSE_ID;
                SendClientMessage(i, COLOR_WHITE, "You have been evicted from your residence for failing to pay rent fees.");
            }
            else
            {
                HouseInfo[PlayerInfo[i][pRenting]][hSafeMoney] += HouseInfo[PlayerInfo[i][pRenting]][hRentFee];
                PlayerInfo[i][pAccount] -= HouseInfo[PlayerInfo[i][pRenting]][hRentFee];
            }
        }
        if(PlayerInfo[i][pPlayTime] >= 4500)
        {
            if(GetPVarType(i, "AdvisorDuty"))
            {
                PlayerInfo[i][pDutyHours]++;
            }
            SendClientMessage(i, COLOR_WHITE, "________ BANK STATEMENT ________");
            format(string, sizeof(string), "  Paycheck: $%d  |  Tax: $%d (%d percent)", PlayerInfo[i][pPayCheck], (PlayerInfo[i][pPayCheck] / 100) * TaxValue, TaxValue);
            SendClientMessage(i, COLOR_GRAD1, string);
            interest = (PlayerInfo[i][pAccount] + 1) / 1000;
            if(PlayerInfo[i][pTaxiLicense] == 1)
            {
                PlayerInfo[i][pAccount] -= (PlayerInfo[i][pPayCheck] / 100) * 5;
                Tax += (PlayerInfo[i][pPayCheck] / 100) * 5;
                format(string, sizeof(string), "  Taxi licensing fee (5 percent): $%d", (PlayerInfo[i][pPayCheck] / 100) * 5);
                SendClientMessage(i, COLOR_GRAD2, string);
            }
            PlayerInfo[i][pAccount] -= (PlayerInfo[i][pPayCheck] / 100) * TaxValue;
            Tax += (PlayerInfo[i][pPayCheck] / 100) * TaxValue;
            PlayerInfo[i][pAccount] += interest;
            format(string, sizeof(string), "  Interest gained: $%d", interest);
            SendClientMessage(i, COLOR_GRAD3, string);
            SendClientMessage(i, COLOR_GRAD4, "______________________________________");
            format(string, sizeof(string), "  New balance: $%d  |  Rent paid: $%d", PlayerInfo[i][pAccount], (0 <= PlayerInfo[i][pRenting] < sizeof HouseInfo) ? (HouseInfo[PlayerInfo[i][pRenting]][hRentFee]) : (0));
            SendClientMessage(i, COLOR_GRAD5, string);

            GivePlayerCash(i, PlayerInfo[i][pPayCheck]);
            if((1 <= PlayerInfo[i][pMember] <= 12 || PlayerInfo[i][pMember] == 16) && PlayerInfo[i][pMember] != 8 && 0 <= PlayerInfo[i][pRank] <= 6)
            {
                if(TaxSystem > 0)
                {
                    TaxSystem -= FactionPay[PlayerInfo[i][pMember] - 1][PlayerInfo[i][pRank]];
                    GivePlayerCash(i, FactionPay[PlayerInfo[i][pMember] - 1][PlayerInfo[i][pRank]]);
                    format(string,sizeof(string),"  Government pay: $%d", FactionPay[PlayerInfo[i][pMember] - 1][PlayerInfo[i][pRank]]);
                    SendClientMessage(i, COLOR_GRAD2, string);
                }
                else SendClientMessage(i,COLOR_RED,"The government is in debt; no money is available for pay.");
            }
            GameTextForPlayer(i, "~y~PayDay~n~~w~Paycheck", 5000, 1);
            PlayerInfo[i][pPlayTime] = 0;
            PlayerInfo[i][pPayCheck] = 0;
        }
        else SendClientMessage(i, COLOR_LIGHTRED, "* You haven't played long enough to obtain a paycheck.");
    }
}
Reply
#3

What did you change ?
Reply
#4

Removed an unnecessary closing bracket "}" which was on the line 5 from the bottom.
Reply
#5

Thank you! +Rep
Reply
#6

I have the same problem

Код:
 public OnPlayerRequestClass(playerid, classid)
{

	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2480.8901,-1536.6035,24.1829,268.8467);
		SetPlayerFacingAngle(playerid,268.8467);
		SetPlayerCameraPos(playerid,2484.2258,-1536.7886,24.0013,88.8468);
		SetPlayerCameraLookAt(playerid,2480.8901,-1536.6035,24.1829,268.8467);
		ApplyAnimation(playerid, "PED", "phone_talk", 4.1, 0, 1, 1, 1, 1, 1);
		}
		if(classid == 13)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid, 936.3463,-1103.2695,24.3137,267.6657);
		SetPlayerFacingAngle(playerid,267.6657);
		SetPlayerCameraPos(playerid, 948.5059,-1103.6152,24.1295,87.6657);
		SetPlayerCameraLookAt(playerid, 936.3463,-1103.2695,24.3137,267.6657);
        ApplyAnimation(playerid, "PED", "WALK_gang1", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 14)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid, 936.3463,-1103.2695,24.3137,267.6657);
		SetPlayerFacingAngle(playerid,267.6657);
		SetPlayerCameraPos(playerid, 948.5059,-1103.6152,24.1295,87.6657);
		SetPlayerCameraLookAt(playerid, 936.3463,-1103.2695,24.3137,267.6657);
		ApplyAnimation(playerid, "PED", "WALK_gang1", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 39)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1206.8037,-1161.9932,23.4886,91.1619);
		SetPlayerFacingAngle(playerid,91.1619);
		SetPlayerCameraPos(playerid,1210.2382,-1161.9072,23.4248,88.6553);
		SetPlayerCameraLookAt(playerid,1206.8037,-1161.9932,23.4886,91.1619);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	    if(classid == 40)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1206.8037,-1161.9932,23.4886,91.1619);
		SetPlayerFacingAngle(playerid,91.1619);
		SetPlayerCameraPos(playerid, 1210.2382,-1161.9072,23.4248,88.6553);
		SetPlayerCameraLookAt(playerid,1206.8037,-1161.9932,23.4886,91.1619);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	    if(classid == 41)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1206.8037,-1161.9932,23.4886,91.1619);
		SetPlayerFacingAngle(playerid,91.1619);
		SetPlayerCameraPos(playerid,1210.2382,-1161.9072,23.4248,88.6553);
		SetPlayerCameraLookAt(playerid,1206.8037,-1161.9932,23.4886,91.1619);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 29)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,709.0796,-1609.0201,9.1260,85.6029);
		SetPlayerFacingAngle(playerid,85.6029);
		SetPlayerCameraPos(playerid,704.2338,-1608.7395,9.1260,268.5679);
		SetPlayerCameraLookAt(playerid,709.0796,-1609.0201,9.1260,85.6029);
		ApplyAnimation(playerid, "RAPPING", "Laugh_01", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 30)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,709.0796,-1609.0201,9.1260,85.6029);
		SetPlayerFacingAngle(playerid,85.6029);
		SetPlayerCameraPos(playerid,704.2338,-1608.7395,9.1260,268.5679);
		SetPlayerCameraLookAt(playerid,709.0796,-1609.0201,9.1260,85.6029);
		ApplyAnimation(playerid, "RAPPING", "Laugh_01", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 34)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,305.2606,-1770.2201,4.5381,0.6967);
		SetPlayerFacingAngle(playerid,0.6967);
		SetPlayerCameraPos(playerid,305.5800,-1773.9879,4.5850,0.6966);
		SetPlayerCameraLookAt(playerid,305.2606,-1770.2201,4.5381,0.6967);
		ApplyAnimation(playerid, "POLICE", "Door_Kick", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 35)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,305.2606,-1770.2201,4.5381,0.6967);
		SetPlayerFacingAngle(playerid,0.6967);
		SetPlayerCameraPos(playerid,305.5800,-1773.9879,4.5850,0.6966);
		SetPlayerCameraLookAt(playerid,305.2606,-1770.2201,4.5381,0.6967);
		ApplyAnimation(playerid, "POLICE", "Door_Kick", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 36)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,305.2606,-1770.2201,4.5381,0.6967);
		SetPlayerFacingAngle(playerid,0.6967);
		SetPlayerCameraPos(playerid,305.5800,-1773.9879,4.5850,0.6966);
		SetPlayerCameraLookAt(playerid,305.2606,-1770.2201,4.5381,0.6967);
		ApplyAnimation(playerid, "POLICE", "Door_Kick", 4.1, 0, 1, 1, 1, 1, 1);

	   }

	   if(classid == 46)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,305.2606,-1770.2201,4.5381,0.6967);
		SetPlayerFacingAngle(playerid,0.6967);
		SetPlayerCameraPos(playerid,305.5800,-1773.9879,4.5850,0.6966);
		SetPlayerCameraLookAt(playerid,305.2606,-1770.2201,4.5381,0.6967);
		ApplyAnimation(playerid, "POLICE", "Door_Kick", 4.1, 0, 1, 1, 1, 1, 1);

	   }
	   if(classid == 33)
	 {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2101.8994,-1648.8588,13.3840,273.2972);
		SetPlayerFacingAngle(playerid,237.2972);
		SetPlayerCameraPos(playerid,2098.2332,-1649.7500,13.6022,283.6374);
		SetPlayerCameraLookAt(playerid,2101.8994,-1648.8588,13.3840,273.2972);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 0)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 1)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 2)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 11)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 12)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 13)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 37)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 44)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,2508.8684,-1669.8671,14.7683,266.1870);
		SetPlayerCameraLookAt(playerid,2513.1375,-1671.3628,13.5127,74.1493);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 4)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2763.5979,-2012.0525,13.5547,90.5025);
		SetPlayerFacingAngle(playerid,90.5025);
		SetPlayerCameraPos(playerid,2765.9097,-2011.8884,13.5620,93.0092);
		SetPlayerCameraLookAt(playerid,2763.5979,-2012.0525,13.5547,90.5025);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 5)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2763.5979,-2012.0525,13.5547,90.5025);
		SetPlayerFacingAngle(playerid,90.5025);
		SetPlayerCameraPos(playerid,2765.9097,-2011.8884,13.5620,93.0092);
		SetPlayerCameraLookAt(playerid,2763.5979,-2012.0525,13.5547,90.5025);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);
	}

		if(classid == 6)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2763.5979,-2012.0525,13.5547,90.5025);
		SetPlayerFacingAngle(playerid,90.5025);
		SetPlayerCameraPos(playerid,2765.9097,-2011.8884,13.5620,93.0092);
		SetPlayerCameraLookAt(playerid,2763.5979,-2012.0525,13.5547,90.5025);
		ApplyAnimation(playerid, "GRAFFITI", "spraycan_fire", 4.1, 0, 1, 1, 1, 1, 1);
	}

	if(classid == 26)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
        ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}

	if(classid == 27)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}

	if(classid == 28)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 23)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1871.3867,-2020.6656,13.5469,269.9995);
		SetPlayerFacingAngle(playerid,269,9995);
		SetPlayerCameraPos(playerid,1874.2583,-2020.5739,13.5469,88.4328);
		SetPlayerCameraLookAt(playerid,1871.3867,-2020.6656,13.5469,269.9995);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 24)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1871.3867,-2020.6656,13.5469,269.9995);
		SetPlayerFacingAngle(playerid,269,9995);
		SetPlayerCameraPos(playerid,1874.2583,-2020.5739,13.5469,88.4328);
		SetPlayerCameraLookAt(playerid,1871.3867,-2020.6656,13.5469,269.9995);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 25)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1871.3867,-2020.6656,13.5469,269.9995);
		SetPlayerFacingAngle(playerid,269,9995);
		SetPlayerCameraPos(playerid,1874.2583,-2020.5739,13.5469,88.4328);
		SetPlayerCameraLookAt(playerid,1871.3867,-2020.6656,13.5469,269.9995);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 47)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,687.0648,-1275.7979,19.0340,90.6508);
		SetPlayerFacingAngle(playerid,269,9995);
		SetPlayerCameraPos(playerid,679.0361,-1275.8167,19.0568,268.3124);
		SetPlayerCameraLookAt(playerid,679.0361,-1275.8167,19.0568,268.3124);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 7)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1540.1969,-1675.9867,13.5501,89.3516);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,1534.2244,-1675.9977,13.3828,270.7499);
		SetPlayerCameraLookAt(playerid,1534.2244,-1675.9977,13.3828,270.7499);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 8)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1540.1969,-1675.9867,13.5501,89.3516);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,1534.2244,-1675.9977,13.3828,270.7499);
		SetPlayerCameraLookAt(playerid,1534.2244,-1675.9977,13.3828,270.7499);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 45)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,1456.6705,-1496.7351,13.5469,90.5659);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,1452.7393,-1496.7740,13.5469,90.5659);
		SetPlayerCameraLookAt(playerid,1452.7393,-1496.7740,13.5469,90.5659);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 48)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,687.0648,-1275.7979,19.0340,90.6508);
		SetPlayerFacingAngle(playerid,74.1493);
		SetPlayerCameraPos(playerid,679.0361,-1275.8167,19.0568,268.3124);
		SetPlayerCameraLookAt(playerid,679.0361,-1275.8167,19.0568,268.3124);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 49)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,687.0648,-1275.7979,19.0340,90.6508);
		SetPlayerFacingAngle(playerid,85.1476);
		SetPlayerCameraPos(playerid,679.0361,-1275.8167,19.0568,268.3124);
		SetPlayerCameraLookAt(playerid,679.0361,-1275.8167,19.0568,268.3124);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 50)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,687.0648,-1275.7979,19.0340,90.6508);
		SetPlayerFacingAngle(playerid,85.1476);
		SetPlayerCameraPos(playerid,679.0361,-1275.8167,19.0568,268.3124);
		SetPlayerCameraLookAt(playerid,679.0361,-1275.8167,19.0568,268.3124);
		ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 51)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,972.3027,-1109.0645,23.8751,85.1476);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,969.1415,-1109.3302,23.8654,267.1960);
  SetPlayerCameraLookAt(playerid,972.3027,-1109.0645,23.8751,85.1476);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
  if(classid == 52)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,972.3027,-1109.0645,23.8751,85.1476);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,969.1415,-1109.3302,23.8654,267.1960);
  SetPlayerCameraLookAt(playerid,972.3027,-1109.0645,23.8751,85.1476);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 16)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,2191.7209,-2291.0195,18.5155,88.1453);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  SetPlayerCameraLookAt(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 17)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,2191.7209,-2291.0195,18.5155,88.1453);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  SetPlayerCameraLookAt(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 18)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,2191.7209,-2291.0195,18.5155,88.1453);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  SetPlayerCameraLookAt(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 19)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,2191.7209,-2291.0195,18.5155,88.1453);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  SetPlayerCameraLookAt(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 20)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,2191.7209,-2291.0195,18.5155,88.1453);
  SetPlayerFacingAngle(playerid,85.1476);
  SetPlayerCameraPos(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  SetPlayerCameraLookAt(playerid,2185.8430,-2290.7075,18.5155,264.2170);
  ApplyAnimation(playerid, "BASEBALL", "Bat_IDLE", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 21)
	{
  SetPlayerInterior(playerid,0);
  SetPlayerPos(playerid,1871.3867,-2020.6656,13.5469,269.9995);
  SetPlayerFacingAngle(playerid,269,9995);
  SetPlayerCameraPos(playerid,1874.2583,-2020.5739,13.5469,88.4328);
  SetPlayerCameraLookAt(playerid,1871.3867,-2020.6656,13.5469,269.9995);
  ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 22)
	{
 SetPlayerInterior(playerid,0);
 SetPlayerPos(playerid,1871.3867,-2020.6656,13.5469,269.9995);
 SetPlayerFacingAngle(playerid,269,9995);
 SetPlayerCameraPos(playerid,1874.2583,-2020.5739,13.5469,88.4328);
 SetPlayerCameraLookAt(playerid,1871.3867,-2020.6656,13.5469,269.9995);
 ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 23)
	{
 SetPlayerInterior(playerid,0);
 SetPlayerPos(playerid,1871.3867,-2020.6656,13.5469,269.9995);
 SetPlayerFacingAngle(playerid,269,9995);
 SetPlayerCameraPos(playerid,1874.2583,-2020.5739,13.5469,88.4328);
 SetPlayerCameraLookAt(playerid,1871.3867,-2020.6656,13.5469,269.9995);
 ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 24)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
        ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 25)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
        ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 26)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
        ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 27)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}

	if(classid == 28)
	{
	    SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		SetPlayerFacingAngle(playerid,82.3273);
		SetPlayerCameraPos(playerid,2456.4712,-1356.6945,24.0000,268.5941);
		SetPlayerCameraLookAt(playerid,2460.0391,-1356.7123,24.0000,82.3273);
		ApplyAnimation(playerid, "GANGS", "smkcig_prtl_F", 4.1, 0, 1, 1, 1, 1, 1);
	}
	if(classid == 13)
    {
        SetPlayerInterior(playerid,0);
		SetPlayerPos(playerid, 936.3463,-1103.2695,24.3137,267.6657);
		SetPlayerFacingAngle(playerid,267.6657);
		SetPlayerCameraPos(playerid, 948.5059,-1103.6152,24.1295,87.6657);
		SetPlayerCameraLookAt(playerid, 936.3463,-1103.2695,24.3137,267.6657);
        ApplyAnimation(playerid, "PED", "WALK_gang1", 4.1, 0, 1, 1, 1, 1, 1);
	    }
     return 1;
 }
Reply
#7

Anyone?
Reply
#8

Again, extra brace. Be careful and indent your code properly.
pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
   
    SetPlayerInterior(playerid,0);
    SetPlayerPos(playerid,2480.8901,-1536.6035,24.1829,268.8467);
    SetPlayerFacingAngle(playerid,268.8467);
    SetPlayerCameraPos(playerid,2484.2258,-1536.7886,24.0013,88.8468);
    SetPlayerCameraLookAt(playerid,2480.8901,-1536.6035,24.1829,268.8467);
    ApplyAnimation(playerid, "PED", "phone_talk", 4.1, 0, 1, 1, 1, 1, 1);
    if(classid == 13)
    {
        SetPlayerInterior(playerid,0);
        SetPlayerPos(playerid, 936.3463,-1103.2695,24.3137,267.6657);
        SetPlayerFacingAngle(playerid,267.6657);
        SetPlayerCameraPos(playerid, 948.5059,-1103.6152,24.1295,87.6657);
        SetPlayerCameraLookAt(playerid, 936.3463,-1103.2695,24.3137,267.6657);
        ApplyAnimation(playerid, "PED", "WALK_gang1", 4.1, 0, 1, 1, 1, 1, 1);
       
    }
   
    if(classid == 14)
    {
        SetPlayerInterior(playerid,0);
        SetPlayerPos(playerid, 936.3463,-1103.2695,24.3137,267.6657);
        SetPlayerFacingAngle(playerid,267.6657);
        SetPlayerCameraPos(playerid, 948.5059,-1103.6152,24.1295,87.6657);
        SetPlayerCameraLookAt(playerid, 936.3463,-1103.2695,24.3137,267.6657);
        ApplyAnimation(playerid, "PED", "WALK_gang1", 4.1, 0, 1, 1, 1, 1, 1);
       
    }
    // rest of code
Reply
#9

This may be useful for people having issues with brackets.
https://sampforum.blast.hk/showthread.php?tid=454423
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)