public static bool HasGangCommand(GameClient Session, string command) { if (Session == null || Session.GetRoleplay() == null) { return(false); } int GangId = Session.GetRoleplay().GangId; int GangRank = Session.GetRoleplay().GangRank; if (GangId == 1000) { return(false); } Group Gang = GetGang(GangId); GroupRank Rank = GetGangRank(GangId, GangRank); if (Gang == null || Rank == null) { return(false); } if (!Rank.HasCommand(command)) { return(false); } return(true); }
public static bool HasJobCommand(GameClient Session, string command) { if (Session == null || Session.GetRoleplay() == null) { return(false); } int JobId = Session.GetRoleplay().JobId; int JobRank = Session.GetRoleplay().JobRank; if (JobId == 1) { return(false); } Group Job = GetJob(JobId); GroupRank Rank = GetJobRank(JobId, JobRank); if (Job == null || Rank == null) { return(false); } if (!Rank.HasCommand(command)) { return(false); } return(true); }