simple NPC doesn't spawn - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: simple NPC doesn't spawn (
/showthread.php?tid=429669)
simple NPC doesn't spawn -
HurtLocker - 10.04.2013
I started getting used to manage npcs. I recorded a simple waving welcome motion with length about 10 sec. I add this line in a random non-npc filterscript:
pawn Код:
public OnFilterScriptInit()
{
print(" Loaded successful.");
ConnectNPC("Welcome","wave_npc"); //wave_npc is the name of the npc filterscript which follows down
return 1; //and it is located in the folder \npcmodes
}
Next I created a npc filterscript which is used above and this is the whole of it:
pawn Код:
#include <a_npc.inc>
main() {}
public OnNPCSpawn() StartRecordingPlayback(PLAYER_RECORDING_TYPE_ONFOOT,"wave");
public OnRecordingPlaybackEnd() StartRecordingPlayback(PLAYER_RECORDING_TYPE_ONFOOT,"wave");
wave is the .rec file
I open server and my ncp is not there, what am I doing wrong?
Re: simple NPC doesn't spawn -
iJumbo - 10.04.2013
Have you modify the maxnpc on server.cfg?
Re: simple NPC doesn't spawn -
HurtLocker - 10.04.2013
Yes, I entered value 5 just to put something. I need only 1.
Re: simple NPC doesn't spawn -
iJumbo - 10.04.2013
Im not so familiar with NPC let me check somewhere
Re: simple NPC doesn't spawn -
HurtLocker - 11.04.2013
Some help here.
Re: simple NPC doesn't spawn -
fiki574 - 11.04.2013
pawn Код:
public OnFilterScriptInit()
{
ConnectNPC("Welcome","wave_npc");
return 1;
}
"wave_npc.pwn" file:
pawn Код:
#include <a_npc>
main()
{
}
NextPlayback()
{
StartRecordingPlayback(PLAYER_RECORDING_TYPE_ONFOOT,"wave_npc");
}
public OnRecordingPlaybackEnd()
{
NextPlayback();
}
Re: simple NPC doesn't spawn -
HurtLocker - 11.04.2013
Still nothing, I suppose its something I don't do correctly...