This uses the update item hook to delete and recreate the spellcasting entry on the character sheet. I'm sure there's a more graceful way to do this (like reading and updating the spellcasting entry), but this should work.
Thanks for starting this. Didn't love duplicating the same logic in both hooks, so I just made the entry handling a function that updates an existing entry or creates a new one if an existing entry isn't found.
This uses the update item hook to delete and recreate the spellcasting entry on the character sheet. I'm sure there's a more graceful way to do this (like reading and updating the spellcasting entry), but this should work.
This solves Issue #9