NPC Amimation!!!
#3

Quote:
Originally Posted by billiout
Посмотреть сообщение
noone? pls help
put it in npcmodes folder.

pawn Код:
#include <a_npc>

//------------------------------------------
#define YOUR_DISTANCE 5.0

main()
{
    SetTimer( "Check", 1000, 1 );
}

forward public Check();
public Check()
{
    new Float:npc_pos[3];
    GetMyPos( npc_pos[0], npc_pos[1], npc_pos[2] );
    for( new i = 0 ; i < MAX_PLAYERS ; i ++)
    {
        if( IsPlayerConnected(i) && !IsPlayerNPC(i) )
        {          
            if( IsPlayerInRangeOfPoint( i , YOUR_DISTANCE, npc_pos[0], npc_pos[1], npc_pos[2] ) )          
            {
                SendChat( "Hey~ I wanna take you to a gay bar!" );
            }
        }
    }
}

didn't optimized the code.
Reply


Messages In This Thread
NPC Amimation!!! - by billiout - 21.08.2010, 17:27
Re: NPC Amimation!!! - by billiout - 22.08.2010, 06:13
Re: NPC Amimation!!! - by dax123 - 22.08.2010, 06:31
Re: NPC Amimation!!! - by billiout - 22.08.2010, 07:04
Re: NPC Amimation!!! - by dax123 - 22.08.2010, 07:09
Re: NPC Amimation!!! - by billiout - 22.08.2010, 07:18
Re: NPC Amimation!!! - by dax123 - 22.08.2010, 07:51

Forum Jump:


Users browsing this thread: 1 Guest(s)