Please Help Me Mask System :"(
#1

Quote:

D:\Script\New Script Fre )\Philippines Roleplay (1)\gamemodes\VGRP.pwn(26276) : error 017: undefined symbol "pHasBoughtMask"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.

Quote:

CMD:fmask(playerid, params[])
{
new string[128];
if(AdminDuty[playerid] == 1)
{
SendClientMessage(playerid,COLOR_WHITE, "You can't use this command while on-duty as admin.");
return 1;
}
if(PlayerInfo[playerid][pFaction] == 2 || PlayerInfo[playerid][pLeader] == 2)
{
if(PlayerInfo[playerid][pRank] < 4)
{
SendClientMessage(playerid, COLOR_GREY, "You're not the required rank for that weapon (4+)!");
return 1;
}
if(PlayerInfo[playerid][pHasBoughtMask] == 0)
{
SendClientMessage(playerid, COLOR_GREY, "You don't have a mask.");
return 1;
}
if(PlayerInfo[playerid][pMask] == 0)
{
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
ShowPlayerNameTagForPlayer(i, playerid, 0);
}
}
PlayerInfo[playerid][pMask] = 1;
format(string, sizeof(string), "* %s brings out his mask, raising his both arms as he wears the mask.", GetPlayerNameEx(playerid));
ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPL E,COLOR_PURPLE);
}
else if(PlayerInfo[playerid][pMask] == 1)
{
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
ShowPlayerNameTagForPlayer(i, playerid, 1);
}
}
PlayerInfo[playerid][pMask] = 0;
format(string, sizeof(string), "* Stranger raising his right arm, grabbing the mask from his face and puts it away");
ProxDetector(15.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPL E,COLOR_PURPLE);
}
}
return 1;
}






Reply
#2

Add this at top:
PHP код:
new bool:pHasBoughtMask[MAX_PLAYERS]; 
Reply
#3

You need to define pHasBoughtMask to use it.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)