Beiträge von friday96

    Also erstma is das ein Filterscript oder dein richtiges "GameMode" Script ?! :D ok ich glaube aber dass es ein Filterscript ist ^^ also, du musst die Sachen in dein GameMode einfügen zumindestens so teilweise ... schau dir ma Tutorial an aba das nur schon ma als kleinen Hinweis ;)


    mfg:[SGS]Krypton :thumbup:


    Joa ist ein Filterscript.^^
    Was muss ich genau in den Gamemod machen.

    Ich wollt einen Bot in Mein Script machen nur leider kommen immer wieder 3 Errors und 1 Warning.
    Hier der Code:
    #include <a_samp>
    #include <a_npc>



    #define RECORDING "train_lv"


    new train_train_lv;


    public OnGameModeInit()
    {
    ConnectNPC("train_lv","train_lv");
    train_train_lv = CreateVehicle(538, 1000.0,1000.0, 1000.0, 0.0, 10, 1, -1);
    return 1;
    }


    public OnGameModeExit()
    {
    return 1;
    }



    new botname[MAX_PLAYER_NAME];


    public OnPlayerConnect(playerid)
    {
    if(IsPlayerNPC(playerid))
    GetPlayerName(playerid, botname, sizeof(botname));
    if(!strcmp(botname, "train_lv", true))


    return 1;
    }


    public OnPlayerDisconnect(playerid, reason)
    {
    return 1;
    }


    public OnPlayerSpawn(playerid)
    {
    if(IsPlayerNPC(playerid))
    {
    GetPlayerName(playerid, botname, sizeof(botname));
    if(!strcmp(botname, "train_lv", true))
    {
    PutPlayerInVehicle(playerid, train_train_lv, 0);
    }
    }
    return 1;
    }


    public OnRecordingPlaybackEnd()
    {
    StartRecordingPlayback(1, RECORDING);
    }


    public OnNPCEnterVehicle(vehicleid, seatid)
    {
    StartRecordingPlayback(1, RECORDING);
    }


    public OnNPCExitVehicle()
    {
    StopRecordingPlayback();
    }


    public OnPlayerDeath(playerid, killerid, reason)
    {
    return 1;
    }


    public OnVehicleSpawn(vehicleid)
    {
    return 1;
    }


    public OnVehicleDeath(vehicleid, killerid)
    {
    return 1;
    }


    public OnPlayerText(playerid, text[])
    {
    return 1;
    }


    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("", cmdtext, true, 10) == 0)
    {
    return 1;
    }
    return 0;
    }


    public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
    {
    return 1;
    }


    public OnPlayerExitVehicle(playerid, vehicleid)
    {
    return 1;
    }


    public OnPlayerStateChange(playerid, newstate, oldstate)
    {
    return 1;
    }


    public OnPlayerEnterCheckpoint(playerid)
    {
    return 1;
    }


    public OnPlayerLeaveCheckpoint(playerid)
    {
    return 1;
    }


    public OnPlayerEnterRaceCheckpoint(playerid)
    {
    return 1;
    }


    public OnPlayerLeaveRaceCheckpoint(playerid)
    {
    return 1;
    }


    public OnRconCommand(cmd[])
    {
    return 1;
    }


    public OnPlayerRequestSpawn(playerid)
    {
    return 1;
    }


    public OnObjectMoved(objectid)
    {
    return 1;
    }


    public OnPlayerObjectMoved(playerid, objectid)
    {
    return 1;
    }


    public OnPlayerPickUpPickup(playerid, pickupid)
    {
    return 1;
    }


    public OnVehicleMod(playerid, vehicleid, componentid)
    {
    return 1;
    }


    public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
    {
    return 1;
    }


    public OnVehicleRespray(playerid, vehicleid, color1, color2)
    {
    return 1;
    }


    public OnPlayerSelectedMenuRow(playerid, row)
    {
    return 1;
    }


    public OnPlayerExitedMenu(playerid)
    {
    return 1;
    }


    public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
    {
    return 1;
    }


    public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
    {
    return 1;
    }


    public OnRconLoginAttempt(ip[], password[], success)
    {
    return 1;
    }


    public OnPlayerUpdate(playerid)
    {
    return 1;
    }


    public OnPlayerStreamIn(playerid, forplayerid)
    {
    return 1;
    }


    public OnPlayerStreamOut(playerid, forplayerid)
    {
    return 1;
    }


    public OnVehicleStreamIn(vehicleid, forplayerid)
    {
    return 1;
    }


    public OnVehicleStreamOut(vehicleid, forplayerid)
    {
    return 1;
    }


    public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
    {
    return 1;
    }


    public OnPlayerClickPlayer(playerid, clickedplayerid, source)
    {
    return 1;
    }



    Und hier die Errors und Warnigs:
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(31) : warning 209: function "OnPlayerConnect" should return a value
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(53) : error 017: undefined symbol "StartRecordingPlayback"
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(58) : error 017: undefined symbol "StartRecordingPlayback"
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(63) : error 017: undefined symbol "StopRecordingPlayback"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    3 Errors.



    Und da weiß ich nicht mehr weiter. ;(
    Brauche eure Hilfe ;) .

    mach einfach die forwards von der a_npc datei in die a_samp datei.


    //info a_npc und a_samp beißen sich deswegen geht das nicht!


    also einfach notepad oder editor nehmen a_npc öffnen und die 3 forwards in a_samp einfügen ganz einfach^^
    //edit ach ja und die natives natürlich auch von StartRecordingPlayback usw



    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(31) : warning 209: function "OnPlayerConnect" should return a value
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(53) : error 017: undefined symbol "StartRecordingPlayback"
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(58) : error 017: undefined symbol "StartRecordingPlayback"
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(63) : error 017: undefined symbol "StopRecordingPlayback"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    3 Errors.



    Und jetzt?

    Was ist daran Falsch?
    #include <a_samp>


    #include "a_npc"


    #define RECORDING "train_lv"


    new train_train_lv;


    public OnGameModeInit()
    {
    ConnectNPC("train_lv","train_lv");
    train_train_lv = CreateVehicle(538, 1000.0,1000.0, 1000.0, 0.0, 10, 1, -1);
    return 1;
    }


    public OnGameModeExit()
    {
    return 1;
    }



    new botname[MAX_PLAYER_NAME];


    public OnPlayerConnect(playerid)
    {
    if(IsPlayerNPC(playerid))
    GetPlayerName(playerid, botname, sizeof(botname));
    if(!strcmp(botname, "train_lv", true))


    return 1;
    }


    public OnPlayerDisconnect(playerid, reason)
    {
    return 1;
    }


    public OnPlayerSpawn(playerid)
    {
    if(IsPlayerNPC(playerid))
    {
    GetPlayerName(playerid, botname, sizeof(botname));
    if(!strcmp(botname, "train_lv", true))
    {
    PutPlayerInVehicle(playerid, train_train_lv, 0);
    }
    }
    return 1;
    }


    public OnRecordingPlaybackEnd()
    {
    StartRecordingPlayback(1, RECORDING);
    }


    public OnNPCEnterVehicle(vehicleid, seatid)
    {
    StartRecordingPlayback(1, RECORDING);
    }


    public OnNPCExitVehicle()
    {
    StopRecordingPlayback();
    }


    public OnPlayerDeath(playerid, killerid, reason)
    {
    return 1;
    }


    public OnVehicleSpawn(vehicleid)
    {
    return 1;
    }


    public OnVehicleDeath(vehicleid, killerid)
    {
    return 1;
    }


    public OnPlayerText(playerid, text[])
    {
    return 1;
    }


    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if (strcmp("", cmdtext, true, 10) == 0)
    {
    return 1;
    }
    return 0;
    }


    public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
    {
    return 1;
    }


    public OnPlayerExitVehicle(playerid, vehicleid)
    {
    return 1;
    }


    public OnPlayerStateChange(playerid, newstate, oldstate)
    {
    return 1;
    }


    public OnPlayerEnterCheckpoint(playerid)
    {
    return 1;
    }


    public OnPlayerLeaveCheckpoint(playerid)
    {
    return 1;
    }


    public OnPlayerEnterRaceCheckpoint(playerid)
    {
    return 1;
    }


    public OnPlayerLeaveRaceCheckpoint(playerid)
    {
    return 1;
    }


    public OnRconCommand(cmd[])
    {
    return 1;
    }


    public OnPlayerRequestSpawn(playerid)
    {
    return 1;
    }


    public OnObjectMoved(objectid)
    {
    return 1;
    }


    public OnPlayerObjectMoved(playerid, objectid)
    {
    return 1;
    }


    public OnPlayerPickUpPickup(playerid, pickupid)
    {
    return 1;
    }


    public OnVehicleMod(playerid, vehicleid, componentid)
    {
    return 1;
    }


    public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
    {
    return 1;
    }


    public OnVehicleRespray(playerid, vehicleid, color1, color2)
    {
    return 1;
    }


    public OnPlayerSelectedMenuRow(playerid, row)
    {
    return 1;
    }


    public OnPlayerExitedMenu(playerid)
    {
    return 1;
    }


    public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
    {
    return 1;
    }


    public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
    {
    return 1;
    }


    public OnRconLoginAttempt(ip[], password[], success)
    {
    return 1;
    }


    public OnPlayerUpdate(playerid)
    {
    return 1;
    }


    public OnPlayerStreamIn(playerid, forplayerid)
    {
    return 1;
    }


    public OnPlayerStreamOut(playerid, forplayerid)
    {
    return 1;
    }


    public OnVehicleStreamIn(vehicleid, forplayerid)
    {
    return 1;
    }


    public OnVehicleStreamOut(vehicleid, forplayerid)
    {
    return 1;
    }


    public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
    {
    return 1;
    }


    public OnPlayerClickPlayer(playerid, clickedplayerid, source)
    {
    return 1;
    }


    Hier die Errors: C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(31) : warning 209: function "OnPlayerConnect" should return a value
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(51) : warning 235: public function lacks forward declaration (symbol "OnRecordingPlaybackEnd")
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(53) : error 017: undefined symbol "StartRecordingPlayback"
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(56) : warning 235: public function lacks forward declaration (symbol "OnNPCEnterVehicle")
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(58) : error 017: undefined symbol "StartRecordingPlayback"
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(61) : warning 235: public function lacks forward declaration (symbol "OnNPCExitVehicle")
    C:\Users\Oliver\Desktop\SAMP SERVER\filterscripts\Bots.pwn(63) : error 017: undefined symbol "StopRecordingPlayback"
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    3 Errors.