PDA

View Full Version : error 017: undefined symbol


Andrew163
02/08/2012, 11:35 AM
Help fix the error.

D:\Games\SAMP сервер\SampDM\filterscripts\Script.pwn(314) : error 017: undefined symbol "Bank"

{
if(pickupid == Bank)
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 1480.7194,-1765.2272,18.7958);//
}
return 1;
}

oKzrh
02/08/2012, 11:37 AM
You haven't declared such a variable called "Bank".
Try adding "new Bank" to the top of your script (under your includes, defines, etc.. Where there should be some more variables).
Also, assign the pickup (CreatePickup) to the Bank variable like so:

Bank = CreatePickup(...);

Andrew163
02/08/2012, 11:50 AM
new Bank;
public OnFilterScriptExit()
Bank = CreatePickup(1274,23,1481.0802,-1770.3795,18.7958);
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == Bank)
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 4546.9433, -2005.5704, 22.5492);//
}
return 1;
}

oKzrh
02/08/2012, 12:01 PM
Is it working now?
Is the "new Bank;" at the top (Above all of the publics).

Andrew163
03/08/2012, 03:44 AM
yes "new Bank," in up the script,in at the bottom of intsludes and #if defined FILTERSTSRIPT