SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Plugin Development

Reply
 
Thread Tools Display Modes
Old 03/01/2017, 03:12 AM   #3081
BagazPattrya
Little Clucker
 
Join Date: Dec 2016
Location: Kalimantan Timur, Indonesia
Posts: 5
Reputation: 0
Default Re: FCNPC - Fully Controllable NPC

Quote:
Originally Posted by ZiGGi View Post
No way.
Ohh, ok thanks. anyway, can you make me a filterscript that spawn NPC near with the player, the NPC just spawn, not doing anything, thanks before
BagazPattrya is offline   Reply With Quote
Old 03/01/2017, 04:29 AM   #3082
rt-2
Huge Clucker
 
rt-2's Avatar
 
Join Date: Jun 2011
Location: Montral, Qubec, Canada
Posts: 267
Reputation: 24
Default Re: FCNPC - Fully Controllable NPC

Quote:
Originally Posted by BagazPattrya View Post
Ohh, ok thanks. anyway, can you make me a filterscript that spawn NPC near with the player, the NPC just spawn, not doing anything, thanks before
I'll make you one, 20$/h, cheap price
__________________
rt-2
My hardcore first person 1994 simulation in development:
SA Advance Roleplay
rt-2 is offline   Reply With Quote
Old 03/01/2017, 06:40 AM   #3083
ZiGGi
High-roller
 
ZiGGi's Avatar
 
Join Date: Sep 2008
Location: Russia
Posts: 1,584
Reputation: 231
Default Re: FCNPC - Fully Controllable NPC

Quote:
Originally Posted by liguanhua123 View Post
help me!
[21:50:01] [FCNPC] Error: Incorrect parameter count for "FCNPC_AimAtPlayer", 8 != 11
Update your include file and recompile the script. Or downgrade the plugin.

Quote:
Originally Posted by BagazPattrya View Post
Ohh, ok thanks. anyway, can you make me a filterscript that spawn NPC near with the player, the NPC just spawn, not doing anything, thanks before
No, look sample scripts.
ZiGGi is offline   Reply With Quote
Old 03/01/2017, 08:22 AM   #3084
BagazPattrya
Little Clucker
 
Join Date: Dec 2016
Location: Kalimantan Timur, Indonesia
Posts: 5
Reputation: 0
Default Re: FCNPC - Fully Controllable NPC

Quote:
Originally Posted by ZiGGi View Post
Update your include file and recompile the script. Or downgrade the plugin.



No, look sample scripts.
Thanks for answering my question but, I dont understand filterscript in the sample, i think they are too complex, i'm noob scripter
BagazPattrya is offline   Reply With Quote
Old 03/01/2017, 02:21 PM   #3085
Freaksken
Huge Clucker
 
Freaksken's Avatar
 
Join Date: Mar 2009
Location: Belgium
Posts: 489
Reputation: 198
Default Re: FCNPC - Fully Controllable NPC

Quote:
Originally Posted by BagazPattrya View Post
i'm noob scripter
Then maybe you should start of with something simpler first.
__________________
Always keep in mind that a lot of people are active on this forum in their spare time.
They are sacrificing time they could easily spend on things they would rather do, to help you instead.


[Include] FCNPC A.I. - [Tutorial] Speedometer - [WIP] Single-player-like Mission - [Other] List of all my work
Freaksken is offline   Reply With Quote
Old 04/01/2017, 09:11 AM   #3086
BagazPattrya
Little Clucker
 
Join Date: Dec 2016
Location: Kalimantan Timur, Indonesia
Posts: 5
Reputation: 0
Default Re: FCNPC - Fully Controllable NPC

I Have created a script that spawn a NPC, but how can i make him shoot at me when i shoot him
BagazPattrya is offline   Reply With Quote
Old 04/01/2017, 01:49 PM   #3087
Freaksken
Huge Clucker
 
Freaksken's Avatar
 
Join Date: Mar 2009
Location: Belgium
Posts: 489
Reputation: 198
Default Re: FCNPC - Fully Controllable NPC

Quote:
Originally Posted by BagazPattrya View Post
I Have created a script that spawn a NPC, but how can i make him shoot at me when i shoot him
FCNPC_OnTakeDamage
FCNPC_AimAtPlayer
__________________
Always keep in mind that a lot of people are active on this forum in their spare time.
They are sacrificing time they could easily spend on things they would rather do, to help you instead.


[Include] FCNPC A.I. - [Tutorial] Speedometer - [WIP] Single-player-like Mission - [Other] List of all my work
Freaksken is offline   Reply With Quote
Old 12/01/2017, 04:08 AM   #3088
Kar
High-roller
 
