A dynamic text isn't possible in OMSI.
thats not true. you can easily develop a scrolling text in OMSI. even a pixel-perfect one.
I've checked your script and there are a few issues i found. Without checking the complete script, i can only evaluate the segment you posted. first of all, a value in OMSI isn't exactly zero or one at any time because OMSI is using floating point numbers. you should always use bigger > or smaller < operations instead of "=" while dealing with changing values, unless you put them in yourself. So you can do a 1 (S.L.YourVariable) and it will work just fine if you check the variable later with e.g. (L.L.YourVariable) 1 =. Everything thats a floating value like Timegap or your wheels roation or stuff like that will most likely never be zero or one. Also, try to rethink your script and check for logic errors. as an example, the following script wont work due to a few reasons:
(L.L.rtime) 0 >
(L.L.rtime) 2 < &&
(L.L.rtime) 0 =
(L.L.rlocation) 1000 >
first of all, if you check if rtime is bigger than zero and smaller than two, the next statement (L.L.rtime) 0 = will never be true because this scriptpart is only calculated if rtime is bigger than zero. Also, you forgot an && or || behind (L.L.rlocation) 1000 >, so (L.L.rtime) 0 = is ignored.
after that it seems like you try to step over the text by one space 100 times; so the text will scroll once every frame. this will technically work just fine. however, there are a few issues. lets say you only have 20 frames per second, this code is only executed 20 times a second; so for your two second counter, you can only step over the text 40 times. to get this to work, you need to call the macro every frame and you also need to set Refresh_Strings to 1 every frame. besides that, you never set your rtime counter back to zero; so the script would only work once and the counter would count up to infinity if you haven't set this variable back to zero somewhere else in the script.
I've modified your code in a way that it should scroll permanently exactly 100 times, so it will add 100 spaces behind the text and then it will start from the beginning as long as its called every frame. It will take 100 frames to do so.
To make this work more realistic, a few more steps would be needed. first, check the font settings in your model.cfg. there are settings to automatically center the font and stuff like that, make sure your settings fit your needs. Also,you have to compensate for the framerate using a timegap, not only for the counter itself. lets say the string moves over by 10 characters a second, you cant simply say "yeah, from 0 to 1 second, step over 10 times"; you would need to get the current frametime and check how far it should move over every frame. on a fast computer with like 200fps on grundorf, the script would take only half a second to complete. on a slower machine with 100 fps, it would take a second. for 50 fps, it would take two seconds and for 10 fps it would take 10 seconds. so on a slow machine with only 10 fps, the steps to move over would need to be bigger and you would need to add more spaces every frame.
so, in theory, you can make this work without any issues if you fix some problems here and there.
You should never use a string modification for scrolling a text. this will result in massive lags and it may cause other issues like blinking or invisible text, especially while using scripttextures. A much better solution - at least from a performance point of view - is to just animate the textbox itself horizontally. you could cut it in different pieces and hide/unhide them using scripts or you can hide the textbox with a transparent face and a bit of cheating using the rendering order.