HolloFox_TS-Extra_Assets_Library icon

Extra Assets Library

Extra Assets Library is a new tool to allow the injection of new assets into your game.

Last updated 2 months ago
Total downloads 370
Total rating 1 
Categories Networked Tools Integration Assets Minis
Dependency string HolloFox_TS-Extra_Assets_Library-1.0.4
Dependants 2 other mods depend on this mod

This mod requires the following mods to function

bbepisTaleSpire-BepInExPack-5.4.10 icon
bbepisTaleSpire-BepInExPack

Unified BepInEx all-in-one modding pack - plugin framework, detour library

Preferred version: 5.4.10
brcoding-SetInjectionFlagPlugin-2.3.0 icon
brcoding-SetInjectionFlagPlugin

Allows players to flag mods are installed

Preferred version: 2.3.0

README

Extra Assets Library

The Extra Assets Library is a plugin to register custom assets into TaleSpire.

Installing With R2ModMan

This package is designed specifically for R2ModMan and Talespire. You can install them via clicking on "Install with Mod Manager" or using the r2modman directly.

Installing Without R2ModMan (WIP)

You can still manually install this with the downloaded DLLs. Upon doing so, you'll need to configure the plugin manual by updating the config file.

Player Usage

Players will start to find all your minis within the UI Asset Browser with every other minis.

Writing Mods with this

Loading an asset in:

var asset = new ExtraAssetsLibrary.DTO.Asset
   {
    Kind = AssetDb.DbEntry.EntryKind.Creature, // Future can do tiles and props
    Id = ExtraAssetsLibrary.DTO.Asset.GenerateID($"some sort of unique constant string"),
    GroupName = "Pokemon Gen I",
    Description = "Eevee, the evolution poke...",
    Name = "Eevee",
    groupTagOrder = 2, //Index in group
    Icon = icon, //Sprite (128x128)
    ModelCallback = ModelCallback, // Method
    
    // optional method to load custom base, null callback loads DefaultBase()
    BaseCallback = BaseCallback, 
};
ExtraAssetsLibrary.ExtraAssetPlugin.AddAsset(asset); // Name still WIP but methods the same.

Example Callback

public static GameObject ModelCallback(NGuid id){
  return new GameObject(); // You may want to return your actual model
}

public static GameObject BaseCallback(NGuid id){
  return new GameObject(); // You may want to return your actual custom base
}

Recommended Extra Plugin (WIP)

In the works is an Asset Distribution plugin that will be paired with this plugin.

Changelog

  • 1.0.4: Fixed zipping issue where re-entering campaign tries appending to db again
  • 1.0.3: Assets can be added to existing groups
  • 1.0.2: optimized package by pointing to existing default base instead of copy
  • 1.0.1: prevent race condition.
  • 1.0.0: Null callback stops creature spawn in prep for CMP Effects.
  • 0.9.0: Alpha release

Shoutout to my Patreons on https://www.patreon.com/HolloFox recognising your mighty contribution to my caffeine addiction:

Available versions

Please note that the install buttons only work if you have compatible client software installed, such as the Thunderstore Mod Manager. Otherwise use the zip download links instead.

Upload date Version number Downloads Download link  
2021-8-25 1.0.4 258 Version 1.0.4 Install
2021-8-25 1.0.3 21 Version 1.0.3 Install
2021-8-25 1.0.2 16 Version 1.0.2 Install
2021-8-24 1.0.1 29 Version 1.0.1 Install
2021-8-24 1.0.0 16 Version 1.0.0 Install
2021-8-23 0.9.0 30 Version 0.9.0 Install