-
Notifications
You must be signed in to change notification settings - Fork 215
Update AgentRepair.cs #1689
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
base: main
Are you sure you want to change the base?
Update AgentRepair.cs #1689
Conversation
|
We could revert the breaking change if it's wanted, but the rename is more precise to what the struct actually holds |
Adjusted some names and comments (for a better understanding) which I forgot last night
|
The typical process for breaking changes is keeping the old field around, but marking it with a non-erroring [Obsolete(...)] and adding the named field at the same offset. Obsolete fields get removed from the API a couple weeks after a major game patch. |
Sure can do, but what about the changed return type of the function call? From: |
|
That one is a bit tougher, because it can't distinguish between the two based on return type alone, sometimes a new name is used, or a note is added to change the return value on the next major game update. |
Replaced RepairableItemAmount with ShownRepairEntryAmount and marked the old field as obsolete.
|
I don't think that we can get around the last breaking change, as I added an enum so users know right away what the possible values are and don't set any bogus value. |
|
You can by doing the following: [FieldOffset(0x5C), Obsolete("Use InventoryContainer field")] public int InventoryContainerIndex; // Used to lookup static array. Mapped index ids of repair gear dropdown. (7 = Equipped, 0 = Main/Off Hand, 1 = Head/Body/Hands, ...)
[FieldOffset(0x5C)] public InventoryContainer InventoryContainer; |
|
Worked it out a bit more and made it a bit cleaner. :) |
No description provided.