0.2.0 #8

Merged
Lubba-64 merged 8 commits from refactor-inventory-managers into main 2022-07-23 21:17:38 +00:00
Lubba-64 commented 2022-07-21 21:15:12 +00:00 (Migrated from github.com)

Intended updates:

  • inventory_contains_item does not need to have optional item_instance
    input
  • add_to_inventory does not need to have optional item_instance input
  • add quant_in_inventory
  • add empty_quant_in_inventory
  • add remove_from_inventory
  • Move as many tests as possible to be doctests
  • Refactor slot management functions to return a result instead of swapping the items for better user customization.
  • Remove IDebugItem
  • Add basic usage example to the readme.
    Closes #7
    Closes #3
    Closes #6
    Closes #4
Intended updates: - `inventory_contains_item` does not need to have optional `item_instance` input - `add_to_inventory` does not need to have optional `item_instance` input - add `quant_in_inventory` - add `empty_quant_in_inventory` - add `remove_from_inventory` - Move as many tests as possible to be `doctests` - Refactor slot management functions to return a result instead of swapping the items for better user customization. - Remove `IDebugItem` - Add basic usage example to the readme. Closes #7 Closes #3 Closes #6 Closes #4
Lubba-64 commented 2022-07-23 00:49:37 +00:00 (Migrated from github.com)

This is essentially done, just needs final review.
There are some relatively small breaking changes, but since this library is in its infancy it shouldn't be an issue.

This is essentially done, just needs final review. There are some relatively small breaking changes, but since this library is in its infancy it shouldn't be an issue.
Lubba-64 commented 2022-07-23 16:23:34 +00:00 (Migrated from github.com)

It occurred to me that the slot management helpers could just leave it up to the user ( and quite easily ) what happens when the specific operation does not work. This would be amazing for doctests, as it removes the need for a check on whether the items were swapped, as we can simply check if the result is Err or Ok.

Also, it appears that someone wants better docs in #6, and personally I agree. I have seen way too many projects that have inadequate documentation, and I want to fix that problem before it becomes too large. That's a new requirement for 0.2.0

It occurred to me that the slot management helpers could just leave it up to the user ( and quite easily ) what happens when the specific operation does not work. This would be amazing for doctests, as it removes the need for a check on whether the items were swapped, as we can simply check if the result is `Err` or `Ok`. Also, it appears that someone wants better docs in #6, and personally I agree. I have seen way too many projects that have inadequate documentation, and I want to fix that problem before it becomes too large. That's a new requirement for `0.2.0`
Lubba-64 commented 2022-07-23 21:17:30 +00:00 (Migrated from github.com)

ALRIGHT YOLO

ALRIGHT YOLO
Sign in to join this conversation.
No description provided.