magicant / bve-autopilot

Bve trainsim 用自動運転車両プラグイン
GNU Lesser General Public License v2.1
21 stars 6 forks source link

Feature request: Coasting #93

Open Kenny-Hui opened 3 years ago

Kenny-Hui commented 3 years ago

On some older metro system, trains do not coast at its target speed. That means once it reaches the target speed. The train stops accelerating until the train falls below the minimum speed. (The minimum speed is different depending on track section. But usually 5-10km/h less than target speed) Can this be a feature, and minimum speed defined with beacon? Thanks! (Sorry if this got implemented already, I've read the wiki a few times but I still can't find it)

magicant commented 3 years ago

I'm not sure if this feature is so easy to implement...

Kenny-Hui commented 3 years ago

I have thought about this for a bit, my approach would be: Make a MinSpeed variable If the train is below the minimum speed, set MinSpeed to TargetSpeed (So the train accelerates to the Targetspeed) Then if Minspeed == TargetSpeed && CurrentVehicleSpeed >= TargetSpeed: Set Minspeed back to the minimum speed specified with beacon.

But I doubt that this approach would work here as there are many more safety system and features to consider