Merge branch 'develop' of ssh://development.life-of-german.org:451/log-gtav/reallife-gamemode into develop
This commit is contained in:
@@ -46,7 +46,7 @@ namespace ReallifeGamemode.Server.Commands
|
|||||||
{
|
{
|
||||||
User user = player.GetUser();
|
User user = player.GetUser();
|
||||||
Faction f = user?.Faction;
|
Faction f = user?.Faction;
|
||||||
if (f == null || f.StateOwned)
|
if ((f == null || f.StateOwned) && !user.IsAdmin(AdminLevel.ADMIN))
|
||||||
{
|
{
|
||||||
ChatService.NotAuthorized(player);
|
ChatService.NotAuthorized(player);
|
||||||
return;
|
return;
|
||||||
@@ -180,7 +180,7 @@ namespace ReallifeGamemode.Server.Commands
|
|||||||
public void CmdFactionLc(Player player, string message)
|
public void CmdFactionLc(Player player, string message)
|
||||||
{
|
{
|
||||||
User user = player.GetUser();
|
User user = player.GetUser();
|
||||||
if (user?.FactionId == null || user.FactionLeader == false || !user.IsAdmin(AdminLevel.ADMIN))
|
if ((user?.FactionId == null || user.FactionLeader == false) && !user.IsAdmin(AdminLevel.ADMIN))
|
||||||
{
|
{
|
||||||
ChatService.NotAuthorized(player);
|
ChatService.NotAuthorized(player);
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ namespace ReallifeGamemode.Server.Services
|
|||||||
foreach (Player c in NAPI.Pools.GetAllPlayers())
|
foreach (Player c in NAPI.Pools.GetAllPlayers())
|
||||||
{
|
{
|
||||||
User user = c.GetUser();
|
User user = c.GetUser();
|
||||||
Faction f = user.Faction;
|
Faction f = user?.Faction;
|
||||||
if (f != null)
|
if (f != null)
|
||||||
{
|
{
|
||||||
if (factions.Find(fT => fT.Id == f.Id) != null)
|
if (factions.Find(fT => fT.Id == f.Id) != null)
|
||||||
|
|||||||
Reference in New Issue
Block a user