Page 1 of 3

OLD: TrainSim Helper (Joystick/Overlay) release thread

Unread postPosted: Wed Oct 01, 2014 7:06 pm
by Havner
Just FYI:

I've released a small utility that displays an UI replacement for the F5 view with more info and can handle Joysticks/Throttles to control the loco. It can handle:
CombinedThrottle, Throttle, TrainBrake, DynamicBrake, LocoBrake, AFB. Even on scripted locos (where Joystick RailDriver interface fails).

The release thread with more information is here:
http://forums.uktrainsim.com/viewtopic. ... 1&t=139304

Make sure to read the documentation as it's not straightforward to configure because of the way it works.

Update: Version 0.6d released

Distance indicator:
http://forums.uktrainsim.com/viewtopic. ... 7#p1723307

Download:
http://vega.livecd.pl/~havner/trainsim-helper/

Changelog:
Code: Select all
0.6d
 - FEF-3 support. Not all controls are in the HUD simply because there
   is too many of them, but all that are used during normal startup,
   firing and driving are.
 - Separate Blowers for J94
 - Experimental green speed indicator when speed is up to 5 units
   (mph/kph) below the speed limit.

0.6
 - WARNING: some of my internal configurations have changed a little.
   If you rely on them have a look in the locoss sections.
 - Made an optiom for the program to treat driving backwards as forwards
   (Shift-Alt-S). Very usefull for some locos/scenarios where you have to
   drive backwards for longer periods of time.
 - New axes for the joystick: Small Ejector, HandBrake, Blower, Damper.
   Very usefull for 3rd party realistic locos (e.g. VictoryWorks).
 - Big optimization in the LUA overlay code. Don't check for existance
   of ControlValues per iteration. Check this info only once on loco
   initialization.
 - Inclusion of DataExtractor. New version, integrated in the main
   package. Thanks CobraOne.
 - Separate units detection for brakes. Now a loco displays properly
   BAR/PSI if it has brakes that use both.
 - SteamHeating indicator.
 - Detections and notches configurations for more locos I bought recently.
 - Cleanups in my own configs, they wont take precedence over axes set
   explicitly. ReplaceControls() function for this. They are grouped
   under "Havner's config" comments.

0.5
 - WARNING: keyboard shortcuts got changed again due to steamers addition
 - Support for steamers, see the readme
 - Detection script will notify what loco has been detected
 - Detections and notches configurations for MANY more locos (ALL I own)
 - Handbrake indicator, better CruiseControl/AFB indicator
 - CruiseControl axis for locos other then German AFB
 - Separate Loco and Train brakes indicators (some locos use both)

0.4
 - WARNING: the keyboard shortcuts (F1-F9) got changed again due
   to the addition of Distance and a change with TargetSpeed
 - WARNING: the modifier for ALL the shortcuts got changed to
   SHIFT-ALT due to collisions with TS shortcuts (adv. brakes)
 - Distance/Countdown implementation, see the readme
 - Moved the TargetSpeed to the controls (blue) section
 - Made it possible to use the Patcher without TS registry entries
   and custom named RailWorks folder
 - Handle the windowed mode case, move together with TS window
 - Removed numbers formatting in lua for some variables, pass the full float/double
 - Detections and notches configurations for more locos
 - Minor code changes

0.3
 - WARNING: the script has been split into 3 files, you need all
  - Overlay configuration is in the trainsim-helper-overlay.lua
  - Joystick configuration is in the trainsim-helper-joystick.lua
  - Detections for locos are in the trainsim-helper.lua
 - WARNING: ALL ControlRanges are detected before Locos detections
  - This allows for less code in the detection routines
 - GearControl axis added (Gear Lever)
 - Gear in the Overlay moved to the controls group (blue)
  - WARNING: Because of this shortcuts got shifted by 1 (F1-F9, F11-F12)
 - Vacuum Pipe added to the Overlay (red), Vacuum Chamber ignored (seems irrelevant)
 - Moved the clock to align better with long scenario names and F5 UI
 - Overlay GradientUK format option (1:XXX) (mostly autodetected for UK)
 - Fixed gigantic speed limits for SpeedLimitType == 3 (now it's '??')
 - Add units to acceleration, recalculate from m/s^2 (Kph/m, Mph/m)
 - Moved most of the calculations to C++ for performance and greater control
 - Readme updated (TOC and section on how to receive help)
 - Detections and notches configurations for more locos
 - Source code from now is on github:
  - https://github.com/Havner/trainsim-helper

0.2a
 - Added M8Brake to the list of controllable TrainBrakes
 - Fix for the patcher to handle very old locos that don't provide Initialise()
 - Fix for the patcher in case there are already 2 scripts named the same but one .lua, one .out
 - Detections and notches configurations for more locos

0.2
 - Next speed limit + distance
 - Keyboard shortcuts for turning off the whole overlay or just parts of it
 - Command line switches to disable joystick support completely
 - Command line switches to turn off the overlay or just parts of it
 - Notched levers support (needs to be configured manually per loco)
 - An option to redefine warning strings
 - Patcher template updated to pass frame interval for future use
 - More examples in the code for the new functions
 - Internal code changes
 - Docs updated, changelog and todo added

0.1a
 - Changed the BRs in the readme to be readable in notepad
 - Fixed BAR/PSI display for some locos
 - Added Reverser control

0.1
 - initial release


Image
Image
Image

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Thu Oct 02, 2014 12:36 pm
by _o_OOOO_oo-Kanawha
Awesome. Thanks.

Downloading now.

Will you provide support here or is it best to post on UKTS' board, where your main thread is?

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Thu Oct 02, 2014 1:38 pm
by plethaus
Brilliant, thank you :) You even put the speed and speed limit in.. that's great.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Thu Oct 02, 2014 5:42 pm
by Havner
_o_OOOO_oo-Kanawha wrote:Will you provide support here or is it best to post on UKTS' board, where your main thread is?


