Fix build errors from GC update
This commit is contained in:
parent
1faa9898f7
commit
934b542ea1
6 changed files with 14 additions and 14 deletions
|
@ -32,9 +32,9 @@ namespace GamecraftModdingAPI.Blocks
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static ExclusiveGroup SIM_BLOCKS_DISABLED { get { return CommonExclusiveGroups.BLOCKS_DISABLED_IN_SIM_GROUP; } }
|
public static ExclusiveGroup SIM_BLOCKS_DISABLED { get { return CommonExclusiveGroups.BLOCKS_DISABLED_IN_SIM_GROUP; } }
|
||||||
|
|
||||||
public static ExclusiveGroup SPAWN_POINTS { get { return CommonExclusiveGroups.SPAWN_POINTS_GROUP; } }
|
//public static ExclusiveGroup SPAWN_POINTS { get { return CommonExclusiveGroups.SPAWN_POINTS_GROUP; } }
|
||||||
|
|
||||||
public static ExclusiveGroup SPAWN_POINTS_DISABLED { get { return CommonExclusiveGroups.SPAWN_POINTS_DISABLED_GROUP; } }
|
//public static ExclusiveGroup SPAWN_POINTS_DISABLED { get { return CommonExclusiveGroups.SPAWN_POINTS_DISABLED_GROUP; } }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The ID of the most recently placed block
|
/// The ID of the most recently placed block
|
||||||
|
|
|
@ -85,7 +85,7 @@ namespace GamecraftModdingAPI.Blocks
|
||||||
{
|
{
|
||||||
case CubeCategory.SpawnPoint:
|
case CubeCategory.SpawnPoint:
|
||||||
case CubeCategory.BuildingSpawnPoint:
|
case CubeCategory.BuildingSpawnPoint:
|
||||||
newBlockID = MachineEditingGroups.NewSpawnPointBlockID;
|
newBlockID = MachineEditingGroups.NewUncheckedBlockEGID;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
newBlockID = MachineEditingGroups.NewBlockID;
|
newBlockID = MachineEditingGroups.NewBlockID;
|
||||||
|
|
|
@ -12,7 +12,7 @@ namespace GamecraftModdingAPI.Events
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Event emitter engine for switching to to build mode.
|
/// Event emitter engine for switching to to build mode.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class GameStateBuildEmitterEngine : IEventEmitterEngine, IInitializeOnBuildStart
|
public class GameStateBuildEmitterEngine : IEventEmitterEngine, IUnorderedInitializeOnTimeStoppedModeEntered
|
||||||
{
|
{
|
||||||
public string Name { get; } = "GamecraftModdingAPIGameStateBuildEventEmitter" ;
|
public string Name { get; } = "GamecraftModdingAPIGameStateBuildEventEmitter" ;
|
||||||
|
|
||||||
|
@ -37,13 +37,13 @@ namespace GamecraftModdingAPI.Events
|
||||||
public void EmitIfBuildMode()
|
public void EmitIfBuildMode()
|
||||||
{
|
{
|
||||||
//Logging.MetaDebugLog($"nextSimulationMode: {entitiesDB.QueryUniqueEntity<SimulationModeStateEntityStruct>(SimulationModeStateExclusiveGroups.GAME_STATE_GROUP).nextSimulationMode}");
|
//Logging.MetaDebugLog($"nextSimulationMode: {entitiesDB.QueryUniqueEntity<SimulationModeStateEntityStruct>(SimulationModeStateExclusiveGroups.GAME_STATE_GROUP).nextSimulationMode}");
|
||||||
if (entitiesDB.QueryUniqueEntity<SimulationModeStateEntityStruct>(SimulationModeStateExclusiveGroups.GAME_STATE_GROUP).nextSimulationMode == SimulationMode.Build)
|
if (entitiesDB.QueryUniqueEntity<SimulationModeStateEntityStruct>(SimulationModeStateExclusiveGroups.GAME_STATE_GROUP).nextSimulationMode == SimulationMode.TimeStopped)
|
||||||
{
|
{
|
||||||
Emit();
|
Emit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public JobHandle OnInitializeBuildMode()
|
public JobHandle OnInitializeTimeStoppedMode()
|
||||||
{
|
{
|
||||||
Emit();
|
Emit();
|
||||||
return default(JobHandle);
|
return default(JobHandle);
|
||||||
|
|
|
@ -12,7 +12,7 @@ namespace GamecraftModdingAPI.Events
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Event emitter engine for switching to simulation mode.
|
/// Event emitter engine for switching to simulation mode.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class GameStateSimulationEmitterEngine : IEventEmitterEngine, IInitializeOnSimulationStart
|
public class GameStateSimulationEmitterEngine : IEventEmitterEngine, IUnorderedInitializeOnTimeRunningModeEntered
|
||||||
{
|
{
|
||||||
public string Name { get; } = "GamecraftModdingAPIGameStateSimulationEventEmitter" ;
|
public string Name { get; } = "GamecraftModdingAPIGameStateSimulationEventEmitter" ;
|
||||||
|
|
||||||
|
@ -36,13 +36,13 @@ namespace GamecraftModdingAPI.Events
|
||||||
|
|
||||||
public void EmitIfSimMode()
|
public void EmitIfSimMode()
|
||||||
{
|
{
|
||||||
if (entitiesDB.QueryUniqueEntity<SimulationModeStateEntityStruct>(SimulationModeStateExclusiveGroups.GAME_STATE_GROUP).nextSimulationMode == SimulationMode.Simulation)
|
if (entitiesDB.QueryUniqueEntity<SimulationModeStateEntityStruct>(SimulationModeStateExclusiveGroups.GAME_STATE_GROUP).nextSimulationMode == SimulationMode.TimeRunning)
|
||||||
{
|
{
|
||||||
Emit();
|
Emit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public JobHandle OnInitializeSimulationMode()
|
public JobHandle OnInitializeTimeRunningMode()
|
||||||
{
|
{
|
||||||
Emit();
|
Emit();
|
||||||
return default(JobHandle);
|
return default(JobHandle);
|
||||||
|
|
|
@ -62,7 +62,7 @@ namespace GamecraftModdingAPI.Input
|
||||||
playerID = inputEngine.GetLocalPlayerID();
|
playerID = inputEngine.GetLocalPlayerID();
|
||||||
}
|
}
|
||||||
ref InputEntityStruct currentInput = ref inputEngine.GetInputRef(playerID);
|
ref InputEntityStruct currentInput = ref inputEngine.GetInputRef(playerID);
|
||||||
Utility.Logging.CommandLog($"Current sim frame {currentInput.frame}");
|
//Utility.Logging.CommandLog($"Current sim frame {currentInput.frame}");
|
||||||
// set inputs
|
// set inputs
|
||||||
switch(hotbar)
|
switch(hotbar)
|
||||||
{
|
{
|
||||||
|
@ -114,7 +114,7 @@ namespace GamecraftModdingAPI.Input
|
||||||
playerID = inputEngine.GetLocalPlayerID();
|
playerID = inputEngine.GetLocalPlayerID();
|
||||||
}
|
}
|
||||||
ref InputEntityStruct currentInput = ref inputEngine.GetInputRef(playerID);
|
ref InputEntityStruct currentInput = ref inputEngine.GetInputRef(playerID);
|
||||||
Utility.Logging.CommandLog($"Current sim frame {currentInput.frame}");
|
//Utility.Logging.CommandLog($"Current sim frame {currentInput.frame}");
|
||||||
// set inputs
|
// set inputs
|
||||||
if (toggleMode) currentInput.actionMask |= RobocraftX.Common.Input.ActionInput.ToggleSimulation;
|
if (toggleMode) currentInput.actionMask |= RobocraftX.Common.Input.ActionInput.ToggleSimulation;
|
||||||
if (forward) currentInput.actionMask |= RobocraftX.Common.Input.ActionInput.Forward;
|
if (forward) currentInput.actionMask |= RobocraftX.Common.Input.ActionInput.Forward;
|
||||||
|
|
|
@ -31,12 +31,12 @@ namespace GamecraftModdingAPI.Utility
|
||||||
|
|
||||||
public bool IsBuildMode()
|
public bool IsBuildMode()
|
||||||
{
|
{
|
||||||
return _isInGame && SimModeUtil.IsBuildMode(entitiesDB);
|
return _isInGame && TimeRunningModeUtil.IsTimeStoppedMode(entitiesDB);
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool IsSimulationMode()
|
public bool IsSimulationMode()
|
||||||
{
|
{
|
||||||
return _isInGame && SimModeUtil.IsSimulationMode(entitiesDB);
|
return _isInGame && TimeRunningModeUtil.IsTimeRunningMode(entitiesDB);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue