Skip to content

Initial Project Setup

lightyyt edited this page Jun 8, 2025 · 1 revision

How to set up your HumanoidAPI Project:

*Note: //... is a sign for the rest of the (Previous) code

1. Create a new .NET Project (Preferred: .NET 4.7.2 (net472) )

2. Include BepInEx and HumanoidAPI DLLs

Visual Studio: Right Click your C# Project (not the Solution), Add > Assembly Reference > Browse and select the DLL Locations

JetBrains Rider: Right Click your C# Project (not the Solution), Add > Reference > Add From and select the DLL Locations

(Default for R2Modman in Windows: %appdata%\r2modmanPlus-local\HumanFallFlat\profiles\Default\BepInEx)

3. Set up your BepInEx Project Example:

namespace MyHumanoidAPIPlugin;

[BepInPlugin("com.myPlugin.me", "myHumanoidAPIPlugin", "1.0.0")]
public class MyHumanoidApiPlugin : BaseUnityPlugin {

    //BepInEx Logger
    internal new static ManualLogSource Logger;

    private void Awake() {
        Logger = base.Logger;
        Logger.LogInfo($"My Plugin is loaded!");
    }
}

4. Include HumanoidAPI as a Dependency

using HumanoidAPI;

namespace MyHumanoidAPIPlugin;

[BepInPlugin("com.myPlugin.me", "myHumanoidAPIPlugin", "1.0.0")]
[BepInDependency(HumanoidAPIInfo.PluginGuid)] //<- Add this line
public class MyHumanoidApiPlugin : BaseUnityPlugin {
//...

5. Set up your Plugin as a detected HumanoidAPI Plugin

    //...
    private void Awake(){
        HAPI.InitPlugin("com.myPlugin.me", "1.2.0"); //Your Plugin GUID 
        // (e.g. com.myPlugin.me) and the HAPI version your are using (e.g. 1.2.0)
    //...
    }

6. Done!

How to find your current HumanoidAPI version:

1. Start Human Fall Flat

2. Go to the main Menu

3. Look at the bottom right of the Screen

Clone this wiki locally