OnPlayerPickUpPickup not working?
#1

Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
	SendClientMessage(playerid, COLOR_WHITE, "test");
	return 1;
}
Something isn't right here, I use both AddStaticPickup and CreatePickup, neither seem to work. I've tried using pickup types 2 and 23. Any idea whats causing this?
Reply
#2

you need to define the Pickup!

pawn Код:
new pickup1;

OnGamemodeInit(plaplapla)
{
   pickup1 = AddStaticPickup(plaplapla);
}

OnPlayerPickUpPickup(playerid, pickupid(
{
  if(pickupid == pickup1)
  {
    //your things here
  }
}
Reply
#3

actually, i wound up renaming the pwn file... and forgot to rename the gamemode to use in the server cfg... I changed it and it works now, simple brain fart
Reply
#4

hehe
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)