BepInEx Mods: Setup Plugin Files

From Astrea Wiki
(Redirected from BepInEx Mods: Setup Files)
Jump to navigation Jump to search

We created some useful Setup Files to configure your project before starting mod. In the AstreaBepInExModTemplate folder you will find a Setup.bat that use these python files:

  • RenameAstreaModProject.py
  • GetMainAstreaDLLs.py

You need just to install python before using it: https://www.python.org/downloads/ After that just execute Setup.bat file.

These python files use SetupSettings.cfg to setup. You have to edit this file using any text editor.

SetupSettings.cfg

[Game]
gameDirectory="PUT_YOUR_GAME_DIRECTORY_PATH_HERE"
[Project]
assemblyName=AstreaBepInExModTemplate
[DLLs]
Assembly-CSharp.dll
UnityEngine.CoreModule.dll
UnityEngine.dll
Unity.TextMeshPro.dll
Assembly-CSharp.dll

RenameAstreaModProject.py

This file will:

  • Edit your Plugins.cs, MyPluginsInfo.cs and all scripts localized in Patches folder changing all namespace using the assemblyName from SetupSettings.cfg.
  • In the MyPluginInfo.cs PLUGIN_GUID and PLUGIN_NAME will change keeping your company name and changing just thee namespace.
  • Change the name of your .csproj using the AssemblyName.
  • Edit your .csproj changing your <AssemblyName> and <Description> (you can change text inside <Description> tag with other description. )

GetMainAstreaDLLs.py

  • Every [DLLs] from SetupSettings.cfg will be copy/paste to your libs folder.
  • Your .csproj will be edited and all reference will be updated after copying using your libs folder as reference.


Go Back to Mods page: Mods