Merged feature/business-system into develop

This commit is contained in:
hydrant
2018-11-27 16:08:22 +01:00
17 changed files with 781 additions and 6 deletions

View File

@@ -3,11 +3,9 @@ using reallife_gamemode.Model;
using reallife_gamemode.Server.Extensions;
using reallife_gamemode.Server.Util;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
/**
* @overview Life of German Reallife - Entities User (User.cs)
@@ -59,6 +57,8 @@ namespace reallife_gamemode.Server.Entities
public int? FactionRankId { get; set; }
public FactionRank FactionRank { get;set; }
public int? BusinessId { get; set; }
public Faction GetFaction()
{
using(var context = new DatabaseContext())
@@ -146,5 +146,10 @@ namespace reallife_gamemode.Server.Entities
return databaseContext.UserBankAccounts.FirstOrDefault(u => u.UserId == this.Id);
}
}
public Client GetClient()
{
return NAPI.Player.GetPlayerFromName(Name);
}
}
}