SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help > Help Archive

 
 
Thread Tools Display Modes
Old 09/02/2010, 10:34 AM   #1
Ma
Little Clucker
 
Join Date: Feb 2010
Posts: 15
Reputation: 0
Default NPC leaves server after joining

Hi,

I'm using an edit from the Godfather gamemode and I created an filterscript with NPC's.
When I load this filterscript, my NPC leaves my server after joining.
I think they get autokicked by the godfather login system.
How can I fix this in the filterscript? Or do I need to create accounts for my NPC's and let them log in? But how do I let my NPC's write a command?

I hope somebody can help me with this problem.
Ma is offline  
Old 09/02/2010, 10:35 AM   #2
V1ceC1ty
Banned
 
Join Date: Oct 2008
Location: West Australia
Posts: 1,909
Reputation: 273
Default Re: NPC leaves server after joining

http://forum.sa-mp.com/index.php?topic=119947.0

Read the whole tutorial.
V1ceC1ty is offline  
Old 09/02/2010, 10:37 AM   #3
Ma
Little Clucker
 
Join Date: Feb 2010
Posts: 15
Reputation: 0
Default Re: NPC leaves server after joining

Quote:
Originally Posted by V1ceC1ty
I read this whole topic 5 time's, there is no solution for this problem in it. Thanks for trying.
Ma is offline  
Old 09/02/2010, 12:02 PM   #4
V1ceC1ty
Banned
 
Join Date: Oct 2008
Location: West Australia
Posts: 1,909
Reputation: 273
Default Re: NPC leaves server after joining

There is a solution, read it all. It's even in big writing.
V1ceC1ty is offline  
Old 09/02/2010, 12:10 PM   #5
Ma
Little Clucker
 
Join Date: Feb 2010
Posts: 15
Reputation: 0
Default Re: NPC leaves server after joining

Quote:
Originally Posted by V1ceC1ty
There is a solution, read it all. It's even in big writing.
If you mean

Code:
if(IsPlayerNPC(playerid)) return 1;
That is not working, I placed this line on every place you can think about, and stull my NPC get kicked.
Ma is offline  
Old 09/02/2010, 12:36 PM   #6
V1ceC1ty
Banned
 
Join Date: Oct 2008
Location: West Australia
Posts: 1,909
Reputation: 273
Default Re: NPC leaves server after joining

Quote:
Originally Posted by Ma
Quote:
Originally Posted by V1ceC1ty
There is a solution, read it all. It's even in big writing.
If you mean

Code:
if(IsPlayerNPC(playerid)) return 1;
That is not working, I placed this line on every place you can think about, and stull my NPC get kicked.
You see all my NPC scripts in my signature, well I read through the tutorial properly and got my first NPC to work the first time. There is numerous reasons why yours doesn't work so why don't you let us see your script?
V1ceC1ty is offline  
Old 09/02/2010, 01:02 PM   #7
Ma
Little Clucker
 
Join Date: Feb 2010
Posts: 15
Reputation: 0
Default Re: NPC leaves server after joining

Quote:
Originally Posted by V1ceC1ty
Quote:
Originally Posted by Ma
Quote:
Originally Posted by V1ceC1ty
There is a solution, read it all. It's even in big writing.
If you mean

Code:
if(IsPlayerNPC(playerid)) return 1;
That is not working, I placed this line on every place you can think about, and stull my NPC get kicked.
You see all my NPC scripts in my signature, well I read through the tutorial properly and got my first NPC to work the first time. There is numerous reasons why yours doesn't work so why don't you let us see your script?
I just followed the tutorial step by step in a filterscript, nothing more, nothing less, and my gamemode is just the basic godfather, nothing else.
Ma is offline  
Old 09/02/2010, 01:04 PM   #8
[KMA]DlennartD
Huge Clucker
 
[KMA]DlennartD's Avatar
 
Join Date: Mar 2008
Location: The Netherlands
Posts: 253
Reputation: 4
Default Re: NPC leaves server after joining

Try like KC says:

Code:
onPlayerCommandText(npc_id_here, "/command");
Maybe you can let your NPC's login on a existing account, I'm not sure but you can give it a shot.
__________________
[KMA]DlennartD is offline  
Old 09/02/2010, 01:04 PM   #9
Ma
Little Clucker
 
Join Date: Feb 2010
Posts: 15
Reputation: 0
Default Re: NPC leaves server after joining

Quote:
Originally Posted by [KMA
DlennartD ]
Try like KC says:

Code:
nPlayerCommandText(npc_id_here, "/command");
Maybe you can let your NPC's login on a existing account, I'm not sure but you can give it a shot.
Where shall I place this line?
Ma is offline  
Old 09/02/2010, 01:07 PM   #10
(Jeff)
Huge Clucker
 
Join Date: Sep 2009
Posts: 242
Reputation: 0
Default Re: NPC leaves server after joining

Quote:
Originally Posted by Ma
Quote:
Originally Posted by [KMA
DlennartD ]
Try like KC says:

Code:
nPlayerCommandText(npc_id_here, "/command");
Maybe you can let your NPC's login on a existing account, I'm not sure but you can give it a shot.
Where shall I place this line?
OnPlayerCommand Text i suppose
(Jeff) is offline  
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
NPC leaves 20 seconds after joining iklipse Help Archive 3 18/05/2010 03:57 PM
Error joining server dclaw Client Support 8 03/05/2010 11:57 AM
MOVED: Error joining server dugi General 0 30/04/2010 09:11 PM
Error when joining a server in SA-MP Carl_I Client Support 6 29/04/2010 01:53 PM
Crash while joining a server Gabawaba Help Archive 1 19/03/2009 08:59 AM


All times are GMT. The time now is 05:08 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.