SA-MP Forums Archive
minigun command for admins dont work - 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: minigun command for admins dont work (/showthread.php?tid=398444)



minigun command for admins dont work - Mustafa6155 - 09.12.2012

pawn Код:
CMD:minigun(playerid, params[])
{
    if (PlayerInfo[playerid][pAdmin] >= 3) // this is the error line
    {
        GivePlayerWeapon(playerid, 38, 10000);
        SendClientMessage(playerid, -1,"Je hebt een Minigun gespawnt!");
        }
        else
        {
        SendClientMessage(playerid, -1,"{F81414}Je bent geen Admin!");
        return 1;
}
Код:
C:\Users\Mustafa\Desktop\SAmp SRV\ForYou\gamemodes\TDMNIEUW.pwn(449) : error 030: compound statement not closed at the end of file (started at line 439)
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.



Re: minigun command for admins dont work - doreto - 09.12.2012

pawn Код:
CMD:minigun(playerid, params[])
{
    if (PlayerInfo[playerid][pAdmin] >= 3) // this is the error line
    {
        GivePlayerWeapon(playerid, 38, 10000);
        SendClientMessage(playerid, -1,"Je hebt een Minigun gespawnt!");
    }
    else
    {
        SendClientMessage(playerid, -1,"{F81414}Je bent geen Admin!");
    }// you forgot to close second else bracket {
    return 1;
}



Re: minigun command for admins dont work - AndreT - 09.12.2012

Key to solving the issue would be using proper indentation. ****** it or use your brain to see where you're missing a bracket.

Good luck breda.


Re: minigun command for admins dont work - Mustafa6155 - 09.12.2012

Thank you. Sometimes you can forgot stupid thinks like what i did