Can bots pick up a pickup?
#3

Quote:
Originally Posted by Jay_
Pickups aren't synced, so unless you have a global event that takes place when someone/thing pickups a pickup, how could you know the NPC didn't get the pickup?
I can show you the code..
pawn Код:
public OnGameModeInit()
{
    BusStopPickup1 = CreatePickup(323,14,-1967.4030,724.0678,45.4586);
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
    if (pickupid == BusStopPickup1)
    {
      print("Pickup 1 picked up"); //When bot drives through pickup this line doesn't work. When I'm with bot, this line works
      foreach(Player,i)
        {
            if(PlayerToPoint(5.0,i,-1964.3035, 720.1036, 45.7245))
            {
                printf("%i is in bus station!",i);
            }
            else print("Nobody's in Bus Stop");
        }
        return 1;
    }
    return 1;
}
Reply


Messages In This Thread
Can bots pick up a pickup? - by SiJ - 16.12.2009, 14:20
Re: Can bots pick up a pickup? - by Jay_ - 16.12.2009, 14:37
Re: Can bots pick up a pickup? - by SiJ - 16.12.2009, 14:41
Re: Can bots pick up a pickup? - by Jay_ - 16.12.2009, 14:43
Re: Can bots pick up a pickup? - by SiJ - 16.12.2009, 14:49

Forum Jump:


Users browsing this thread: 1 Guest(s)