Downloading and configuring the C# IDE for the example template is the fourth step Overall Goals.
Download Rider or Visual Studio. If you prefer, you can also use a text editor, or a lightweight environment like Visual Studio Code.
Now, Open the project in your IDE or text editor. Do not worry if your IDE shows a lot of errors. They will disappear at the end of this section. There are a few steps to follow:
- Open the
In Rider, right click on the project and go under
Edit > Edit .csproj. Note that the image below is a sample image, and some information, particularly the name of the project, will not match with our Example mod project.
In Visual Studio Code, open up the
.csprojfile from the explorer view.
You can also navigate to the directory in which you cloned the git repository, and open the .csproj with a text editor.
If you can't find the
.csproj file, make sure you are in the right directory.
The project is organized in a nested structure. Here is an example directory
structure. Note that the exact name of the
.csproj file depends on what you
passed as the name to
dotnet new reactor -n when you created the project.
.└── ModExperiment ├── ModExperiment │ ├── ModExperiment.csproj │ └── TemplatePlugin.cs └── ModExperiment.sln
.csproj file, there are few important properties:
GamePlatformdefines game platform (
Itch), defaults to
GameVersiondefines which version of the game that the Reactor framework will download.
Descriptionshould be a description of your mod.
Authorsshould be the name of the author(s) of the mod.
<Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <TargetFramework>netstandard2.1</TargetFramework> <LangVersion>latest</LangVersion> <DebugType>embedded</DebugType> <VersionPrefix>1.0.0</VersionPrefix> <VersionSuffix>dev</VersionSuffix> <Description>Mod generated using Reactor.Template</Description> <!-- <Authors>your name</Authors> --> </PropertyGroup> <PropertyGroup> <GameVersion Condition="'$(GamePlatform)' == 'Steam'">2021.6.15s</GameVersion> <GameVersion Condition="'$(GamePlatform)' == 'Itch'">2021.6.15i</GameVersion> </PropertyGroup> <ItemGroup> <PackageReference Include="Reactor" Version="1.0.0-rc.1" /> <PackageReference Include="Reactor.MSBuild" Version="0.1.5" PrivateAssets="all" /> </ItemGroup> <Target Name="Copy" AfterTargets="Build" Condition="'$(AmongUs)' != ''"> <Copy SourceFiles="$(OutputPath)$(AssemblyName).dll" DestinationFolder="$(AmongUs)/BepInEx/plugins/" Condition="'$(Configuration)' == 'Debug'" /> </Target></Project>
If you still have any errors, you should refresh your IDE, and IDE should do this automatically. Otherwise, restart the IDE, and it will pick up the proper information from the project.