Power Tools Developer v1.0 – FS22

FS22 Other

Power Tools Developer v1.0 – FS22

Power Tools: Developer is a quality-of-life mod for modders that works well alongside Power Tools, Easy Dev Controls and Global Explorer.

An improved style of visualizing in-game tables, together with the possibility to save tables to well-formed Lua files, opens up a new way of understanding the FS object model!

FEATURES:
– New console commands to restart the game (see below for details)
– Console command to print Lua table contents to either the console/log or a separate file
– Console command to clear the log file

CONSOLE COMMANDS:
– dtRestart (or ‘r’): Restarts the current savegame using a soft restart (slightly faster than a hard reset)
– dtRestartHard (or ‘rr’): Performs a hard reset (this will ensure everyhing is unloaded from memory)
– dtTable: Prints the contents of a Lua table to the console/log
– dtSaveTable: Save the contents of a Lua table to a file (3-4x times faster than printing a table to the log)
– dtVisualizeTable [beta]: An improved way of printing tables to the log, both faster, more memory efficient and visually improved.
– dtClearLog (or ‘cls’): Clears the log.txt file to get a fresh log (especially useful when using the restart command)

CAUTION!
The console commands to restart the game will do this -without- asking you to save your progress first. I.e. you risk losing progress if you are not cautious!

SAVING TABLES
The ‘dtSaveTable’ allows you to quickly dump a Lua table to disk in a well-formatted Lua file, meaning you can load this file as a source file in the Lua interpreter or in-game. This has several use cases, especially to understand the FS object model.

Optionally you can choose the depth of the output, especially important when saving top level tables (e.g. g_currentMission) that may contain many child tabled and/or large tables. Thanks to a well optimized code it is still possible to save g_currentMission with some 5-6 levels of depth before the Lua engine starts to leak memory and becomes unstable (the default depth is set to 2).

Example:
To dump the g_currentMission table to a file you could use the command ‘dtSaveTable g_currentMission currentMission.lua 1’. This would export the g_currentMission table to a file named ‘currentMission.lua’ and only include the direct descendants of g_currentMission.

Note: due to security restrictions, the generated .lua file will be stored in your ‘My GamesFarmingSimulator2022modSettingsFS22_000_DevTools’ folder.

PRINTING TABLES
Similar to ‘dtSaveTable’, the command ‘dtTable’ can be used to output a table to the log. It takes the table name as mandatory parameter and the maxDepth as an optional parameter (with a default value of 2).

Important! Due to the nature of how FS prints to the log it is only recommended for fairly small tables and/or shallow structures (depth should not exceed 2-3). E.g. printing g_currentMission to the console with a depth of 4 will make FS consume some 10-15GB of system ram and then crash in an out-of-memory error.

If you need to print a deeper structure it is recommended to use ‘dtSaveTable’.


Credits: w33zl
(3 votes, average: 5.00 out of 5)
Loading...

This content was uploaded by website visitors. If you notice any mistake, please let us know.

FS25 Mods

If you are face difficulties which are hard to overcome, check our Farming Simulator Mods database and you will probably find a solution there. There additional files are extremely popular all around the globe. That’s definitely for a reason – every single Farming Simulator 19 Mod / Farming Simulator 22 Mod is unique and provides you explicit options. If you wonder how it works, you will find plenty of information in our FS19 Mods / FS22 Mods website – we have collected all kind of data to make the gaming easier. If you are passionate about the Farming Simulator 19 Mods / Farming Simulator 22 Mods as we are, then you are on the right site. Take a deeper look at our offered samples and pick the needed one. Then all you need to do is simply click on LS19 Mods / LS22 Mods free download button and implement it to your game. This few simple steps will lift your game to the upper level – what can be better that upgrading your game personally? Break all boundaries and develop your farm easily. These additional files will add so much value that you won’t want to play without them anymore. There is no risk, so no arguments against – therefore the are no excuses of not taking this special chance. It’s amazing how much a simple update can do – be the smart player and achieve much more than you were ever planning. It’s great getting even more than it was expected – that’s why we insist on you to try and test the benefits personally. That could be a great boost to your farm and there are no reasons why to react negatively. Take the best that you can and don’t look back – you must be orientated to the future and new experiences. That’s the only way to stay ahead of everything. If you see it as your goals, it’s definitely now or never!



Useful Information:
- Do you need any help? Join Our FS Group
- How to install Farming Simulator 19 Mods
- Farming Simulator 19 Release Date
- How to Create Farming Simulator 19 Mods
- Farming Simulator 19 System Requirements
- Farming Simulator 19 Mods on Consoles
- Download Farming Simulator 19 Game
- Landwirtschafts Simulator 19 mods

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *