17.08.2012, 01:52
how to make /houserob cmd
im using PPC_Housing system
im using PPC_Housing system
#define SCM SendClientMessage
CMD:robhouse(playerid, params[])
{
for(new i = 0; i < MAX_HOUSES;i++)
{
if(IsPlayerInRangeOfPoint(playerid,2.5,HInfo[i][XPos],HInfo[i][YPos],HInfo[i][ZPos]))
{
if(HInfo[i][locked] == 0)
{
GivePlayerMoney(playerid,3000);
If(playerinfo[playerid][criminal]);
SCM(playerid,-1,"You have sucessfully robbed the house.");
}
}
return 1;
}
return 0;
}
If(playerinfo[playerid][criminal]);
if(HInfo[i][locked] == 0)
//and
HInfo[i][XPos],HInfo[i][YPos],HInfo[i][ZPos]
GivePlayerMoney(playerid,3000);