SA-MP Forums Archive
again problem with script - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: again problem with script (/showthread.php?tid=381717)



again problem with script - fireboy - 30.09.2012

hello can somebody help me fix this:
D:\Documents and Settings\abc\Desktop\Serveris\Conex SA-MP\filterscripts\poke.pwn(394) : error 030: compound statement not closed at the end of file (started at line 372)

script:
//================================================== ================================================== ===============//
if(GetPlayerScore(playerid) >= 2)
{
if(!strcmp(cmdtext, "/flipcar", true, 4))
{
if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, -1, "KĻŪDA: Tev jābūt maљīnā!");
{
new currentveh;
new Float:angle;
currentveh = GetPlayerVehicleID(playerid);
GetVehicleZAngle(currentveh, angle);
SetVehicleZAngle(currentveh, angle);
SendClientMessage(playerid, 0xFFFFFFFF, "Tava maљīna veiksmīgi apgriezta.");
return 1;
}

thank you.


Re: again problem with script - Gangster-rocks - 30.09.2012

PLEASE USE [pawn]code here with out the dot[/.pawn]
please so i can understand you


Re: again problem with script - doreto - 30.09.2012

You forgot to close {

pawn Код:
if(GetPlayerScore(playerid) >= 2)
{
    if(!strcmp(cmdtext, "/flipcar", true, 4))
    {
        if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, -1, "KL,U-DA: Tev ja-bu-t mas(i-na-!");
        {
            new currentveh;
            new Float:angle;
            currentveh = GetPlayerVehicleID(playerid);
            GetVehicleZAngle(currentveh, angle);
            SetVehicleZAngle(currentveh, angle);
            SendClientMessage(playerid, 0xFFFFFFFF, "Tava mas(i-na veiksmi-gi apgriezta.");
        }
    }
    return 1;
}



Re: again problem with script - fireboy - 30.09.2012

okay this fixed it but now i got this problem:
D:\Documents and Settings\abc\Desktop\Serveris\Conex SA-MP\filterscripts\poke.pwn(39 : error 030: compound statement not closed at the end of file (started at line 86)

in this part:
pawn Код:
if (strcmp("/buylevel", cmdtext, true) == 0)
      {
            //1.LVL
//1lvl
if(GetPlayerScore(playerid)==0)
            {
            if(GetPlayerMoney(playerid) < 1000000)//
                {
                SendClientMessage(playerid, 0xE6000033, "Jums nav pietiekami daudz naudas, lai nopirktu 1. līmeni!");
                }
            else
                {
                SetPlayerScore(playerid, 1);
                GivePlayerMoney(playerid, -1000000);//
                SendClientMessage(playerid, 0x33AA33AA, "Apsveicam! Jūs iegādājāties 1. Līmeni. Tagad jums ir iespēja lietot /repair, lai salabotu maљīnu nekur nebraucot!");
                }
            return 1;
   }



Re: again problem with script - doreto - 30.09.2012

Damm it dude you you open the braked { you later need to close it } next time i wont help you check your code correct

pawn Код:
if (strcmp("/buylevel", cmdtext, true) == 0)
{
    if(GetPlayerScore(playerid)==0)
    {
        if(GetPlayerMoney(playerid) < 1000000)//
        {
            SendClientMessage(playerid, 0xE6000033, "Jums nav pietiekami daudz naudas, lai nopirktu 1. li-meni!");
        }
    } // you miss it here
    else
    {
        SetPlayerScore(playerid, 1);
        GivePlayerMoney(playerid, -1000000);//
        SendClientMessage(playerid, 0x33AA33AA, "Apsveicam! Ju-s iega-da-ja-ties 1. Li-meni. Tagad jums ir iespe-ja lietot /repair, lai salabotu mas(i-nu nekur nebraucot!");
    }
    return 1;
}



Re: again problem with script - fireboy - 30.09.2012

oh but i have still the problem. my pawno crashes when i copy paste your reedited code. :/