06.07.2016, 22:55
Hello ,
While compiling this fs i get alot of errors:
While compiling this fs i get alot of errors:
PHP код:
// This is a comment
// uncomment the line below if you want to write a filterscript
#define FILTERSCRIPT
#include <a_samp>
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
print("AdmBot NPC");
ConnectNPC("AdmBot","justnpc");
MyFirstNPCVehicle = CreateVehicle(437, 0.0, 0.0, 5.0, 0.0, 198, 166, 5000);
return 1;
}
public OnPlayerSpawn(playerid)
{
if(IsPlayerNPC(playerid)) //Checks if the player that just spawned is an NPC.
{
new npcname[MAX_PLAYER_NAME];
GetPlayerName(playerid, npcname, sizeof(npcname)); //Getting the NPC's name.
if(!strcmp(npcname, "AdmBot", true)) //Checking if the NPC's name is MyFirstNPC
{
SetPlayerSkin(playerid, 147);
PutPlayerInVehicle(playerid, MyFirstNPCVehicle, 0); //Putting the NPC into the vehicle we created for it.
}
}
}
public OnFilterScriptExit()
{
print("AdmBot NPC Unloaded");
return 1;
}
#else
main()
{
print("\n----------------------------------");
print("AdmBot NPC Unloaded");
print("----------------------------------\n");
}
#endif
Код:
C:\Documents and Settings\Youssef\Bureau\RPG Romania 1.00.40\filterscripts\AdmBot.pwn(13) : error 017: undefined symbol "MyFirstNPCVehicle" C:\Documents and Settings\Youssef\Bureau\RPG Romania 1.00.40\filterscripts\AdmBot.pwn(25) : error 017: undefined symbol "MyFirstNPCVehicle" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 2 Errors.