
Only interact with that class using an AddComponent call inside a check, or your mod will not load when Object Explorer isn't installed. If you want to add support for your objects to Object Explorer, create a new class that calls ObjectExplorer.AddMappings() in Awake().If you have Object Explorer installed, it will print that object in the log.

You can also use trusty old `Debug.Log` for printing messages - but you can also provide an object for context.Use Object Explorer to find objects in the current scene and view/edit their values.The entire contents of the official modding wiki are also stored in Besiege/Besiege_data/Documentation. Use dnSpyEx to decompile it and read the code to understand what it does. This will make it fail to copy before you build, so it will build properly when you do close the game.īesiege code doesn't have documentation beyond the official APIs, but you can use it. if exist "$(ProjectDir).\.\\$(TargetFileName)" copy "$(TargetPath)" "$(ProjectDir).\.\\$(TargetFileName)".Copy the following into 'Pre-build event command line' (replace all occurences of ):.Go to Solution Explorer > (your project) > right click > Properties > Build Events.dll and then it won't rebuild properly until you change something. If you build the assembly while the game is still running, it will fail to copy the. NET Framework 3.5 in Windows features (search 'Turn Windows features on or off' in the Start menu). NET Framework 3.5 Development Toolsīesiege (for PC) runs on Unity 5.4.0f3, so install that. Use Visual Studio 2019 for coding with the following extras:
#Besiege mods list how to
(You can create mods without code, but they're no fun and I don't know how to use them, so they're getting skipped.)

createassembly compiled ĭo not use scripted assemblies! They are much more limited and way harder to debug.To create a mod, use these commands in the Besiege console (Ctrl + K):
