Modding:Setting up your Development Environment: Difference between revisions

From Vintage Story Wiki
add powershell script to set the environmet variable ty Fulgen
m (moved note for SuppressWindowsConsoleWindow to Visual Studio part)
(add powershell script to set the environmet variable ty Fulgen)
Line 48: Line 48:
=== Windows ===
=== Windows ===


Here you have two options to set the environment variable:
* Use this short PowerShell script. Open the ''Windows PowerShell'' Application and paste the following into it and hit ''ENTER''
<syntaxhighlight lang=shell>
[Environment]::SetEnvironmentVariable("VINTAGE_STORY", "$Env:AppData\Vintagestory", "User")
</syntaxhighlight>
Change <code>$Env:AppData\Vintagestory</code> if you used a custom installation path for your game.
* Follow these manual steps to set the Environment variable
Search in Windows search for <code>Edit the system environment variables</code> > <code>Environment Variables...</code> > User variables for USER > New > Add insert the Variable name: <code>VINTAGE_STORY</code> and add the path to your Vintage Story installation.
Search in Windows search for <code>Edit the system environment variables</code> > <code>Environment Variables...</code> > User variables for USER > New > Add insert the Variable name: <code>VINTAGE_STORY</code> and add the path to your Vintage Story installation.
[[File:Win env.png|400px|center|frameless|alt=Setup Windows environment variable]]
[[File:Win env.png|400px|center|frameless|alt=Setup Windows environment variable]]


For example, the default installation directory would be <code>C:\Users\<Userername>\AppData\Roaming\Vintagestory</code>, (replace <Username> with your username) if you are not sure where yours is type <code>%appdata%</code> into the URL field in the File Explorer and hit ENTER. It will take you to your AppData\Roaming folder where Vintage Story should be installed if you haven't changed the default installation location.
For example, the default installation directory would be <code>C:\Users\<Username>\AppData\Roaming\Vintagestory</code>, (replace <Username> with your username) if you are not sure where yours is type <code>%appdata%</code> into the URL field in the File Explorer and hit ENTER. It will take you to your AppData\Roaming folder where Vintage Story should be installed if you haven't changed the default installation location.


[[File:Win appdata.png|400px|frameless|center|alt=find the default installation path of vintage story]]
[[File:Win appdata.png|400px|frameless|center|alt=find the default installation path of vintage story]]
Confirmedusers, editor
19

edits