Odd issue with gang safe
#1

Hello folks.
I'm having an odd issue with my gamemode. I've finished scripting of a gang safe system for gangs on my server, but theres some problems in it, and I came to look for help from here as I haven't been able to sort it out.

There is no issues when compiling.
/safe command returns "SERVER: Unknown command", unless you're member of 1 or 12 factions. (returns You are not in a gang text piece to chat)

/safegetcrack /safegetpot /safegetmats /safestorepot /safestorecrack /safestoremats
All 6 commands above returns you the help tip for each cmd (Usage: /safegetcrack [amount], etc)
Those also returns "SERVER: Unknown command", and if you try to adjust the amount example /safegetcrack 10, it'll return only "SERVER: Unknown command", without the tip.

LINK

Help would be highly appreciated, thank you.
Reply
#2

Could it be [pFMember] ? Example:

pawn Код:
if(strcmp(cmd,"/safe",true)==0)
  {
  if(IsPlayerConnected(playerid))
  {
  if(PlayerInfo[playerid][pMember] == 12)
  {
  SendClientMessage(playerid,COLOR_GREY,"You are not in a gang !");
    return 1;
    }
  if(PlayerInfo[playerid][pMember] == 1)
  {
  SendClientMessage(playerid,COLOR_GREY,"You are not in a gang !");
    return 1;
    }
  new family = PlayerInfo[playerid][pMember];
  new safepotv = FamilyInfo[family][sPot];
  new safecrackv = FamilyInfo[family][sCrack];
  new safematsv = FamilyInfo[family][sMats];
  SendClientMessage(playerid, COLOR_GREEN, "|___ Gang Safe ___|");
    SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /safestore[name]");
    SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /safeget[name]");
    format(string, sizeof(string), "pot: %d | crack: %d | mats: %d", safepotv , safecrackv , safematsv);
    SendClientMessage(playerid, COLOR_GREEN, string);
    return 1;
    }
    }
This
pawn Код:
new family = PlayerInfo[playerid][pMember];
I recently tried to script .pwn to write families.cfg files, and I'm not sure does [pMember] works with the same way as [pFMember] does. Although I tried to use each codes in
pawn Код:
new family = PlayerInfo[playerid][pFMember];
but yet it returned only "SERVER: Unknown Command".

A tip or two would be nice to have.
Reply
#3

Please Write the completed script, i need it!

Thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)