21.08.2011, 01:25
Well when im not near a /atm it shows i am not near a atm, but when i go to a random atm it shows You are not near a atm, please help
pawn Code:
CMD:atm(playerid,params[])
{
if(!IsPlayerInRangeOfPoint(playerid,1,2228.30688477,-1715.81237793,13.21310616)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2045.58654785,-1909.97204590,13.18977451)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,1154.66308594,-1456.00451660,15.43977451)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2424.53173828,-1219.58166504,25.17372131)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,378.54266357,-2061.15917969,7.47883701)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2023.52770996,997.79492188,10.46321201)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2194.95239258,1988.35095215,11.93977451)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2224.72631836,1830.93542480,10.46321201)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2196.88867188,1673.56408691,12.01008701)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,1627.44104004,1814.48828125,10.46321201)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,1971.71301270,2041.84753418,10.70389652)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2275.69873047,2292.50634766,10.46321201)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,2500.02856445,2123.77832031,10.48342609)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,413.86004639,2537.95288086,18.79133606)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,-1967.16564941,291.60144043,34.94517517)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,-2269.99560547,-153.04603577,34.96321106)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,-2517.18969727,-624.90289307,132.43955994)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
else if(!IsPlayerInRangeOfPoint(playerid,1,-2626.94506836,1412.05920410,6.73664951)) return SendClientMessage(playerid,red,"ERROR: You are not near a atm!");
ShowPlayerDialog(playerid,37,DIALOG_STYLE_LIST,"ATM","Deposit\nWithdraw","Open","Close");
return 1;
}