Compare commits

..

No commits in common. "a836a0e43874ef30c56832bd411526d9ec4f518f" and "7f3388b24a1a0953cab8f2829d219b40e87b729b" have entirely different histories.

3 changed files with 11 additions and 16 deletions

View file

@ -346,12 +346,13 @@ namespace OpenbveFcmbTrainPlugin
} }
// Panel indicators // Panel indicators
train.Panel[11] = TrackState > TrackStates.Unprotected && train.PhysicalHandles.Reverser == 1 ? 1 : 0; train.Panel[25] = DeviceState == DeviceStates.Override ? 1 : 0;
train.Panel[12] = AtcControlState == AtcControlStates.NoPower || AtcControlState == AtcControlStates.NoPowerAlarm ? 1 : 0; train.Panel[26] = DeviceState == DeviceStates.YARD ? 1 : 0;
train.Panel[13] = (int)DeviceState; train.Panel[27] = DeviceState == DeviceStates.ATP ? 1 : 0;
train.Panel[14] = (int)CurrentSpeedCode.CurrentLimit.KilometersPerHour * 1000; train.Panel[28] = DeviceState == DeviceStates.ATO ? 1 : 0;
train.Panel[15] = (int)CurrentSpeedCode.TargetLimit.KilometersPerHour * 1000; train.Panel[34] = (int)CurrentSpeedCode.CurrentLimit.KilometersPerHour * 1000;
train.Panel[16] = (int)DeviceState > 1 ? 1 : 0; train.Panel[33] = 1;
train.Panel[35] = (int)CurrentSpeedCode.TargetLimit.KilometersPerHour * 1000;
// Play alarm sound // Play alarm sound
if (AtcControlState == AtcControlStates.NoPowerAlarm) if (AtcControlState == AtcControlStates.NoPowerAlarm)

View file

@ -39,8 +39,8 @@ namespace OpenbveFcmbTrainPlugin
} }
// Update panel variables for door selection state // Update panel variables for door selection state
train.Panel[1] = (RequestedDoorInterlock == DoorInterlockStates.Left || RequestedDoorInterlock == DoorInterlockStates.Unlocked) || (((train.DoorState & DoorStates.Left) != 0) && !LeftDoorsClosing) ? 1 : 0; train.Panel[50] = (RequestedDoorInterlock == DoorInterlockStates.Left || RequestedDoorInterlock == DoorInterlockStates.Unlocked) || (((train.DoorState & DoorStates.Left) != 0) && !LeftDoorsClosing) ? 1 : 0;
train.Panel[2] = (RequestedDoorInterlock == DoorInterlockStates.Right || RequestedDoorInterlock == DoorInterlockStates.Unlocked) || (((train.DoorState & DoorStates.Right) != 0) && !RightDoorsClosing) ? 1 : 0; train.Panel[51] = (RequestedDoorInterlock == DoorInterlockStates.Right || RequestedDoorInterlock == DoorInterlockStates.Unlocked) || (((train.DoorState & DoorStates.Right) != 0) && !RightDoorsClosing) ? 1 : 0;
} }
/// <summary>Is called when the state of a key changes.</summary> /// <summary>Is called when the state of a key changes.</summary>

View file

@ -175,10 +175,7 @@ namespace OpenbveFcmbTrainPlugin
switch (Key) switch (Key)
{ {
case "enabled": case "enabled":
if (!PluginSettings.AtcDimetronicDeviceEnabled)
{
PluginSettings.AtcBombardierDeviceEnabled = string.Compare(Value, "false", StringComparison.OrdinalIgnoreCase) != 0; PluginSettings.AtcBombardierDeviceEnabled = string.Compare(Value, "false", StringComparison.OrdinalIgnoreCase) != 0;
}
break; break;
case "initializationtime": case "initializationtime":
{ {
@ -218,10 +215,7 @@ namespace OpenbveFcmbTrainPlugin
switch (Key) switch (Key)
{ {
case "enabled": case "enabled":
if (!PluginSettings.AtcBombardierDeviceEnabled)
{
PluginSettings.AtcDimetronicDeviceEnabled = string.Compare(Value, "false", StringComparison.OrdinalIgnoreCase) != 0; PluginSettings.AtcDimetronicDeviceEnabled = string.Compare(Value, "false", StringComparison.OrdinalIgnoreCase) != 0;
}
break; break;
case "yardspeedlimit": case "yardspeedlimit":
{ {