RandomlyAwesome-HolyDLL icon

HolyDLL

EXPERIMENTAL.(Un)Holy code changes for the sake of performance.

Last updated 3 weeks ago
Total downloads 178
Total rating 0 
Categories Mods Tweaks
Dependency string RandomlyAwesome-HolyDLL-0.0.4
Dependants 0 other mods depend on this mod

This mod requires the following mods to function

bbepis-BepInExPack-5.4.19 icon
bbepis-BepInExPack

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

Preferred version: 5.4.19
RiskofThunder-HookGenPatcher-1.2.1 icon
RiskofThunder-HookGenPatcher

MMHOOK generation at runtime.

Preferred version: 1.2.1
tristanmcpherson-R2API-3.0.71 icon
tristanmcpherson-R2API

A modding API for Risk of Rain 2

Preferred version: 3.0.71

README

#What?

Mod to house experimental changes intended to optimize certain parts of the game,currently there is only a single change;\

  • Parallelize calls to RecalculateStats.Preliminary testing shows this to be highly beneficial when enemies change stats en masse(spawns,level ups).

When/If more changes become part of this they will be togglable by config,though one isn't included for now since it would be equivalent to uninstalling the mod. THIS MOD IS HIGHLY LIKELY TO BREAK COMPATIBILITY WITH OTHER MODS,DONT COMPLAIN TO OTHER MOD AUTHORS IF SOMETHING BREAKS WITH THIS

#I'm a mod dev,how does this affect my work?

Any hooks on CharacterBody.RecalculateStats not done through RecalculateStatsAPI.GetStatCoefficents WILL break,unless your hook doesn't touch any of unity's code (this means no interaction with GameObjects,vanilla csharp only).
While you can still put through synchronous calls to RecalculateStats() when necessary,it is greatly recommended that devs prefer marking the body's stats dirty instead,as this will allow the calls to be batched together.The statsDirty value can be set directly or through the relevant CharacterBody methods.

#Whats with the icon

That's the file icon for linkable libraries(shared objects) that my system theme uses,I attempted to make it look more 'holy',it's sitting on a pedestal made of fuel arrays to reinforce how janky this is.
DLLs don't actually get that icon in system though,they get a generic one that is not as stylish so I am using this instead.

#Whats with the Name?

I named the project files haphazardly due to not expecting this to go anywhere and ended up with output named holy.dll.It's kinda funny so it stays.
The ingame name is HolyHolyHOLY because I was reminded of that one Shin Megami Tensei schizopost,also it's easy to notice in Logs,which means it's easier for people to point out that you shouldn't be expecting something as jank as this to have good mod compatibility.I mean,it works with some stuff,see above section,but you waive the right to complain about mods breaking by installing this.

Credit to Rob,as always,since I used his csproj file.
Credit to IDeath and Twiner,for reminding me that Unity's csharp multi-threading support is non-existant and providing information on how to navigate the minefield it represents.
Credit to the GNU image manipulation program for helping me make the icon.
Credit to cute anime girls for giving me the will to continue living.

#Changelog

0.0.4 - Implemented some additional logic to make sure synchronous calls to determine stats don't ignore RecalculateStatsAPI,Note:Research if this is actually necessary,it is a slight reduction in the performance gain to leave it as is since the very initial call can not be safely parallelized.\ 0.0.3 - Moved OnLevelUp dispatch back into the main thread.
0.0.2 - RecalculateStatsAPI compatibility.
0.0.1 - Initial Shitpost

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-12-30 0.0.4 178 Version 0.0.4 Install