FCNPC error
#1

Hey
pawn Код:
YCMD:n(playerid, params[], help) // a test command , after I will put it in timer for my zombie bot
{
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z); // we get the player who put /npc position
FCNPC_Create("ZOMBIE"); // we  create the NPC
FCNPC_SetPosition(npcid,x+2.0,y,z); // teleport the NPC to player's pos
    return 1;
}
I get error :
Код:
C:\DOCUME~1\ADMINI~1\Bureau\FCINFE~1\GAMEMO~1\FCI.pwn(432) : error 017: undefined symbol "npcid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
what's the problem ? npcid is unknown how to know it ?
Thanks all for reading
Reply
#2

Код:
new npcid = FCNPC_Create("ZOMBIE");
Reply
#3

O thanks a lot ! one more thing : is it normal that a NPC ping is 6 millions ? & how to hide the NPC from TAB list ? cuz it's like a bot not player ...
Reply
#4

Quote:
Originally Posted by Saw®
Посмотреть сообщение
O thanks a lot ! one more thing : is it normal that a NPC ping is 6 millions ? & how to hide the NPC from TAB list ? cuz it's like a bot not player ...
I've never worked with the NPC with FCNPC, but that's awkward how come the NPCs are showing in score board? Also, 6 million pings is not valid at all, SA-MP doesn't syncs their pings.
Reply
#5

Quote:
Originally Posted by iZN
Посмотреть сообщение
I've never worked with the NPC with FCNPC, but that's awkward how come the NPCs are showing in score board? Also, 6 million pings is not valid at all, SA-MP doesn't syncs their pings.
Yea , strange that we see them in the score board, here's the command:
pawn Код:
YCMD:n(playerid, params[], help)
{
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
new npcid = FCNPC_Create("ZOMBIE");
FCNPC_Spawn(npcid,180,x,y+2.0,z);
    return 1;
}
SS:
Reply
#6

UP..
Reply
#7

It's not strange at all if you understood FCNPC or actually read through the thread you would realize the purpose is to enable OnPlayerGiveDamage() this makes the FCNPC damage system perfect. The best thing to do is set the NPC color black if you want to camouflage them in the player list. Anyways I do not recommend FCNPC at all it's not reliable for a myriad of reasons best to just stay away and use RNPC which is harder to use but will yield better results in the long run. Also keep in mind that those of us who do create NPC systems it takes a lot of effort and a lot of trouble shooting to design them.
Reply
#8

Oh thanks , u mean this one ?: https://sampforum.blast.hk/showthread.php?tid=412666

it doesn't work for me IDK why I used the GM test the NPCs don't spawn...

EDIT : it works
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)