29.12.2016, 06:17
PHP Code:
if(newkeys == KEY_YES)
{
printf("Passed key");
new a;
if(IsPlayerInRangeOfPoint(playerid, 2.0, AtmInfo[a][aPosX], AtmInfo[a][aPosY], AtmInfo[a][aPosZ]))
{
printf("First passed");
if(PlayerInfo[playerid][AtmCard] != 1)
{
ERROR(playerid, "You need to purchase Atm Card");
return 1;
}
SPD(playerid, DIALOG_BANK, DIALOG_STYLE_LIST, "Bank", "Withdraw money\nPut in bank", "Select", "Leave");
printf("Dialog shown");
return 1;
}
}
After
printf("Passed key");
nothing gets executed.. It looks like I am not in range of point but I am...
But Nothing after that.. Here is the enum
PHP Code:
#define MAX_ATM 51
#define ATM_OBJECT 2942
enum aInfo
{
aID,
Float:aPosX,
Float:aPosY,
Float:aPosZ,
Float:aAngle,
aInt,
aVW,
bool: AtmExist,
}
new AtmInfo[MAX_ATM][aInfo],
Text3D:AtmLabel[MAX_ATM],
AtmObject[MAX_ATM],
Iterator: i_ATM<MAX_ATM>;