The NPC is leaving right after he joins
#1

This is how its defined:

OnGameModeInit

Quote:

ConnectNPC("JobNPC1","JobNPC1");

OnPlayerRequestSpawn

Quote:

if(IsPlayerNPC(playerid))return 1;

OnPlayerRequestClass

Quote:

if(IsPlayerNPC(playerid))return 1;

OnPlayerConnect
Quote:

if(IsPlayerNPC(playerid))return 1;

OnPlayerSpawn

Quote:

if(IsPlayerNPC(playerid))return 1;

{
if(IsPlayerNPC(playerid))
{
new npcname[MAX_PLAYER_NAME];
GetPlayerName(playerid, npcname, sizeof(npcname));
if(!strcmp(npcname, "JobNPC1", true))

return 1;
}
}

Whats wrong with it?
Reply
#2

Bump
Reply
#3

ConnectNPC("JobNPC1","JobNPC1");

and in onplayerconnect:

Make a timer for 10 secs

And add if(is npc blablabla SpawnPlayer
Reply
#4

Didn't work..
Reply
#5

BUMP
Reply
#6

Don't double post.

Don't bump topics before 12 hours.

Quote:

b) Do not bump
Some people apparently think they are important enough to bump their own topic after 10 minutes.
You can bump topics when the last reply is at least 12 hours old, and it needs to have useful information about your problem.

c) Help yourself
-Follow the READ ME FIRST! thread
-Use the search option
-Read the wiki
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)