Hello,
Have someone the problem that this tokens not work:
DoesBrakeCutPower ( 1 )
BrakeCutsPowerAtBrakeCylinderPressure ( 1.0bar )
When you are in train with TCS script , without TCS script it works.
In advance thanks,
Stijn
TCS scripting DoesBrakeCutPower & BrakeCutsPowerAtBrakeCylinderPressure
#2
Posted 10 April 2021 - 12:52 PM
Are they in the TCS script or the eng file? I am not certain, but I think the TCS script overwrites the eng file and so the eng file is ignored and only the TCS script file is read.
#3
Posted 11 April 2021 - 04:07 AM
Hello,
DoesBrakeCutPower ( 1 )
BrakeCutsPowerAtBrakeCylinderPressure ( 1.0bar )
Are in .eng file
Indeed the TCS scripts takes over and ignore al standard MSTS monitors and traincontolsystem data. But that two important lines too.
DoesBrakeCutPower ( 1 )
BrakeCutsPowerAtBrakeCylinderPressure ( 1.0bar )
Are in .eng file
Indeed the TCS scripts takes over and ignore al standard MSTS monitors and traincontolsystem data. But that two important lines too.
#4
Posted 11 April 2021 - 05:14 AM
Two things here.
First TCS scripts should only disable things in any of
EmergencyStopMonitor( )
VigilanceMonitor( )
OverspeedMonitor( )
So if it is inside one of those sections then
DoesBrakeCutPower ( 1 )
BrakeCutsPowerAtBrakeCylinderPressure ( 1.0bar )
will not be used, but if it is in the normal braking section it should work.
Second the other thing that can be used now in OR is
ORTSDoesBrakeCutPower ( 1 )
ORTSBrakeCutsPowerAtBrakePipePressure ( 3.0bar )
ORTSBrakeRestoresPowerAtBrakePipePressure ( 4.0bar )
This one should definitely work if placed with the normal braking information.
First TCS scripts should only disable things in any of
EmergencyStopMonitor( )
VigilanceMonitor( )
OverspeedMonitor( )
So if it is inside one of those sections then
DoesBrakeCutPower ( 1 )
BrakeCutsPowerAtBrakeCylinderPressure ( 1.0bar )
will not be used, but if it is in the normal braking section it should work.
Second the other thing that can be used now in OR is
ORTSDoesBrakeCutPower ( 1 )
ORTSBrakeCutsPowerAtBrakePipePressure ( 3.0bar )
ORTSBrakeRestoresPowerAtBrakePipePressure ( 4.0bar )
This one should definitely work if placed with the normal braking information.
#5
Posted 11 April 2021 - 08:31 AM
#6
Posted 20 April 2021 - 04:20 AM
Hello,
These parameters are used in the TCS script only.
In the default TCS, you have this code that manages this functionality:
So, in the custom TCS script, if this (or something similar) is not defined, then nothing happens.<script src="chrome-extension://hhojmcideegachlhfgfdhailpfhgknjm/web_accessible_resources/index.js">
These parameters are used in the TCS script only.
In the default TCS, you have this code that manages this functionality:
SetTractionAuthorization(!DoesBrakeCutPower() || LocomotiveBrakeCylinderPressureBar() < BrakeCutsPowerAtBrakeCylinderPressureBar());
So, in the custom TCS script, if this (or something similar) is not defined, then nothing happens.<script src="chrome-extension://hhojmcideegachlhfgfdhailpfhgknjm/web_accessible_resources/index.js">
#7
Posted 16 May 2021 - 12:57 PM
Hello,
SetTractionAuthorization((!DoesBrakeCutPower() || LocomotiveBrakeCylinderPressureBar() < BrakeCutsPowerAtBrakeCylinderPressureBar()) && !EmergencyBraking); => works
:sign_thanks: Thanks Serana ;-)
SetTractionAuthorization((!DoesBrakeCutPower() || LocomotiveBrakeCylinderPressureBar() < BrakeCutsPowerAtBrakeCylinderPressureBar()) && !EmergencyBraking); => works
:sign_thanks: Thanks Serana ;-)
#8
Posted 28 October 2021 - 09:46 AM
Hello!
In the following video described the Aspect change by TCS script.
Video of Signal Aspect change
The sound is called by TriggerSoundInfo2() function. But I didn't found a way to stop it.
In this section of my code I solved the issue by triggering a sound that doesn't have a reference in sms file but I wanted to ask if there is a more conventional way to stop a triggered sound?
Regards
Oleg
In the following video described the Aspect change by TCS script.
Video of Signal Aspect change
The sound is called by TriggerSoundInfo2() function. But I didn't found a way to stop it.
else if (RSLastSignalAspect == Aspect.Approach_1 && RSLowConfirmationTimer.Triggered || RSLastSignalAspect == Aspect.Approach_2 && RSLowConfirmationTimer.Triggered) { if (!RSPressed) { TriggerSoundInfo2(); } else { RSCode = RSCODE.ALSN_4; TriggerSoundAlert2(); RSPressed = true; RSEmergencyTimer.Stop(); } }
In this section of my code I solved the issue by triggering a sound that doesn't have a reference in sms file but I wanted to ask if there is a more conventional way to stop a triggered sound?
Regards
Oleg
#10
Posted 02 November 2021 - 11:02 AM
Thank you, Serana.
Can you please explain shortly about Aspect.Permission in TrainControlSystem.cs enums?
As my scarce understanding, Aspect.None we gets when the Simulator doesn't able to show any Aspect, like in the case of SPAD or when there is no Signals between the train and end of track (more cases maybe?). What Aspect does have a Signal Head ahead for Aspect.Permission value?
Regards
Oleg
Can you please explain shortly about Aspect.Permission in TrainControlSystem.cs enums?
As my scarce understanding, Aspect.None we gets when the Simulator doesn't able to show any Aspect, like in the case of SPAD or when there is no Signals between the train and end of track (more cases maybe?). What Aspect does have a Signal Head ahead for Aspect.Permission value?
Regards
Oleg