outsourced database initialization, faction bank accounts get added if none exist
This commit is contained in:
10
Main.cs
10
Main.cs
@@ -6,6 +6,7 @@ using reallife_gamemode.Model;
|
||||
using reallife_gamemode.Server.Entities;
|
||||
using reallife_gamemode.Server.Managers;
|
||||
using reallife_gamemode.Server.Saves;
|
||||
using reallife_gamemode.Server.Util;
|
||||
|
||||
/**
|
||||
* @overview Life of German Reallife - Main Class (Main.cs)
|
||||
@@ -33,13 +34,8 @@ namespace reallife_gamemode
|
||||
|
||||
TuningManager.AddTuningGarage(new Vector3(-341, -134, 38.5));
|
||||
|
||||
using (var context = new DatabaseContext())
|
||||
{
|
||||
context.Bans.FirstOrDefault();
|
||||
context.Factions.FirstOrDefault();
|
||||
context.Users.FirstOrDefault();
|
||||
context.SaveChanges();
|
||||
}
|
||||
DatabaseHelper.InitDatabaseFirstTime();
|
||||
FactionHelper.CheckFactionBankAccounts();
|
||||
|
||||
TempBlip tempBlip = new TempBlip()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user