Yes, I will try. But the latency here might be higher as I'm still on trial and my posts are moderated.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Thu Oct 02, 2014 6:53 pm
by artimrj
Nope your free now, that was your second post to prove your a person. Welcome aboard.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Thu Oct 02, 2014 7:12 pm
by Havner
artimrj wrote:Nope your free now, that was your second post to prove your a person. Welcome aboard.


Thank you, makes me wonder whether I've chosen a wrong forum to post this to :D (as I like both, UK & US rails). It took me around 25 posts and a desperate message to moderators there to be taken out of trial and remove the ~20h latency in posting.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Thu Oct 02, 2014 10:00 pm
by Chacal
This is great work.
I especially like the possibility of making a custom display.
I would love to see only the gauges on the screen: air brakes, speed, ammeter.
Even better, I would put them in a different window on one of my secondary monitors.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Fri Oct 03, 2014 2:37 am
by Havner
I've been pointed out that I uploaded the readme file with not windows compatible break lines. Notepad can't handle this. Any better editor can (notepad++). I've uploaded 0.1a with the readme fixed, so if you had problems reading it it should be ok now.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Fri Oct 03, 2014 9:46 pm
by NYWhiskey
Hi Havner, that's a great program. Thank you so much. I have never used a controller for Train Sim but I always wanted to try, no better time than the present. *!twisted!*

I have a problem though. In step 4 it says "Now open the trainsim-helper.lua. This has to be done in a good text editor". I can only find the trainsim-helper-engine-template. lua file. All the others are out files. Where does the lua file I need to edit reside? I am using Notepad++.

Thanks again,

Rich

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Fri Oct 03, 2014 10:04 pm
by NYWhiskey
Sorry Havner, I found it. No problems at all!!! !!*ok*!!

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Sat Oct 04, 2014 4:02 am
by Havner
NYWhiskey wrote:Sorry Havner, I found it. No problems at all!!! !!*ok*!!

Glad to hear that :-)

I'm working on the next version. Already added:
- next speed limit + distance
- keyboard shortcuts for turning off the whole overlay or just parts of it (CTRL+SHIFT+F1-F12)
- command line switches to disable joystick support completely (no warning for no joysticks detected)
- command line switches to turn off the overlay or just parts of it (possible to override with shortcuts in runtime)

Working on notched levers now.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Sat Oct 04, 2014 1:19 pm
by Chacal
Havner wrote:- keyboard shortcuts for turning off the whole overlay or just parts of it (CTRL+SHIFT+F1-F12)


That should prevent any accidental activation except if you have a cat.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Sat Oct 04, 2014 5:09 pm
by Havner
Shameful bump for a new version released. Main post updated.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Sun Oct 05, 2014 9:46 am
by gwgardner
Looks great. Thanks for making it available.

Unfortunately I mostly run steam engines, and hope that someday you may see your way to including support for them.

Re: TrainSim Helper (Joystick/Overlay) released

Unread postPosted: Sun Oct 05, 2014 12:05 pm
by Havner
gwgardner wrote:Unfortunately I mostly run steam engines, and hope that someday you may see your way to including support for them.


Ok. After I get some pleasure from using my helper (instead of just writing it) I will try to implement steamers. But I need help with this.

1. What additional things should the overlay display? Injectors? Shoveling speed? Watering speed? I know very little about driving a steamer with manual fireman.
2. What additional things should it be possible to control with throttle? Things that are analogue. Meaning they are not togglable but you have a rotary, lever etc to control them.
3. And most importantly I need engine's .bin files for a few advanced steamers. I ony own few from EU locos pack and the Fowler from the Academy.

EDIT:

ad 3. by the engine .bin file I mean a file which is loco's/engine's main definition file. The one holding all the ControlValues
4. Also it would be great to have an input mapper file for a loco. So I can see what the author actually wanted the user to control (and how).