Skip to content

#713: Override item examine text when necessary

What have you done in this MR?

  • Overwrite noted items examine (cleaned up how this happens by overriding Definition getExamine() inside ItemDefinition) - maybe this could be added to json, but then Definition getExamine() would need to be updated to handle looking at a noted examine text instead of examine text. Probably not much better than just having this single override in the overridden getExamine() in ItemDefinition.
  • Update json for clue scrolls to not need to override in code
  • Added override in BankInterface.kt for Coins which require different examine text for large quantities (>= 100k)

This is the table of behavior I went off of - if this is incorrect, then adjustments can be made: Examine Coins 995

Situation Should Display
On ground < 100 "Lovely money!"
On ground >= 100k "Lovely money!"
In bank < 100k "Lovely money!"
In bank >= 100k "X x Coins."
In bank inv < 100k "Lovely money!"
In bank inv >= 100k "X x Coins."
In inventory < 100k "Lovely money!"
In inventory >= 100k "X x Coins."

It also should be noted that as far as I can tell with the debugger, large quantity stacks of items (>= 100k) in the player inventory are not handled by the server at all. Most likely this behavior is in client scripts.

Are there any tricky things testers should keep an eye out for?

  • No
  • Yes, as follows:
  • I have tested these changes thoroughly.
  • This requires extra testing due to changes to architecture or other similarly risky changes.
  • I used the Thanos Tool for any JSON edits, I did not edit any JSON files by hand (MR will be rejected if there are manual JSON edits).
  • I acknowledge that this contribution will be released under the AGPL license.

Closes #713 (closed)

Edited by Byte

Merge request reports