Open lilwhitemouse opened 5 years ago
@Ratysz has a way to patch for RSA compatibility: https://github.com/Ratysz/RT_Shelves/blob/master/Source/Patches_StoreUtility.cs So it's possible for other mod creators to create compatibility; this approach may be slower than others.
This is not a "new" problem. For example Extended Storage has dedicated logic to allow balancing storage across multiple buildings which each store multiple stacks.
An ideal solution would ultimately be some standardized sort of attribute for slotGroups one could use to toggle hysteresis on or off.
Hello, I am writing a storage mod (https://github.com/lilwhitemouse/RimWorld-LWM.DeepStorage) and ran into an interoperability conflict.
We both patch StoreUtility_NoStorageBlockersIn.cs. I patch it to allow more than one thing on a cell, and the hysteresis code patches - as a postifx - to not allow hauling if the hysteresis conditions are met...on ANY stack of items there. If there are 6 stacks of berries, and room for 8, the hysteresis postfix will see the first stack of berries is full...and not allow anything. (Or 1 full stack, if there is only 1 full stack - the postfix isn't aware more than one stack can be there!)
This will be a problem for anyone who has multiple items on one square (RT_Shelves, etc).
I wonder if it would be possible to create a check for whether a cell can store multiple items - either at runtime (checking against a set of ThingComps) or by building a list of slotGroups that shouldn't have hysteresis applied (by checking against a set of ThingComps once, when the building is created). This approach would unfortunately put a bit of burden on you to have a list of criteria for keeping storage buildings out of hysteresis logic.
I love the mod, and would like to be able to run both at the same time. I haven't been able to come up with any other approaches off the top of my head; if you have ideas, please share. I would be happy to help in whatever way I can.