Kar's Avatar
 
Join Date: May 2010
Location: Black Asylum
Posts: 3,280
Reputation: 429
Default Re: FCNPC - Fully Controllable NPC

For some reason.. I'm not sure.. I don't think FCNPC_OnSpawn or FCNPC_OnRespawn is called after a GMX.

I set players colors to grey on death, after I GMX all the NPCs are still grey because I set their color under the 2 callbacks above ^.
__________________
Kar is offline   Reply With Quote
Old 16/01/2017, 07:19 PM   #3089
whadez
Little Clucker
 
whadez's Avatar
 
Join Date: Jun 2014
Location: Hungary
Posts: 43
Reputation: 0
Default Re: FCNPC - Fully Controllable NPC

I'm having an issue, my server is crashing when I'm kicking out NPC's, it's happening with FCNPC_Destroy() aswell, any fixes soon? (Using latest plugin)


CODE WHERE THE SERVER CRASHES:
DeletePVar(playerid, "OnPlayerLogin");
StopAudioStreamForPlayer(playerid);
SCM(playerid,HEX_GREEN,"You have logged into your character.");
SetPlayerVirtualWorld(playerid,0);
DestroyVehicle(pInfo[playerid][pLoginVeh]);
if(IsPlayerNPC(pInfo[playerid][LoginNPC][0])) Kick(pInfo[playerid][LoginNPC][0]);
if(IsPlayerNPC(pInfo[playerid][LoginNPC][1])) Kick(pInfo[playerid][LoginNPC][1]);
pInfo[playerid][pSpawnCar]=CreateVehicle(412, 1275.9598,-2022.7804,58.7840,90.0492,0,0,0);
PutPlayerInVehicle(playerid,pInfo[playerid][pSpawnCar],0);
return 1;

CRASH CODE:
=========================== FCNPC Exception Handler ============================
Address: 0x62a7704a

Registers:
EAX: 0x1 - EBX: 0x2 - ECX: 0x0 - EDX: 0x6de338
ESI: 0x76c2e4 - EDI: 0x0 - EBP: 0x18fe0c - ESP: 0x18fdd8

Stack:
0x0: 0x1 - 0x4: 0x76c2e4 - 0x8: 0x0 - 0xC: 0x0 - 0x10: 0x0 - 0x14: 0x2c20020
0x18: 0x0 - 0x1C: 0x0 - 0x20: 0x0

Information:
System: Windows
SA-MP: 0.3.7
FCNPC: 1.6.1

Functions:
FUNC_CPlayerPool__DeletePlayer: 0x466740
FUNC_CPlayer__Kill: 0x4831f0
FUNC_CPlayer__EnterVehicle: 0x483840
FUNC_CPlayer__ExitVehicle: 0x483960
FUNC_CPlayer__SpawnForWorld: 0x485900
FUNC_GetVehicleModelInfo: 0x486e10
FUNC_CConsole__GetIntVariable: 0x488db0
FUNC_ClientJoin_RPC: 0x48f040

Pointers:
VAR_ServerAuthentication: 0x4f6cf0
VAR_NetVersion: 0xfd9

Offsets:
OFFSET_RemoteSystemManager: 0x33c
OFFSET_RemoteSystemSize: 0xcb8
OFFSET_RemoteSystem__ConnectMode: 0xcb0
OFFSET_RemoteSystem__Unknown: 0xcb5
=========================== FCNPC Exception Handler ============================
whadez is online now   Reply With Quote
Old 17/01/2017, 07:56 AM   #3090
ZiGGi
High-roller
 
ZiGGi's Avatar
 
Join Date: Sep 2008
Location: Russia
Posts: 1,584
Reputation: 231
Default Re: FCNPC - Fully Controllable NPC

Do not use Kick for NPCs. Are you shure about FCNPC_Destroy? Show me full sources.
ZiGGi is offline   Reply With Quote
Reply

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
[Include] Controllable NPC Lorenc_ Includes 101 02/06/2014 06:08 AM
[Plugin] FCNPC - Fully Controllable NPC sa-mp 0.3x R2 [LCK]Chris Plugin Development 82 16/05/2014 02:16 PM
Controllable HighPitchedVoice Scripting Help 5 25/05/2012 09:38 PM
[?]New SZR fully controllable NOS system Qeux Help Archive 3 17/03/2011 02:24 AM
Controllable NPC Andreq Русский/Russian 5 25/10/2010 07:57 AM


All times are GMT. The time now is 08:45 PM.


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