Seeing a lot of people saying the editor is using unreal engine 4 but there are 28 different versions from version 4.0.1 to 4.27.0 which will be the right one to use?
TSW will have it's own version, downloadable via the Epic Store. It's based on 4.26 which is what a few of us have been playing around with for mesh imports, etc. But it's so close to release you might as well wait for the real thing now.
The editor is based on version 4.26 but it is completely custom. You don't need to download Unreal Engine 4 itself first. Just download the Train Sim World PC Editor from the Epic Games Store, once it becomes available, and it will be the complete package.