Keep getting error on pickups.
#1

i keep getting this?

Код:
C:\Users\user\Desktop\SAMP Server\Everything World\gamemodes\EverythingWorldTwoBeta.pwn(1187) : warning 235: public function lacks forward declaration (symbol "OnPlayerPickupPickup")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
Reply
#2

Quote:
Originally Posted by [mad
MLK (dino-host.net) ]
i keep getting this?

Код:
C:\Users\user\Desktop\SAMP Server\Everything World\gamemodes\EverythingWorldTwoBeta.pwn(1187) : warning 235: public function lacks forward declaration (symbol "OnPlayerPickupPickup")
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Warning.
forward OnPlayerPickUpPickup(playerid, pickupid);
Reply
#3

You don't forward it.
Reply
#4

Quote:
Originally Posted by [mad
MLK (dino-host.net) ]
i know but since when did you have to forward it lol
I don't know something must be wrong with your sa-mp includes
Reply
#5

You have your capitalization wrong.

OnPlayerPickUpPickup
Reply
#6

Yea that worked, Thanks, BTW the wiki needs fixing as thats were i got it from.
Reply
#7

Quote:
Originally Posted by [mad
MLK (dino-host.net) ]
Yea that worked, Thanks, BTW the wiki needs fixing as thats were i got it from.
https://sampwiki.blast.hk/wiki/OnPlayerPickUpPickup
Fine to me..
Reply
#8

The link: https://sampwiki.blast.hk/wiki/PickupGuide

The Example:

Код:
public OnPlayerPickupPickup(playerid, pickupid)
{
  if(pickupid == mypickup) // Check that the pickup ID of the pickup they picked up is mypickup
  {
    // It is
    SendClientMessage(playerid, 0xFFFFFFFF, "You received $10000!"); // Message the player
    GivePlayerMoney(playerid, 10000); // Give the player the money
  }
  else if (pickupid == (some other pickup))
  {
    // Another pickup, do something else
  }
  return 1;
}
Reply
#9

pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
  if(pickupid == mypickup) // Check that the pickup ID of the pickup they picked up is mypickup
  {
    // It is
    SendClientMessage(playerid, 0xFFFFFFFF, "You received $10000!"); // Message the player
    GivePlayerMoney(playerid, 10000); // Give the player the money
  }
  else if (pickupid == (some other pickup))
  {
    // Another pickup, do something else
  }
  return 1;
}
should be public OnPlayerPickUpPickup(playerid, pickupid)
not public OnPlayerPickupPickup(playerid, pickupid)
Reply
#10

My fault about the wiki typo :P
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)