Skip to content
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

Can't put spells in spellbooks #20

Open
2 tasks
tassaron opened this issue Aug 1, 2023 · 1 comment · May be fixed by #23
Open
2 tasks

Can't put spells in spellbooks #20

tassaron opened this issue Aug 1, 2023 · 1 comment · May be fixed by #23
Labels
bug Something isn't working

Comments

@tassaron
Copy link
Owner

tassaron commented Aug 1, 2023

Wizards need to store their spells inside spellbooks, which do exist as an item already.

Since all items have a "contents" field, I guess we could store spells in there. However that field is currently used for storing references to other equipment inside of "pack" items like the burglar's pack, so maybe not.

  • Serialize spells inside of spellbooks (maybe all spells and items inside of any items?)
  • Document how to use spellbooks
>>> from dnd_character.equipment import Item
>>> from pprint import pprint
>>> pprint(Item('spellbook'))
_Item(uid='5876bcc2fef0460fad6bb8527bacee52',
      contents=[],
      cost={'quantity': 50, 'unit': 'gp'},
      desc=['Essential for wizards, a spellbook is a leather-bound tome with '
            '100 blank vellum pages suitable for recording spells.'],
      index='spellbook',
      name='Spellbook',
      properties=[],
      special=[],
      url='/api/equipment/spellbook',
      weight=3,
      quantity=1,
      stealth_disadvantage=False,
      str_minimum=0,
      equipment_category={'index': 'adventuring-gear',
                          'name': 'Adventuring Gear',
                          'url': '/api/equipment-categories/adventuring-gear'},
      gear_category={'index': 'standard-gear',
                     'name': 'Standard Gear',
                     'url': '/api/equipment-categories/standard-gear'}
)
@tassaron tassaron added the bug Something isn't working label Aug 1, 2023
@stevebelew
Copy link

I'm close to a solution for this.

@tassaron tassaron linked a pull request Oct 5, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants