Train Sim Safe House
Would you like to react to this message? Create an account in a few clicks or log in to continue.

W File Alignment Query

5 posters

Go down

W File Alignment Query Empty W File Alignment Query

Post  OldVern Mon 18 Feb 2019, 12:47 pm

Asked this question on TS dot com but no one seems to be awake over there yet, so thought I would pose it here:

It's only taken me 17 years to discover the World file editing process to ensure a platform or bridge is perfectly aligned with its associated track section. No more twiddling with the End, Ctrl etc. keys and mouse to find the Y axis has dipped one end under the terrain. Dodgy

However I do have one question if someone could indulge me - how do I further edit the file to rotate that object by a perfect 180 degrees - such as when positioning two separate single platforms with edge markings, either side of a double track straight?

OldVern

Posts : 102
Join date : 2016-10-07
Age : 62
Location : Swindon

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  slipperman12 Mon 18 Feb 2019, 3:11 pm

Hi Vern,
The only route-building I've done is one I started about 7 years ago, which is STILL on the 'back burner'!
I have no idea how to align a platform with its track, but I wonder if this from Michael Vone's Route Building Guide answers your question :

But if you need to turn an object by exactly 180° around the vertical axis (as for an already
correctly-aligned bridge or platform), you will have to edit the object's data in your route's world
tile files. Do this as follows:
- find the corresponding world tile file in your route's WORLD folder (see section 3.10.9);
- open that world tile file with WordPad and find the object in it (see section 3.10.9);
- modify the parameters in the QDirection line from
QDirection ( a b c d )
to
QDirection ( -c d a -b )
(this means: change the signs of the last two parameters, labeled c and d here, then move them
before the first two parameters);
- save the world tile file;
- reload your route in RE (without saving, but with the Advanced option to rebuild the track
database if the rotated object is a track or road section), and go to the object: it now should have
exactly the new orientation;
- shift it into place.
Cheers,
Ged


Intel i5 4690K (3.5GHz), Gigabyte GA-Z97P-D3 m/b, 12GB RAM, NVIDIA GTX 750ti (2GB), ASUS Xonar DS Sound Card, Win 10 Pro 64 bit.

slipperman12

Posts : 2401
Join date : 2013-01-29
Age : 81
Location : North Nottinghamshire

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  OldVern Mon 18 Feb 2019, 5:47 pm

Thanks Ged, in the meantime someone posted the response at TS - however they also stated TSRE has a built in alignment feature which I've been trying out and it is a very powerful tool, much easier and safer than hacking around in and editing the world file. In fact TSRE is a very good alternative to the MSTS RE though the track laying system where you only commit to the tdb when ready then can't do certain things with it afterwards is a bit daunting and confusing. However for scenery placement and possibly even terrain painting I can see huge potential. Only drawback is, seems to use far more system resources than the MSTS RE and had the fans on my laptop screaming a bit, so received a bit of a glare from SWMBO as she was trying to watch something on TV at the time!

OldVern

Posts : 102
Join date : 2016-10-07
Age : 62
Location : Swindon

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  terrycunliffe Mon 18 Feb 2019, 6:35 pm

Hi Vern,
In the past I've used a Utility called AlignUtil.exe
Although I can't in the life of me remember where I downloaded it from, and have tried to locate it without success, I've still got a copy of this on my HDD. Let me know by PM if you'd like me to send you a copy to try.

An excerpt from the README:-

"Object Alignment Utility.

Installation and removal.
What it does.
What it does not do.
Notes on operation.
Capture Options.
How to align a bridge to curved track example.
Built in error messages.

Installation and removal.

1 To install, copy AlignUtil.exe to a convenient folder on a local drive and run from there. To remove, just delete it. If you already have an earlier version of AlignUtil.exe, then overwrite the earlier version with this one.

2 The Utility has been developed and tested on Windows XP and requires .NET Framework 2.0 to operate. At the time of writing, you can find .NET Framework 2.0 at http://www.microsoft.com/downloads/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5&DisplayLang=en . If not, search Microsoft downloads for dotnetfx.exe. Please note that you not need to uninstall other versions of .Net Framework, except the beta testing prerelease versions of .NET Framework 2.0.

3 When the Utility is first run, a "AlignUtil.ini" is created in the same folder as AlignUtil.exe and stores the route World folder path and other settings. You can open/edit this in Notepad if you like, although not recommended. When removing the Utility, you may also delete this ini file.

What it does.

4 The Object Alignment Utility is a tool for MSTS route builders for accurately aligning objects relative to each other. The Utility is run at the same time and alongside Route Editor.

