Scripting Helpppp
#1

Hi , my friend made me a gamemode , and he gave me the .amx file , I wanted to make a change so i asked him to give me the .pwn file , but he has his Virtual Private Machine ( VPs ) so i used DeAMXX to decompile the .amx file
and i made the changes , but when i try to compile it i get theese errors :

(60) : error 014: invalid statement; not in switch
(60) : error 029: invalid expression, assumed zero
(60 -- 61) : warning 215: expression has no effect
(61) : error 001: expected token: ";", but found "case"
(61) : fatal error 107: too many error messages on one line

Here is the script : http://pastebin.com/jPJsMJdL

Please help me
Reply
#2

Don't expect to get the original pwn file back exactly of how it was.

pawn Код:
switch(classid) {
                case 0:
                case 3:
                case 2:
                case 1:
            GameTextForPlayer(playerid, "~b~Bodyguard", 999999, 6);
                        glob0[playerid] = 1;
                case 6:
                case 5:
                case 4:
                        GameTextForPlayer(playerid, "~r~Terrorist", 999999, 6);
                        glob0[playerid] = 2;
                case 12:
                case 13:
                case 14:
                case 11:
                case 10:
                case 9:
                case 8:
                        GameTextForPlayer(playerid, "~b~PoliceOfficer", 999999, 6);
                        glob0[playerid] = 3;
                case 17:
                case 18:
                case 16:
                case 15:
                case 19:
                        GameTextForPlayer(playerid, "~r~Psycho", 999999, 6);
                        glob0[playerid] = 4;
        }
It seems that some cases are not used at all so:
pawn Код:
switch(classid)
{
    case 1:
    {
        GameTextForPlayer(playerid, "~b~Bodyguard", 999999, 6);
        glob0[playerid] = 1;
    }
    case 4:
    {
        GameTextForPlayer(playerid, "~r~Terrorist", 999999, 6);
        glob0[playerid] = 2;
    }
    case 8:
    {
        GameTextForPlayer(playerid, "~b~PoliceOfficer", 999999, 6);
        glob0[playerid] = 3;
    }
    case 19:
    {
        GameTextForPlayer(playerid, "~r~Psycho", 999999, 6);
        glob0[playerid] = 4;
    }
}
Reply
#3

Quote:
Originally Posted by Besar
Посмотреть сообщение
but he has his Virtual Private Machine ( VPs ) so i used DeAMXX to decompile the .amx file
Smells fishy.
Reply
#4

I pasted the code you gave me , thank you , but now i get again erros :
(58 ) : warning 217: loose indentation
(81 ) : warning 217: loose indentation
(88 ) : error 017: undefined symbol "glob11A8"
(88 ) : warning 215: expression has no effect
(88 ) : error 001: expected token: ";", but found "]"
(88 ) : error 029: invalid expression, assumed zero
(88 ) : fatal error 107: too many error messages on one line
Reply
#5

Can anybody help me please
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)