OnPlayerPickUpPickup in include
#1

Hey!

I'm currently working on include, and I've added

forward OnPlayerPickUpPickup(playerid, pickupid);
public OnPlayerPickUpPickup(playerid, pickupid)

...

In it, but for some reason even tho pickups are created, it doesnt make the sound of getting picked up, neither does give me what I wrote in code which is nitro. What could be problem? should I define it differently because its include or ?
Reply
#2

The forward should be unneccessary as it's already forwarded in the SAMP includes.

You can put callbacks in includes just like anywhere else, but you should hook it instead of defining the original one in the include (you cannot have the same callback 2 times in one script, so having two includes that use the same callback will give you an error - includes aren't seperate scripts if you include both in one script (obviously)).
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)