[UnSolved] Add functions to a_npc.inc
#6

Quote:
Originally Posted by lrZ^ aka LarzI
Quote:
Originally Posted by SiJ
Quote:
Originally Posted by lrZ^ aka LarzI
Firstly: Why don't you just try it yourself?
Secondly: Why double post?
1. It doesn't work for me, so I'm asking if it should work, and I'm doing anything wrong.
2. I apologize to you for double posting, I hope I didn't ruin your day with that.
Didn't ruin my day, but double posting isn't actually allowed you know.
And you didn't say it didn't work for you, you just asked if it would work with NPC scripts.
Since it's not working for you, it's probally not working at all.
Show us the way you used it?
Showing the definition doesn't help much..
I've added this to a_npc.inc:

pawn Код:
native CallRemoteFunction(const function[], const format[], {Float,_}:...);
And here is my NPC script:

pawn Код:
#include <a_npc>
#include <dudb>
#pragma unused ret_memcpy  //It gives me "warning 203: symbol is never used: "ret_memcpy"" so I use this..
main(){}

public OnNPCModeInit(){}
public OnNPCModeExit(){}
public OnNPCConnect(myplayerid){}
public OnNPCDisconnect(reason[]){}
public OnNPCSpawn(){}
public OnClientMessage(color, text[]){}
public OnPlayerDeath(playerid){}
public OnPlayerText(playerid, text[])
{
    if(strfind(text,"any jobs for me") != -1)
    {
        print("NPC: Someone asks for drug dealer job!");
            if (CallRemoteFunction("PlayerHasJob","d",playerid))
            {
              print("NPC: He already has a job!");
            }
            else
        {
            CallRemoteFunction("MakeDrugDealer","d",playerid);
            print("NPC: Job given!");
        }
    }
}
public OnPlayerStreamIn(playerid){}
public OnPlayerStreamOut(playerid){}
public OnVehicleStreamIn(vehicleid){}
public OnVehicleStreamOut(vehicleid){}
As you can see I don't use recording for this script, but it should work without recording, right?
Reply


Messages In This Thread
[UnSolved] Add functions to a_npc.inc - by SiJ - 23.12.2009, 19:43
Re: Add functions to a_npc.inc - by SiJ - 23.12.2009, 21:48
Re: Add functions to a_npc.inc - by LarzI - 23.12.2009, 22:15
Re: Add functions to a_npc.inc - by SiJ - 24.12.2009, 08:07
Re: Add functions to a_npc.inc - by LarzI - 24.12.2009, 08:15
Re: Add functions to a_npc.inc - by SiJ - 24.12.2009, 08:19
Re: Add functions to a_npc.inc - by LarzI - 24.12.2009, 08:34

Forum Jump:


Users browsing this thread: 1 Guest(s)