Następne podsumowanie tygodnia pojawi się 16.11.2024 | The next summary of the week will be published on 16.11.2024
-
Posts
15 -
Joined
-
Last visited
-
Days Won
1
-
Missing pages in Simrail Wiki
s0n1c replied to Glendathu's topic in General Discussion [Singleplayer]
Hello, all functions that you mentioned here will be added in next patch, so just for now they are private on wiki to don't mislead players. -
Aby zacząć tworzenie scenariuszy polecam na zapoznanie się z tymi poradnikami które pomogą na poprawne ustawienie środowiska w którym będziemy je pisać oraz przedstawią teorie względem plików zawartych w każdym scenariuszu: https://wiki.simrail.eu/LUA/LUA-Introduction - jak skonfigurować środowisko https://wiki.simrail.eu/LUA/developer-tools - objaśnienie developer menu i jak włączyć developer mode w scenariuszu https://wiki.simrail.eu/LUA/first-scenario - ogólne objaśnienie pomagające stworzyć swój pierwszy scenariusz Cała reszta od funkcji do struktur która przyda się w następnych krokach jest zawarta w tej sekcji forum: https://wiki.simrail.eu/en/LUA/Overview
-
How can you let things happen at certain times/places in an LUA scenario?
s0n1c replied to jeroezie's topic in LUA Scripting
It is not necessary to create method like UnconditialCheck but it helps a lot, and make code little bit cleaner. I mean function UnconditialCheck(e) return true end and check = function (trainset) return true end gives the same result. This is pretty much what you need, at the moment Virtual Dispatcher can take a while during game loading. All commands executed before this OnVirtualDispatcherReady call are going nowhere. Also it is mentioned in First LUA Scenario guide I really recommend to read it to get more into LUA scripting in SimRail. -
They are loaded automatically from Locales folder, but the problem you have is basically what i have mentioned here. You are missing default language file which is en.lang. Make sure all language files should have the same structure, that means your key Cango should be in both pl.lang and en.lang files.
-
To make this possible you should use DisplayMessage_Formatted function, where {x} is replacement for your GetUsername function. For example key in locales should look like: Message=Welcome {0} in this scenario and the code with DisplayMessage_Formatted: DisplayMessage_Formatted("Message", 10, GetUsername()) Replacements in key should be defined in range from 0 to 4, that means you have limit of 5 replacements for 1 key.
-
Hello You have to set key in your specific language file in Locales folder. So for example for polish it will be pl.lang with key like this HelloMessage=Your text And then use it in DisplayMessage function like this DisplayMessage("HelloMessage") Remember that you also need the main en.lang file if your scenario doesn't support all languages available in SimRail, then it will be used as default language file. More information about file structure you can find here.
-
Hello! Official LUA Scenario Scripting Documentation is here! We are really happy to announce official documentation. Feel free to ask anything about LUA Scripting Scenario in this topic, we are open at new suggestions, changes or fixes. Some things are still in development. Documentation is available here. === CHANGELOG === 10.05.2024 - First release.
-
An image in the official Dispatching manual is misquoted
s0n1c replied to KagurazakaYukari's topic in Issues archive
Thanks for reporting. Now it should be correct. 😄 -
Po zakupie gry w sklepie Steam należy się wylogować oraz ponownie zalogować na forum aby automatycznie zostać przydzielonym do odpowiedniej grupy. After purchasing a game from the Steam store, you must log out and log back into the forum to be automatically assigned to the appropriate group.
-
Mapa jest aktualnie dostępna jedynie z poziomu przeglądarki jako strona internetowa. Aktualnie nie jest planowane dodanie jej bezpośrednio do SimRail'a, lecz nie jest to wykluczone.