5 The idea is that you select a track, road or other object in Route Editor and capture its alignment as a reference. Next you select a second object, say a building, bridge or other object to be aligned parallel with the reference. The Utiliy copies the rotation settings of the reference to the object being aligned, making it parallel to the reference object.

6 The Utility can align one object at a time, several nearby ojects at a time, or alternatively all the objects on the tile in one go.

7 The object(s) to be aligned can be rotated to specified angles in relation to the reference. This feature was included to cover the following scenarios:

(a) When the reference and object fileshapes were originally constructed on different axes.

(b) When an object is to be aligned alongside a curved track or road. Note: The origin of the track is at one end, so alignment of an object part way along the track section requires a calculated adjustment."



terrycunliffe

Posts : 181
Join date : 2013-01-22
Age : 68
Location : NWE Land

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  slipperman12 Mon 18 Feb 2019, 7:44 pm

Hi Terry & Vern,
AlignUtil is available from the trainsim.com library as alignu.zip

Cheers,
Ged


Intel i5 4690K (3.5GHz), Gigabyte GA-Z97P-D3 m/b, 12GB RAM, NVIDIA GTX 750ti (2GB), ASUS Xonar DS Sound Card, Win 10 Pro 64 bit.

slipperman12

Posts : 2401
Join date : 2013-01-29
Age : 81
Location : North Nottinghamshire

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  OldVern Mon 18 Feb 2019, 9:09 pm

Thanks, I'll grab that as well though I'm still doing a caper of joy over the capabilities of TSRE. No more slightly misaligned platforms or bridges and should help with walls and fencing too. Essentially it gives us the power of the offset tool in DTG TS, to place parallel objects and presumably not just track either. If I want a line of houses aligned to the road I can align the first house, then copy and paste along.

OldVern

Posts : 102
Join date : 2016-10-07
Age : 62
Location : Swindon

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  Markh5682 Wed 20 Feb 2019, 1:23 am

Hi Vern.

You may be interested in these snap together walls and fences, they are very easy to place and snap together like track pieces, but can be rotated in any direction whilst still being anchored to the previous piece making them super easy to follow the terrain without having to use any utilities to align them..........

UKTS  File ID : 30804

W File Alignment Query VSQXnkG

Included in this set are :-

Wire fence 20m concrete post
Wire fence concrete end post
Wire fence 20m Wood post
Wire fence Wood end post
Brick wall 10m
Brick wall 20m
Stone wall 20m
Stone wall 40m
Low stone wall 20m
Low stone wall 40m

The stone walls have snow textures

Hope that helps OK


Mark
Markh5682
Markh5682

Posts : 2657
Join date : 2013-01-21
Age : 69
Location : Lancashire

https://www.youtube.com/user/markh5682

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  OldVern Wed 20 Feb 2019, 8:08 am

Thanks Mark, I'll grab those and add to the asset collection.

OldVern

Posts : 102
Join date : 2016-10-07
Age : 62
Location : Swindon

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  RIGFindlay Wed 20 Feb 2019, 4:05 pm

Thank you, everyone for a lot of very useful information.

There is also a snapable hawthorn hedge, which is useful: File ID 28825.

It is quite easy to make your own snapable objects. These are the notes I use, but I don't know where they came from.

1 The Snapable feature uses the Bounding Boxes which snap together.

2 This line should be paced after the ESD_Bounding_Box ( a b c d e f ) line, but before the final bracket.
ESD_Snapable ()

3 When the object is placed in MSTS its major, longest, axis must lie E-W, not N-S. That is, the first and fourth figures in the Bounding Box (a and d) must contain the major axis of the object. The object can, of course, be rotated once it has been placed.

5 Press X to make the next piece snap to the last piece. Press X again in order to rotate a piece. If the object’s origin is at one end, the object will rotate while holding the snapped position, e.g hedges, telephone poles with wires.

6 If the object’s origin is not at an end, the objects will be snapable, but they will not be able to be rotated.

7 If two dissimilar objects both have the snapable features, they can be snapped together, e.g. telephone pole with wires, and a telephone pole only.

Roderic

RIGFindlay

Posts : 420
Join date : 2014-02-06
Age : 82
Location : Bridport

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  RIGFindlay Thu 21 Feb 2019, 6:13 pm

I have tried AlignUtil. It works up to a point.

Two objects were aligned nicely.

Then a platform was beautifully aligned to the track, but it faced the wrong way.

A canopy was aligned, but at right angles to the track.

BACK UP YOUR ROUTE FOLDER BEFORE TRYING IT.

Good luck,

Roderic

RIGFindlay

Posts : 420
Join date : 2014-02-06
Age : 82
Location : Bridport

Back to top Go down

W File Alignment Query Empty Re: W File Alignment Query

Post  Sponsored content


Sponsored content


Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum