The developer console is not just a powerful tool to gain immediate access to certain game variables and commands for power users, mappers, modders and so on.
It's also something your average user might want to have enabled for reporting bugs, taking screenshots (though the new photo edit mode is good for that as well) and for mod users who want to see if that new mod he installed has any issues. Errors will be shown in red in the console so you don't have to check your game log to know if the mod worked or not.
What do i need to do to enable it?
Don't worry, this isn't advanced at all. Just follow these 5 simple instructions.
1. Locate your Euro Truck Simulator 2 home directory and config file
The home directory is where all your settings, profiles, mods, save files and in game screenshots are stored.
You can find it in your "My Documents\Euro Truck Simulator 2" folder.
Fig 1. Your ETS 2 home directory with the config file to edit for developer console.
[ external image ]
2. Open the config file with Notepad
Right click the file, select "Open with" and pick "Notepad". (If "Notepad" doesn't show up in the list then click on "Choose default program..." and find Notepad in there. (Post in thread if this is unclear to you)
Fig 2. Open the config file with Notepad.
[ external image ]
3. Change two lines to enable developer console in game
The two lines you need to change are:
Code: Select all
uset g_developer "0" → Change the "0" to a "1"
uset g_console "0" → Change the "0" to a "1"
[ external image ]
4. Save the file
In Notepad, click on "File" → "Save".
Fig 4. Save the file.
[ external image ]
5. Run the game, open and close your console to ensure it works
Start the game, press the "~" key (console key) to open and close the console.
Due to the many many keyboard layouts in the world this key may not have a "~" character on it. Therefore, press the key that is depicted in Fig 5.
Fig 5. The console open/close key.
[ external image ]
ALL DONE, YOU HAVE SUCCESSFULLY ENABLED DEVELOPER CONSOLE IN ETS 2!
____________________________________________________________________________________________________
Now, what can one do with the developer console activated?
Hold on, before we start using the console. Let me tell you about the TAB key. (That is the key below the one you used to open the console with)
Using the tab key you can list all commands available in the console and it also serves as an "auto completion" key. If you type a partial command you can press tab and get suggestions for the commands that match your input so far. Or if there's only one command that matches so far, it will be completed for you which can be quite useful.
Bug reports
By pressing SHIFT+F11 your game will take a screenshot AND save the coordinates in the same folder as the config file (see Fig 1.) that you can then paste into your bug reports using CODE tags.
Here's an example set of coordinates...
Code: Select all
Nav issue ; [23/10/2013 20:18] (sec-0012-0011);-44831.8;112.729;-40232.4
Free roaming camera
By pressing the 0 (Zero) on the top row of numbers on your keyboard you enter the "developer camera" mode. This mode lets you (just like in photo editor mode) move your camera around the world freely.
Using the numpad (the collection of numbers on the far right of your keyboard) 8, 4, 5, 6 you can move Forwards, Sideways left, Backwards and Sideways right in the world.
Pressing 9 or 3 you can move up and down in the world.
Using your mouse you can look around.
This is useful for taking screenshots of your truck, especially when you have FXAA injectors active as the photo editor will not do so well with that.
But it's also useful when you need to get your truck out of a bind.
Say there's an AI glitch where the AI gets stuck at an intersection and refuses to move.
Entering developer camera mode you can look at where the traffic is stuck and you can also move the camera past that location, close to the road surface and pointing in the direction you want to be traveling.
Then by pressing F9 your truck (and trailer) will be teleported to that location. Thus saving you from having to restart the game.
Another possibility (for say video makers and people who want to show off cool stuff) for this teleport feature is that you can teleport as far away as you want.
If the camera is moving too slow for you then you can open the console and enter the following command...
Code: Select all
g_flyspeed X
So imagine you wanted to skip a job or just record you parking your trailer with some recording software. You can use the developer camera to fly over to the location of delivery and press F9 (making sure you are close to ground or your truck will fall) and save yourself the time of driving between locations to get a shot at recording.
Additionally, according to Rhythmosaur, SCS have added scroll wheel control of this fly speed. So by scrolling the mouse scroll wheel, you can change the flyspeed up and down by some amount instead of issuing a console command.
Finally, a related and very useful console command is the "goto" command.
Using the coordinates i presented above for the bug report you could type in... (Copy pasting with CTRL+C and CTRL+V also works btw)
Code: Select all
goto -44831.8;112.729;-40232.4
After 1.11.1 you can also issue the "goto" command with a city name. Such as...
Code: Select all
goto berlin
The developers are working on a fix for cities that contain non standard characters. (Going east cities for example, Łódź in Poland)
Simulation speed
A very nice feature is the "warp" console command.
It allows you to set the simulation speed of the game.
For example...
Code: Select all
warp 0.8
It no longer feels (in terms of real life) like you are taking a sharp highway turn at 115 kph.
One the other side of the spectrum, you can increase the warp speed to some high number and watch traffic flying by around you as well as seeing the sun and it's shadows move as if shot in stop motion mode. Cool (and time saving) effect for videos etc.
Set time
Don't like darkness? Running without lights because of performance reasons? Or maybe you want to advance time in game for some other reason?
There's a command for that too!
Code: Select all
g_set_time XX [YY]
For instance, if you want the time to be 1500 hours (3 pm) in the day then you use "g_set_time 15" and the time will advance to the specified time.
Likewise, if you want the time to be 0300 hours (3 am) in the night then you would use "g_set_time 3" and the time will advance to the specified time.
Using the optional second argument you can also set time with minutes. Such as "g_set_time 21 30" which would set the time to 9:30pm.
With special thanks to Moh1336 for the minutes argument.
Note that this will ALWAYS advance the time, if the time is 6 in the morning and you set the time to 5 in the morning then time will advance by 23 hours!
You cannot reverse time so be careful using this while you have a delivery to make.
Set weather
Did it just start to rain at the wrong time or are you tired of the sun? You can change the weather from sunlight to thunderstorm or from rain to sunlight in an instant.
Code: Select all
g_set_weather X f/i
The last f/i is how fast you want that weather to be applied. If you supply an "f" (forced) that means the weather will switch right away.
If however you supply an "i" (intermediate) then the weather will gradually change to what you selected. (approximately 20 minutes game time)
Currently (version 1.11.1) there's only two weather types but that may change in the future.
Show fps
Will show your current Frames Per Second in the game.
Code: Select all
g_minicon 1
g_fps 1
____________________________________________________________________________________________________
There are of course many more things one can do with the console, these where just a couple of highlights.