Rev | Line | |
---|
[182] | 1 | using AllocsFixes.NetConnections.Servers.Telnet;
|
---|
[142] | 2 | using System;
|
---|
[182] | 3 | using System.Reflection;
|
---|
[142] | 4 |
|
---|
| 5 | namespace AllocsFixes
|
---|
| 6 | {
|
---|
| 7 | public class StateManager
|
---|
| 8 | {
|
---|
| 9 | public static void Awake (GameManager manager)
|
---|
| 10 | {
|
---|
| 11 | try {
|
---|
[182] | 12 | Log.Out ("[7dtd-server-fixes by Alloc] Version: " + Assembly.GetExecutingAssembly ().GetName ().Version);
|
---|
[224] | 13 |
|
---|
| 14 | Mods.LoadMods ();
|
---|
| 15 | Mods.CallGameAwake ();
|
---|
| 16 | CommandExtensions.InitCommandExtensions (manager);
|
---|
| 17 |
|
---|
[197] | 18 | new Telnet ();
|
---|
[182] | 19 |
|
---|
[197] | 20 | ItemList.Instance.Init ();
|
---|
[182] | 21 |
|
---|
[142] | 22 | PersistentData.PersistentContainer.Load ();
|
---|
| 23 | } catch (Exception e) {
|
---|
| 24 | Log.Out ("Error in StateManager.Awake: " + e);
|
---|
| 25 | }
|
---|
| 26 | }
|
---|
| 27 |
|
---|
| 28 | public static void Shutdown (GameManager manager)
|
---|
| 29 | {
|
---|
| 30 | try {
|
---|
[145] | 31 | Log.Out ("Server shutting down!");
|
---|
[224] | 32 | Mods.CallGameShutdown ();
|
---|
[142] | 33 | PersistentData.PersistentContainer.Instance.Save ();
|
---|
| 34 | } catch (Exception e) {
|
---|
| 35 | Log.Out ("Error in StateManager.Shutdown: " + e);
|
---|
| 36 | }
|
---|
| 37 | }
|
---|
| 38 | }
|
---|
| 39 | }
|
---|
| 40 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.