[Ajuda] Como por fs no gm !
#1

olha tenho um sistema de neon ! eu troquei o OnFilterScriptInit() por OnGameModeInit() num troquei o OnFilterScriptExit() pq ele nгo tem no fs .

segue os erros q aparece:

pawn Код:
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : warning: 225: unreachable code
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 029: invalid expression, assumed zero
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 001: expected token: ";", but found "{"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : warning: 225: unreachable code
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 029: invalid expression, assumed zero
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "cmdtext"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 029: invalid expression, assumed zero
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 029: invalid expression, assumed zero
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error fatal: 107: too many error messages on one line
SE POSSIVEL QUERIA Q ME ENSINASEM A COMO fs POR NO GM :/ VI VARIOS TUTORIAIS MAS MESMO ASSIM CONTINUA
DANDO ERRO

coloquei esse fs assim no gm olha:

pawn Код:
#define FILTERSCRIPT
#define COLOR_WHITE 0xFFFFFFAA
#include <a_samp>
#define NEON 1337 // Dialogid
#pragma tabsize 0
#if defined FILTERSCRIPT

public OnGameModeInit()
{
    print("\n--------------------------------------");
    print(" Neon System By AlexzzPro");
    print("--------------------------------------\n");
    return 1;
}

#endif
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/neon", cmdtext, true, 10) == 0)
    {
        if(IsPlayerInAnyVehicle(playerid))
         {
            if(!IsPlayerInRangeOfPoint(playerid, 6.0, 2496.1047,-1459.8186,24.0170)) return SendClientMessage(playerid, -1, "Vocк nгo estб na garagem de neon");
            if([playerid][pVIP] < 1) return SendClientMessage(playerid, -1, "Vocк nгo й VIP ou socido !");
            if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
            {
                SendClientMessage(playerid, COLOR_WHITE, "      Vocк Nгo estб em um veiculo");
                return 1;
            }
            ShowPlayerDialog(playerid, NEON, DIALOG_STYLE_LIST, "Escolha sua cor","Azul\nVerde\nAmarelo\nBranco\nRosa\nRetirar Neon","Adicionar","Fechar");
        }
        else
        {
            SendClientMessage(playerid, COLOR_WHITE, " Vocк Nгo estб em um veiculo");
        }
        return 1;
    }
    return 0;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
    if(dialogid == NEON)
    {
        if(response)
        {
            if(listitem == 0)
            {
                SetPVarInt(playerid, "neon", 1);
                SetPVarInt(playerid, "blue", CreateObject(18648,0,0,0,0,0,0));
                SetPVarInt(playerid, "blue1", CreateObject(18648,0,0,0,0,0,0));
                AttachObjectToVehicle(GetPVarInt(playerid, "blue"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                AttachObjectToVehicle(GetPVarInt(playerid, "blue1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~b~ Azul ~w~Neon Foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 1)
            {
                   SetPVarInt(playerid, "neon", 1);
                   SetPVarInt(playerid, "green", CreateObject(18649,0,0,0,0,0,0));
                   SetPVarInt(playerid, "green1", CreateObject(18649,0,0,0,0,0,0));
                   AttachObjectToVehicle(GetPVarInt(playerid, "green"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                  AttachObjectToVehicle(GetPVarInt(playerid, "green1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                  GameTextForPlayer(playerid, "~g~Verde ~w~Neon Foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 2)
            {
                SetPVarInt(playerid, "neon", 1);
                   SetPVarInt(playerid, "yellow", CreateObject(18650,0,0,0,0,0,0));
                  SetPVarInt(playerid, "yellow1", CreateObject(18650,0,0,0,0,0,0));
                AttachObjectToVehicle(GetPVarInt(playerid, "yellow"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                 AttachObjectToVehicle(GetPVarInt(playerid, "yellow1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~y~Amarelo~w~ Neon foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 3)
            {
                   SetPVarInt(playerid, "neon", 1);
                   SetPVarInt(playerid, "white", CreateObject(18652,0,0,0,0,0,0));
                   SetPVarInt(playerid, "white1", CreateObject(18652,0,0,0,0,0,0));
                   AttachObjectToVehicle(GetPVarInt(playerid, "white"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                  AttachObjectToVehicle(GetPVarInt(playerid, "white1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~w~Branco~w~ Neon foi colado em seu veiculo",3500,5);
            }
            if(listitem == 4)
            {
                   SetPVarInt(playerid, "neon", 1);
                 SetPVarInt(playerid, "pink", CreateObject(18651,0,0,0,0,0,0));
                SetPVarInt(playerid, "pink1", CreateObject(18651,0,0,0,0,0,0));
                  AttachObjectToVehicle(GetPVarInt(playerid, "pink"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                AttachObjectToVehicle(GetPVarInt(playerid, "pink1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
                GameTextForPlayer(playerid, "~p~Rosa~w~ Neon foi colocado em seu veiculo",3500,5);
            }
            if(listitem == 5)
            {
                   DestroyObject(GetPVarInt(playerid, "blue"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "blue1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "green"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "green1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "yellow"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "yellow1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "white"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "white1"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "pink"));
                DeletePVar(playerid, "neon");
                DestroyObject(GetPVarInt(playerid, "pink1"));
                DeletePVar(playerid, "neon");
                GameTextForPlayer(playerid, "~g~Neon foi deletado de seu veiculo",3500,5);
            }
        }
     }
    return 1;
}

Bom quero q tenha a variavel vip junto pq quero q sу vips poзгo colocar neon no carro!
sei q variavel sу funfa no gm ! esse fs passei pro gm e quando vo copila da 26 erros ! pf me ajudem !
Reply
#2

topo do gm "em baixo das includes"

pawn Код:
#define COLOR_WHITE 0xFFFFFFAA
#define NEON 1337
#pragma tabsize 0
coloque isso em baixo de um comando seu normal

pawn Код:
if (strcmp("/neon", cmdtext, true, 10) == 0)    
{        
    if(IsPlayerInAnyVehicle(playerid))        
    {            
        if(!IsPlayerInRangeOfPoint(playerid, 6.0, 2496.1047,-1459.8186,24.0170)) return SendClientMessage(playerid, -1, "Vocк nгo estб na garagem de neon");            
        if([playerid][pVIP] < 1) return SendClientMessage(playerid, -1, "Vocк nгo й VIP ou socido !");            
        if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)            
        {                
            SendClientMessage(playerid, COLOR_WHITE, "Vocк Nгo estб em um veiculo");                
            return 1;            
        }            
        ShowPlayerDialog(playerid, NEON, DIALOG_STYLE_LIST, "Escolha sua cor","Azul\nVerde\nAmarelo\nBranco\nRosa\nRetirar Neon","Adicionar","Fechar");        
    }      
    else        
    {            
        SendClientMessage(playerid, COLOR_WHITE, "Vocк Nгo estб em um veiculo");        
    }        
    return 1;    
}
Dentro da Callback OnDialogResponse

pawn Код:
if(dialogid == NEON)
{
    if(response)
    {
        if(listitem == 0)
        {
            SetPVarInt(playerid, "neon", 1);
            SetPVarInt(playerid, "blue", CreateObject(18648,0,0,0,0,0,0));
            SetPVarInt(playerid, "blue1", CreateObject(18648,0,0,0,0,0,0));
            AttachObjectToVehicle(GetPVarInt(playerid, "blue"),
            GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            AttachObjectToVehicle(GetPVarInt(playerid, "blue1"),
            GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            GameTextForPlayer(playerid, "~b~ Azul ~w~Neon Foi colocado em seu veiculo",3500,5);
        }
        if(listitem == 1)
        {
            SetPVarInt(playerid, "neon", 1);
            SetPVarInt(playerid, "green", CreateObject(18649,0,0,0,0,0,0));
            SetPVarInt(playerid, "green1", CreateObject(18649,0,0,0,0,0,0));
            AttachObjectToVehicle(GetPVarInt(playerid, "green"),
            GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            AttachObjectToVehicle(GetPVarInt(playerid, "green1"),
            GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            GameTextForPlayer(playerid, "~g~Verde ~w~Neon Foi colocado em seu veiculo",3500,5);
        }
        if(listitem == 2)
        {
            SetPVarInt(playerid, "neon", 1);
            SetPVarInt(playerid, "yellow", CreateObject(18650,0,0,0,0,0,0));
            SetPVarInt(playerid, "yellow1", CreateObject(18650,0,0,0,0,0,0));
            AttachObjectToVehicle(GetPVarInt(playerid, "yellow"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            AttachObjectToVehicle(GetPVarInt(playerid, "yellow1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            GameTextForPlayer(playerid, "~y~Amarelo~w~ Neon foi colocado em seu veiculo",3500,5);
        }
        if(listitem == 3)
        {
            SetPVarInt(playerid, "neon", 1);
            SetPVarInt(playerid, "white", CreateObject(18652,0,0,0,0,0,0));
            SetPVarInt(playerid, "white1", CreateObject(18652,0,0,0,0,0,0));
            AttachObjectToVehicle(GetPVarInt(playerid, "white"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            AttachObjectToVehicle(GetPVarInt(playerid, "white1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            GameTextForPlayer(playerid, "~w~Branco~w~ Neon foi colado em seu veiculo",3500,5);
        }
        if(listitem == 4)
        {
            SetPVarInt(playerid, "neon", 1);
            SetPVarInt(playerid, "pink", CreateObject(18651,0,0,0,0,0,0));
            SetPVarInt(playerid, "pink1", CreateObject(18651,0,0,0,0,0,0));
            AttachObjectToVehicle(GetPVarInt(playerid, "pink"), GetPlayerVehicleID(playerid), -0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            AttachObjectToVehicle(GetPVarInt(playerid, "pink1"), GetPlayerVehicleID(playerid), 0.8, 0.0, -0.70, 0.0, 0.0, 0.0);
            GameTextForPlayer(playerid, "~p~Rosa~w~ Neon foi colocado em seu veiculo",3500,5);
        }
        if(listitem == 5)
        {
            DestroyObject(GetPVarInt(playerid, "blue"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "blue1"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "green"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "green1"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "yellow"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "yellow1"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "white"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "white1"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "pink"));
            DeletePVar(playerid, "neon");
            DestroyObject(GetPVarInt(playerid, "pink1"));
            DeletePVar(playerid, "neon");
            GameTextForPlayer(playerid, "~g~Neon foi deletado de seu veiculo",3500,5);
        }
    }
}
Espero que isso te ajude na hora de tentar passar o fs pro gm
Reply
#3

pawn Код:
if([playerid][pVIP] < 1) // Isso gerara erros com certeza...
Nгo vai adiantar passar para FS... Nгo da para passar a variбvel de VIP sem criar um sistema de VIP no proprio FS...

pawn Код:
#pragma tabsize  0    // nгo recomendo usar isto, pois й como colocar sujeira debaixo do tapete...
pawn Код:
#if defined FILTERSCRIPT // Tambem nгo precisa usar isso, isso й sу para verificar se foi definido FS | ao retirar isso, tire o #endif do final do FS
Reply
#4

penso que se ele pos essa linha ele deve ter o sistema de vip .-.

os erros que eu vi foi "playerid"
ele pode ter colocado o code em OngameModInt que nao tem (playerid) como as outras callbacks

Код:
Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "cmdtext"C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(48127) : error: 017: undefined symbol "playerid"
Reply
#5

Vocк coloco isso no GM:
pawn Код:
#define FILTERSCRIPT // tu coloco isso no GM? Se tiver colocado tira!
#define COLOR_WHITE 0xFFFFFFAA
#include <a_samp>
#define NEON 1337 // Dialogid
#pragma tabsize 0
#if defined FILTERSCRIPT // tu coloco isso no GM? O.O Se tiver colocado tira
Reply
#6

The_fallen

fiz oq vc falo pra fazer e deu os seguintes erros:

pawn Код:
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(16552) : error: 029: invalid expression, assumed zero
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(16552) : warning: 215: expression has no effect
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(16552) : error: 001: expected token: ";", but found "]"
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(16552) : error: 029: invalid expression, assumed zero
C:\Documents and Settings\Christian temp\Desktop\Gamemods\BHL\gamemodes\BHL.pwn(16552) : error fatal: 107: too many error messages on one line
Reply
#7

poste a linha 16552
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)