Aller au contenu

Photo

Book of Infinite Spells


  • Veuillez vous connecter pour répondre
2 réponses à ce sujet

#1
rjshae

rjshae
  • Members
  • 4 485 messages
I was wondering how you would go about scripting a Book of Infinite Spells, as per the old AD&D magic item? My first attempt was to make it work like a scroll that would call a tag-based On Unacquire script when it was used. Unfortunately a charged item doesn't seem to call the tag-based scripts. My only other option then is to make it a Unique Power that runs a On Activate script when it is used, thereby possibly changing the page or making it vanish. The problem then is the description needs to be managed to list the current spell. Also the spell may be a ranged spell or a self-only spell, which function differently in terms of target selection. Is there a better way?

Thank you.

#2
diophant

diophant
  • Members
  • 116 messages
I would give the book two item properties. The first is a unique power (self only) and handles turning the pages. The second item property is the actual spell. In the onActivate script of the item (i.e. turning the page), you have to remove the second item property, and create a random new one (or destroy the book if you are on the last page). I think the most tricky bit is the possibility of turning the page while casting the spell. This should be possible by spellhooking: check whether the spell was cast from the book, determine if you have to turn the page, and if so, execute the onActivate script.

#3
rjshae

rjshae
  • Members
  • 4 485 messages
Interesting approach. I'll take a look. Thanks.