示例#1
0
        // Mono
#pragma warning disable IDE0051 // Remove unused private members
        private void Awake()
        {
            _awakeModTypes   = new List <Type>();
            _delayedModTypes = new List <Type>();
            _updatableMods   = new List <IUpdatable>();
            _mods            = new List <AMod>();

            Tools.Initialize(this, Logger);
            Tools.IsStopwatchActive = true;

            Tools.Log("Initializing GameInput...");
            GameInput.Initialize();
            Tools.Log("Initializing Players...");
            Players.Initialize();

            Tools.Log("Categorizing mods by instantiation time...");
            CategorizeModsByInstantiationTime();
            Tools.Log("Awake:");
            foreach (var modType in _awakeModTypes)
            {
                Tools.Log($"\t{modType.Name}");
            }
            Tools.Log("Delayed:");
            foreach (var modType in _delayedModTypes)
            {
                Tools.Log($"\t{modType.Name}");
            }

            Tools.Log("Instantiating awake mods...");
            InstantiateMods(_awakeModTypes);

            Tools.Log($"Finished AwakeInit ({Tools.ElapsedMilliseconds}ms)");
            Tools.Log("");

            Tools.Log($"Waiting for game initialization...");
        }
示例#2
0
 public float AxisValue(ControlsInput.MenuActions menuAxis)
 => GameInput.AxisValue(ID, menuAxis);
示例#3
0
 public bool Released(ControlsInput.MenuActions menuAction)
 => GameInput.Released(ID, menuAction);
示例#4
0
 public bool Held(ControlsInput.MenuActions menuAction)
 => GameInput.Held(ID, menuAction);
示例#5
0
 public float AxisValue(ControlsInput.GameplayActions gameplayAxis)
 => GameInput.AxisValue(ID, gameplayAxis);
示例#6
0
 public bool Pressed(ControlsInput.MenuActions menuAction)
 => GameInput.Pressed(ID, menuAction);
示例#7
0
 public bool Released(ControlsInput.GameplayActions gameplayAction)
 => GameInput.Released(ID, gameplayAction);
示例#8
0
 public bool Held(ControlsInput.GameplayActions gameplayAction)
 => GameInput.Held(ID, gameplayAction);
示例#9
0
 public bool Pressed(ControlsInput.GameplayActions gameplayAction)
 => GameInput.Pressed(ID, gameplayAction);
示例#10
0
 public float AxisValue(string axisName)
 => GameInput.AxisValue(ID, axisName);
示例#11
0
 public bool Held(string actionName)
 => GameInput.Held(ID, actionName);
示例#12
0
 public bool Released(string actionName)
 => GameInput.Released(ID, actionName);
示例#13
0
 public bool Pressed(string actionName)
 => GameInput.Pressed(ID, actionName);