Modding:Setting up your Development Environment: Difference between revisions

From Vintage Story Wiki
No edit summary
Line 70: Line 70:
Before doing anything else you have to setup your workspace. Just type in <code>setup</code> and it will automatically try to locate your VintageStory installation directory. If it cannot find it, you will be asked to type in the full path. Once you have entered your path, it will update your project files so you can start to work with it. Now open the project again and run your first test by hitting <code>start</code> [[File:VSMods10.png]]. If everything has been done correctly VintageStory should start.
Before doing anything else you have to setup your workspace. Just type in <code>setup</code> and it will automatically try to locate your VintageStory installation directory. If it cannot find it, you will be asked to type in the full path. Once you have entered your path, it will update your project files so you can start to work with it. Now open the project again and run your first test by hitting <code>start</code> [[File:VSMods10.png]]. If everything has been done correctly VintageStory should start.


= Project Setup (SRC) =
= Project Setup (ZIP) =


The source mod system lets you build mods that ship with source code that is compiled during run-time by the modloader engine. This has the great advantage of being open and easy to modify on the run but also comes with 2 major disadvantages. Up until game version 1.6.x you only have a hardcoded list of library references available to you (System.dll, System.Core.dll, System.Drawing.dll, System.Xml.dll, System.Net.Http.dll, VintagestoryAPI.dll, Newtonsoft.Json.dll, protobuf-net.dll, Tavis.JsonPatch.dll, cairo-sharp.dll), any other reference will not get loaded and thus your mod would fail to compile. The second major disadvantage, affecting all game versions, is that the inbuilt source code compiler can only compile code only up until C# 6.0, so newer language features are not supported. If either of these disadvantages are a showstopper to you, we advise you to build a compiled mod.
The source mod system lets you build mods that ship with source code that is compiled during run-time by the modloader engine. This has the great advantage of being open and easy to modify on the run but also comes with 2 major disadvantages. Up until game version 1.6.x you only have a hardcoded list of library references available to you (System.dll, System.Core.dll, System.Drawing.dll, System.Xml.dll, System.Net.Http.dll, VintagestoryAPI.dll, Newtonsoft.Json.dll, protobuf-net.dll, Tavis.JsonPatch.dll, cairo-sharp.dll), any other reference will not get loaded and thus your mod would fail to compile. The second major disadvantage, affecting all game versions, is that the inbuilt source code compiler can only compile code only up until C# 6.0, so newer language features are not supported. If either of these disadvantages are a showstopper to you, we advise you to build a compiled mod.
Confirmedusers, editor, Administrators
886

edits