CommonAPI
FOR PLUGIN MAKERS - General purpose library to make modding certain aspects of the game easier. Custom save data, phone apps, interactables and more!
Date uploaded | 10 months ago |
Version | 1.2.3 |
Download link | LazyDuchess-CommonAPI-1.2.3.zip |
Downloads | 19648 |
Dependency string | LazyDuchess-CommonAPI-1.2.3 |
This mod requires the following mods to function
BepInEx-BepInExPack
BepInEx pack for Mono Unity games. Preconfigured and ready to use.
Preferred version: 5.4.2100README
CommonAPI
CommonAPI is a general purpose plugin library for Bomb Rush Cyberfunk, which allows modders to do a variety of things more easily.
CommonAPI was used in the Millenium Winterland SlopCrew event to drive the NPCs, cutscenes and progress saving. It was also used to pull the character shaders from the game, to make the NPCs look as accurate as possible to the other characters in the game.
Features
- Easy access to BRC shaders - Simply call
AssetAPI.GetShader(ShaderNames shaderName)
to retrieve a character or environment shader. - Dialogue and Interaction systems - Create any interactable entity, such as an NPC, that can react to a button prompt from the player. Create custom sequences and dialogues completely in C# without touching the Unity Editor.
- Custom save data - Easily create custom save data attached to individual save slots, CommonAPI takes care of automatically loading and saving, with multithreaded file writing.
- Phone apps - Easily create a custom phone app with an user interface with buttons you can scroll through.
Examples
Check out the CommonAPI Sample Project, it showcases how to create a custom app and custom save data.
Building
Make sure you have a BRCPath
environment variable defined on your system, which points to the root folder of your Bomb Rush Cyberfunk installation. This way the project can find the required DLLs.
Usage
Do NOT bundle this assembly with your plugins - Simply add it as a reference in your projects and utilize the dependencies
section in your plugin's manifest.json
to add CommonAPI as a dependency, and do the same with the [BepInDependency]
attribute in your BepInEx plugin class.
CHANGELOG
1.3.1
- Fix a bug where phone buttons would erroneusly press seemingly at random.
1.3.0
- Fix bugs when emptying ScrollViews.
- Now writes backups for save files.
- When a save fails to load CommonAPI will try to load a backup. If the backup fails to load as well, the save will start clean.
1.2.3
- Fix crashes with empty ScrollViews.
1.2.2
- Fix save data loading too late.
1.2.1
- Quick fix for absolute custom save data location not working as intended.
1.2.0
- Removing buttons from a phone scrollview now always destroys their GameObjects fully.
- Can now pick location for custom save data - By default it now saves to the users Documents folder under "Documents/Bomb Rush Cyberfunk Modding" rather than in the BepInEx config. This can be set to any location.
- Fixed phone-related crash.
1.1.0
- Initial public release.