MfG, DimGamer

This commit is contained in:
hydrant
2020-03-25 21:33:32 +01:00
parent 16be2869a0
commit 0d8249c39c
16 changed files with 1527 additions and 61 deletions

View File

@@ -4,6 +4,7 @@ using System.Text;
using GTANetworkAPI;
using ReallifeGamemode.Database.Entities;
using ReallifeGamemode.Server.Extensions;
using ReallifeGamemode.Server.Types;
using ReallifeGamemode.Server.WeaponDeal;
namespace ReallifeGamemode.Server.Events
@@ -22,9 +23,11 @@ namespace ReallifeGamemode.Server.Events
if (seat != 0) return;
User u = player.GetUser();
if (vehicle.GetServerVehicle() is FactionVehicle veh)
{
if (veh.FactionId != player.GetUser().FactionId)
if (!veh.GetOwners().Contains(player.GetUser().FactionId ?? 0) && !u.IsAdmin(AdminLevel.HEADADMIN))
{
if ((VehicleHash)vehicle.Model == VehicleHash.Burrito3)
{