SA-MP Forums Archive
Code doesn't work. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Code doesn't work. (/showthread.php?tid=74547)



Code doesn't work. - -eXo - 24.04.2009

I get these errors while trying to use this code.

Errors:
Код:
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2192) : error 004: function "SafeGivePlayerMoney" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2221) : error 004: function "SafeGivePlayerMoney" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2257) : error 004: function "SafeResetPlayerWeapons" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2258) : error 004: function "SafeGivePlayerWeapon" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2285) : error 004: function "SafeResetPlayerWeapons" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2586) : error 004: function "SetPlayerToTeamColor" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2611) : error 004: function "SetPlayerToTeamColor" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2653) : error 004: function "SetPlayerCriminal" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2658) : error 004: function "SetPlayerCriminal" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2756) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2767) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2779) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2783) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2795) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2799) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2803) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2807) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2811) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2815) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2819) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2823) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2835) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2839) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2843) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2847) : error 004: function "PlayerToPoint" is not implemented
C:\Users\staples036\Downloads\RLRP V2\gamemodes\rlrp.pwn(2851) : error 004: function "PlayerToPoint" is not implemented

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


26 Errors.
code:
Код:
public OnPlayerPickupPickup(playerid, pickupid)
{
	if (pickupid == yakuza09)
	{
	if(PlayerInfo[playerid][pLeader] == 5 )
			{

		SendClientMessage(playerid, COLOR_WHITE, "You have received your weapons!"); // Message the player
 		GivePlayerWeapon(playerid, 24, 60);
 		GivePlayerWeapon(playerid, 339, 1);
 		GivePlayerWeapon(playerid, 355, 61);
	}

	return 1;
	}



Re: Code doesn't work. - Joe Staff - 24.04.2009

Missing a bracket there, chief.


Re: Code doesn't work. - MenaceX^ - 24.04.2009

Post your code.
As Silent hunter said.
It has too much brackets.



Re: Code doesn't work. - ReV. - 24.04.2009

Quote:
Originally Posted by MenaceX^
Post your code.
As Silent hunter said.
It has too much brackets.
It's not because it has 'too much' brackets, you can have a million and it would compile fine. And if you can read, he already posted his code.

You're missing a bracket closing "OnPlayerPickupPickup"
pawn Код:
public OnPlayerPickupPickup(playerid, pickupid)
{
    if (pickupid == yakuza09)
    {
      if(PlayerInfo[playerid][pLeader] == 5 )
      {
         SendClientMessage(playerid, COLOR_WHITE, "You have received your weapons!"); // Message the player
         GivePlayerWeapon(playerid, 24, 60);
         GivePlayerWeapon(playerid, 339, 1);
         GivePlayerWeapon(playerid, 355, 61);
      }
      return 1;
    }
}



Re: Code doesn't work. - -eXo - 25.04.2009

It compiles now, however when someone walks into it. They dont get the weapons, even when I remove the leader check line. (I also fixed the weapon ID's from the code above, so it isn't that)

Also, how would I change it from a money sign to like a big red circle thingy?.


Re: Code doesn't work. - Blacklite - 25.04.2009

Quote:
Originally Posted by -eXo
It compiles now, however when someone walks into it. They dont get the weapons, even when I remove the leader check line. (I also fixed the weapon ID's from the code above, so it isn't that)

Also, how would I change it from a money sign to like a big red circle thingy?.
You have to use a checkpoint, rather than a pickup.