Route Building in RailWorks|
Written by Geoff Potter [AcornComputer]
Date: 18 October 2009
Something that is not obvious to many newcomers to RailWorks is that in order to create your own content (scenery, locos, route templates, etc), you have to set up some folders on your own computer first where the raw information is placed before turning it into a format that RailWorks can understand.
Most people creating content already will be conversant with the way this is done and also the need to have a good knowledge of how Windows files and folders are manipulated and used. In order to create a route template you will not need to go into so much detail but you will need to have some knowledge of file and folder manipulation.
The folder where all the action takes place is the Source folder. This should be found in the RailWorks folder like this -
If you cannot see a source folder then RailWorks has not created one so you will need to do this yourself. Simply create a new folder in the RailWorks folder as per the above screenshot.
The next layer down in the source folder is where you will place your own developer folder. You will usually ever only have one developer folder which should have a unique name. This is a shot of the next layer down in my Source folder -
You can see that in addition to my Acorn folder, there are a few others which relate to some bespoke assets I have created for other people. If they had created their own assets then they would have their own source folders on only their computers. We are only interested in the Acorn folder at this stage. Within the Acorn folder, the set up looks like this -
Each one of the next folders represents the place where I have grouped my models and route templates for each route I have built or I am building. Some of you will now start to recognise the format here as when RailWorks transfers your raw information to the main program, it basically places the converted model/route template/etc in a similar folder format in the RailWorks/Assets folder. This is then found when you use the object set filter to set what assets from each developer that you want to use in a route.
You need to create your route folder here for this Challenge. Something like My_Route_Challenge but using your route name
Getting back to my Source/Acorn/Denby_to_Boxford folder, this is set up in a standard format of empty folders that match the range of assets that you might be transerring to RailWorks. The detailed set up is shown in the WIKI -
You do not need to worry about this at the moment though, but you will need to set up one folder which is the TemplateRoutes folder -
You can see the file path at the top of the window. It is important to note that folder and file names in your own folder should be in the format of Joined_By_An_Underscore or AllInOne format. The system will not work properly if you leave spaces between the words in the title.
This seems a good time for you to set up your own Source folder in this way. You will need to chose a name for yourself that is unique and likely to stay unique so that your assets do not clash with someone else who has chosen the same name as you. Check through your RailWorks/Asset folder to see what sort of names others have chosen.
When you have set up these folders, you now need to load up the Blueprint Editor from the front end of RailWorks -
Click on this button and the Blueprint editor will load - (Click on any image to see it bigger and clearer)
The file tree on the left is reading your source folder. You can see my folder reflected in the tree but you will only have the one file path. You now need to RIGHT click on the TemplateRoutes folder and chose a new route blueprint from the small window offered to you -
- and then click OK. This will bring up the actual Blueprint for you to fill in. The next shot shows what I filled in to the top half of the Blueprint for my route -
You will also need to fill in the same lines but with your details. Note that I have also renamed the Blueprint itself by right clicking on the file and renaming it to match my route. This is not essential and you could leave it with the name RailWorks gave it but it is up to you.
The next shot shows the lower half of the Blueprint which I have scrolled down to. I have only shown the Blueprint in two parts as I could not get all the detail in one screenshot.
You will see that the origin of the route is set in the top fields. I have chosen some arbitrary points somewhere in the South of England but if your route is based on a specific location, then those co-ordinates should be entered here with up to 10 decimal places (I think). I hope you can see the other entries in detail because you need to complete your Blueprint in EXACTLY the same way. This means that all wording should be the same, the slashes need to be facing in the same direction, the full stops should all be there, etc.
What you are doing is setting up the instructions to tell RailWorks where to get the information it needs to create your base route. These entries all refer to default Kuju files but the only other source of this type of information at the moment is the RSDL Island Line, terrain, weather and textures.
Those of you who are super clever, can create your own weather, terrain and texture files and refrence the Blueprint to those but that really is advanced stuff.
Having completed all the entries so that it all looks like my screenshot (only your route template name and Blueprint name will be different), hit the export button at the top and if all goes well you will get a report in the bottom window that tells you that there has been a successful build -
This screenshot shows what you are looking for. If you get this message then great, you have created your own route template, now hit the save button at the top which will save all of the details in case you need to create a new template.
If you do not get the successful build message, you should get a message indicating what the problem has been. Save the Blueprint anyway and try to fix whatever the problem is that has been indicated.
So what has happened? The source folder has done its job and if you now go to RailWorks/Assets/YourDeveloperName/YourRoute/TemplateRoutes you should see something like this -
These small files are your route templates.
Now fire up RailWorks and go the the route selection screen and click on New Route -
This then takes you to a screen where you choose which template you want to use to create you new route -
Find your new template, and click on it -
Type in the name of your route (as you want it to appear in the main route screen) and click on create. Now go back to the route selection screen and you will see your new route listed, click on it and run it. When it loads you will see something like this -
Looks bad, but all you need to do is open the object set filter and you will see that of all the developer assets avilable, only your box has been ticked. You now need go down the list and find Kuju and tick ONLY Rail Simulator and Rail Simulator US. You can also tick RSDL/Foliage and Castlerock/scenery. This will allow only the default RailWorks assets to be shown in your asset seletion list, if you wish to use other assets you can simply tick those as required.
Now exit the route -
The next time you run the route you should see the green terrain as well as the sky and your route is now ready to start building in.
You are now a developer for RailWorks with your own developer name and if you create more content for RailWorks then you will get it into the simulation from the source folder but using another type of Blueprint, depending on what you have created.
You can add your own route loading screen now if you wish at any time but if you wait a while I can put up some instructions for that as well.
Part Two: Creating a Loading Screen for your own Route Template
Having created a new route template in my Developer Folder for the Denby to Boxford Challenge Route, I now want to add a loading screen. I have not done this before from the Source folder and searching through both the Rail Simulator Developer Documents and the RailWorks WIKI, I could not find how to do this. It may be there but I could not find it.
A little study of the file format gave me a clue, however, and the answer lies in the route template blueprint that we used to create our route template in the first place, although the method is not at all obvious.
First we need to create our loading screen image. I normally use Paint Shop Pro for creating images and textures for models but I often use the free program DrawPlus for creating some texture sheets and also where there is a lot of vector work ... straight and curved lines, boxes, circles, etc. I have opened up DrawPlus and have drawn a rectangle of the size 27.10cm x 13.55cm which roughly equates to 1024 pixels to 512 pixels. I have stuck to my 'Corporate' style of black background and yellow lettering and created a basic loading screen like this -
I grouped all of the elements and saved the whole image as a .jpg file to my RailWorks\Source\Acorn\Denby_to_Boxford\TemplateRoutes folder. I named it Loading_Denby_to_Boxford as this is the usual format for a loading screen. I then opened up the image in the free painting program Paint.net and used the features of this program to make sure that image was exactly 1024 pixels x 512 pixels with a resolution of 600.
The image was saved and replaced the original image created in DrawPlus, but now with the new specification. The image now sitting in the source folder is ready to use. It now sits with the route template file that we used to create the route template in the first place. Note that you could create the screen entirely using Paint.net but I find DrawPlus to be an easier program to use.
We now need to convert the image into one that the asset editor can recognise for exporting to Railworks. We use the ToAce tool to do this. I have a copy of the ToAce convertor from RS days and I cannot see where it is in the RailWorks folder. It has to be there somewhere but to save time you can obtain a copy from the RS.com website Legacy Section here -
When you have installed this little program, run it and click on the top box above the word 'convert' and use the internal window to navigate to your RailWorks\Source\Acorn\Denby_to_Boxford\TemplateRoutes folder and click on the .jpg file that is your loading screen image and then click on open. This tells ToAce which file you want to convert. By default, the created .ace file will be placed in the same folder. The drop down box should be set to RGBA 32bit(V2 only) and the radio button should be checked 2 (RS).
Now click on the save button and a red message should come up to tell you that there has been a successful save.
Now close the ToAce window and open up yourRailWorks\Source\Acorn\Denby_to_Boxford\TemplateRoutes folder and you will see an .ace file has joined the group.
We are now ready to do some exporting. Open up the blueprint editor again -
and navigate to the Template Routes folder again -
You will now see that along with your route template you will have the two loading screen files. You just need to click on the route template file to bring up the blueprint which you saved when you had successfully exported the template in the last tutorial. This time, add in the path to your .ace file which in my case looks like this -
Do not alter anything else in the blueprint but make sure the path to the .ace file is correct and that the slashes are in the right direction. Now hit the export button and you should get the successful build message again. This means that you have now exported a new version of your template to the asset folder of RailWorks but this time it has an associated loading screen.
If you do not get a succseesful build message then there will be a maessage telling you what is wrong. Sometimes the image is not the right size, perhaps only 1 pixel out, so that would mean going back to your .jpg image, check the size again in Paint.net, save the image, create a new .ace file and try exporting again.
The way to check that you now have your own loading screen is to run your route and the screen should show. That screen is now only associated with that route.
You can change the image later if you wish by simply exporting the route template again with a new image associated with it.
I have used DrawPlus and Paint.net but you can use any program that can produce a .jpg .bmp or perhaps .tga file as ToAce can convert all of these into an .ace file ready for exporting.