playerid error - 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)
+--- Thread: playerid error (
/showthread.php?tid=502318)
playerid error -
CallumDaBest - 23.03.2014
It comes up with these errors why?
Код:
C:\Users\Gamer\Desktop\PLA.pwn(17528) : error 025: function heading differs from prototype
C:\Users\Gamer\Desktop\PLA.pwn(17530) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17530) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17532) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17533) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17534) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17535) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17536) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17539) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17542) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17543) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17544) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17547) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17548) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17551) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17552) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17553) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17554) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17555) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17556) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17557) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17558) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17559) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17560) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17561) : error 017: undefined symbol "playerid"
C:\Users\Gamer\Desktop\PLA.pwn(17562) : error 017: undefined symbol "playerid"
Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
26 Errors.
Code in the script:
Код:
public OnPlayerDisconnect(playerid, reason)
{
if(IsLoaded, playerid) IsLoaded[playerid] = 0;//Line 17530
//Speedos
PlayerTextDrawDestroy(playerid,SpeedoText0);
PlayerTextDrawDestroy(playerid,SpeedoText1);
PlayerTextDrawDestroy(playerid,SpeedoText2);
PlayerTextDrawDestroy(playerid,SpeedoText3);
PlayerTextDrawDestroy(playerid,SpeedoText4);
//Samsung Galaxy
PlayerTextDrawDestroy(playerid,CalculatorTD2);
//Random News
PlayerTextDrawDestroy(playerid, ServerTips);
PlayerTextDrawDestroy(playerid, MessagesTD);
PlayerTextDrawDestroy(playerid, ServerBanner);
//Radar
PlayerTextDrawDestroy(playerid,RadarHud);
PlayerTextDrawDestroy(playerid,SpeedAndModel);
//Baitcar
PlayerTextDrawDestroy(playerid, Textdraw0);
PlayerTextDrawDestroy(playerid, Textdraw1);
PlayerTextDrawDestroy(playerid, Textdraw2);
PlayerTextDrawDestroy(playerid, Textdraw3);
PlayerTextDrawDestroy(playerid, Textdraw4);
PlayerTextDrawDestroy(playerid, Textdraw5);
PlayerTextDrawDestroy(playerid, Textdraw6);
PlayerTextDrawDestroy(playerid, Textdraw7);
PlayerTextDrawDestroy(playerid, Textdraw8);
PlayerTextDrawDestroy(playerid, Textdraw9);
PlayerTextDrawDestroy(playerid, Textdraw10);
PlayerTextDrawDestroy(playerid, Textdraw11);//Line 17562
PlayerTextDrawDestroy(playerid, Textdraw12);
BaitMonitor[playerid] = 0;
Pursuit[playerid] = 0;
DestroyDynamic3DTextLabel(PlayerInfo[playerid][aMeID]);
PlayerInfo[playerid][aMeStatus] =0;
new activewep, activeammo;
activewep = GetPVarInt(playerid, "activesling");
activeammo = GetPVarInt(playerid, "activeslingammo");
if(activewep > 0)
{
new
szWeapon[16],
szMessage[128];
GetWeaponName(activewep, szWeapon, sizeof(szWeapon));
GivePlayerValidWeapon(playerid, activewep, activeammo);
format(szMessage, sizeof(szMessage), "You have unslung the %s from your back.", szWeapon);
SendClientMessageEx(playerid, COLOR_WHITE, szMessage);
format(szMessage, sizeof(szMessage), "* %s unslings a %s from their back.", GetPlayerNameEx(playerid), szWeapon);
ProxDetector(30.0, playerid, szMessage, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
DeletePVar(playerid, "activesling");
}
Re: playerid error -
CallumDaBest - 23.03.2014
Help please
Re: playerid error -
MP2 - 23.03.2014
Wait
24 hours to bump.
Re: playerid error -
Equuuuin0X - 23.03.2014
LOL when I see this.
it shud be like this with the textdraws.
pawn Код:
PlayerTextDrawDestroy(SpeedoText0,playerid);
PlayerTextDrawDestroy(SpeedoText1,playerid);
PlayerTextDrawDestroy(SpeedoText2,playerid);
PlayerTextDrawDestroy(SpeedoText3,playerid);
PlayerTextDrawDestroy(SpeedoText4,playerid);
//Samsung Galaxy
PlayerTextDrawDestroy(CalculatorTD2,playerid);
//Random News
PlayerTextDrawDestroy(ServerTips,playerid);
PlayerTextDrawDestroy(MessagesTD,playerid);
PlayerTextDrawDestroy(ServerBanned,playerid);
//Radar
PlayerTextDrawDestroy(RadarHud,playerid);
PlayerTextDrawDestroy(SpeedAndModel,playerid);
//Baitcar
PlayerTextDrawDestroy(Textdraw0,playerid);
PlayerTextDrawDestroy(Textdraw1,playerid);
PlayerTextDrawDestroy(Textdraw2,playerid);
PlayerTextDrawDestroy(Textdraw3,playerid);
PlayerTextDrawDestroy(Textdraw4,playerid);
PlayerTextDrawDestroy(Textdraw5,playerid);
PlayerTextDrawDestroy(Textdraw6,playerid);
PlayerTextDrawDestroy(Textdraw7,playerid);
PlayerTextDrawDestroy(Textdraw8,playerid);
PlayerTextDrawDestroy(Textdraw9,playerid);
PlayerTextDrawDestroy(Textdraw10,playerid);
PlayerTextDrawDestroy(Textdraw11,playerid);//Line 17562
PlayerTextDrawDestroy(Textdraw12,playerid);
Re: playerid error -
MP2 - 23.03.2014
There's no need to be destroying player-textdraws on disconnect anyway. Obviously they won't exist anymore if the player leaves..
Re: playerid error -
Equuuuin0X - 23.03.2014
Other than MP2 says,
you should put the ''Textdraw1'' etc thingy, before the ''playerid''.