Community Forum

Spline CV translation via lua?

Forum Overview >> Scripting

Created10.06.2020 21:26

Shawn E Carter (ShawnDaGeek) 10.06.2020 21:26
First let me thank anyone who can help for your response"s".

I have made a simple loop for a train and am having issues with CV's exaggerating the Y value when i export for the shape file. Causing just unsightly bumps. I am hoping to iterate over the Spline CV's as with the setTerrainHeight script in the editor, but i can not find a call to setPosition or get the id of the CV as to setTranslation.

Is there a way to either get a spline CV id and set its y value, as i said, loop through the spline and set or move the CV's?

Colin Smith (WrinkleysRule) 11.06.2020 19:37
As far as I'm aware there is no setPosition for CV's, most people just use the pagedown key to place the CV at the correct height


I'm curious to know why you need to 'export the spline for the shape file' in the first place.

Shawn E Carter (ShawnDaGeek) 11.06.2020 20:28
Colin; thank you for the info, did not know i use the pagedown for that.

i was under the impression i would need to export the transform group with the spine in order to use it in default item? is this not the case?

Also thank you for the link to the docs, i have read them on many occasions - the pagedown sadly is not documented.

Colin Smith (WrinkleysRule) 11.06.2020 22:58
Sorry I tought it was in the docs, just checked and its not in the sdk keyboardShortcuts text file either, your best bet is to check out some of the traffic train vids on you tube as I believe spline shortcut keys are mentioned in some of them (can be any of the game variants FS11,13,15,17,19 shortcuts are the same for all)
The home and end keys also rotate the spline +/-10 degrees without affecting its rotation axis (which can be a problem when using the setTerrain by height script)

Sorry I must have misundestood, yes you do export it all into a seperate new trains folder --check how the base game trains folder is set up especially regarding level crossings

Note: Log in to post. Create a new account here.