New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Preserving Item Mod Data Megathread #265
Comments
If you want to handle the testing for this, I'm quite happy to do the fixing and verify everything is going through the appropriate channels (since I did the Save/Load, Networking and advised on Mod/Global design) Also are we talking about ModItem data or GlobalItem data in each case, and as a sub point for Save/Load/Unload, are we talking about when the mod providing the GlobalItem is unloaded, or when the mod providing the host item with GlobalItem data from another mod is unloaded? |
For the preserve through unload, what I tried so far was a vanilla item with GlobalItem data attached (ExampleInstancedGlobalItem, it attaches a string to the item). The mod supplying the GlobalItem was unloaded, the world entered and exited, the mod was re-enabled, and the world was re-entered. In this case, the data was still present in the .twld file after leaving the world while the mod was unloaded, but the MysteryGlobalItem was not restored to the Player or World once the mod was reenabled. Also, if the world is entered while the data is already in MysteryGlobalItem, the data is lost as well. (As in, Exit World/Unload/Enter/Exit/Enter/Exit) |
#257 should fix for reforges. ( I did test, worked for me ) |
I added |
I believe |
To add a comment on quick stacking: As discussed before, stacking is undefined behavior with custom data. To support this usecase, we need hooks that can define behavior when stacking (CanStack, OnStack.. etc. as discussed). This is probably best suited as a separate issue at some point. |
Adding a couple new sources to the list for 1.4:
|
So, I'm just trying to figure out what's left to tackle here. Allow me to summarize knowns Tile entities, item frames were addressed in Dec by Mirsario: 12cd989 Mannequins preserving armor was also addressed at some point, though can't find any particular source (is this what right-click to equipment refers to? Or are we just speaking about the right click to equip, at which point that's been working afaik?) Preservation of the items in chests will be addressed by: #1266 Preservation of items in void vault will be addressed by: #1270 NPC Loot drop system was addressed by: #1063 tldr; is all that is left fixing the quick stack for chests in multi? |
Looks like quick stack was fixed at some point for multi, or at least compared original issue #235 and never marked here as done (proof with reported durability mod): durability_quickstack.mp4So I guess this is almost closable? |
This needs a once over test, then probably close in favor of individual issues still present logged in existing issues. |
I believe this is done |
This issue serves as a home for all issues pertaining to preserving mod data in Mod Items through all possible movement vectors.
All items are tested with ExampleMod's ExampleInstancedGlobalItem.
GlobalItem
Single Player
1.4 Update
Multiplayer
TODO: Untested
ModItem
TODO: Untested
The text was updated successfully, but these errors were encountered: