Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account

[PF] Spell Sheet Macro

Hi, Over the past few weeks I've been having trouble getting my spell macros to work.  I set up the macro using the abilities section, and using the following formula. %{selected|repeating_lvl-1-spells_$0_roll} For the longest time it worked just fine, then just recently I've started getting this response... You tried to use the repeating section row at index 0 for repeating_lvl-1-spells, but there doesn't seem to be a row at that index. No attribute was found for @{Apra Skoix|repeating_lvl-1-spells_$0_macro-text} I know the character sheets have undergone a recent upgrade, but I'm not sure why this would have been affected. Help?
1475032507
Tetsuo
Forum Champion
Go to your spells. Hover the button for that spell. It should give you the macro text to call that spell. 
They all say the same thing... %{selected|repeating_spells_$X_roll}
1475033513
Finderski
Plus
Sheet Author
Compendium Curator
You change the 'X' to a number. 0 is the first spell in the repeating section, 1 would be the second, etc.  For example:  %{selected|repeating_spells_$0_roll}
1475033665
Tetsuo
Forum Champion
Finderski said: You change the 'X' to a number. 0 is the first spell in the repeating section, 1 would be the second, etc.  For example:  %{selected|repeating_spells_$0_roll} This. Sorry, I should have mentioned that in my original comment. Posting from mobile. 
1475034028

Edited 1475034345
vÍnce
Pro
Sheet Author
All spells have been consolidated into one section to help us maintain the sheet.  You can use %{selected|repeating_spells_$X_roll} where X is any row#.  The better option is to use a spells id instead of a row number.  You can drag/drop a spell to the macro quickbar, cast the spell from there, click in the chat input window and use the UP arrow key to see the last command sent to chat.  This will show the exact call needed to fire that spell.  ie %{GALLF NORAK|repeating_spells_-KIjD1iPvbA5VSXViRwi_roll}  Then you can use that in your own macros, or just rename the spell that you dragged to the quickbar.  Hope this helps.
1475040292

Edited 1475040339
Thanks everyone for your time! Vince, I had noticed the spell ID's and was wondering if they would be useful in the macro...and you've just answered that for me! Thanks again all!
1475044712

Edited 1475044746
vÍnce
Pro
Sheet Author
Using the id allows your macro to always be tied to that repeating entry/attribute, regardless of what row it's on. I like to rearrange repeating entries for organization.  Row $0 might not be the same item all the time, but id -KIjD1iPvbA5VSXViRwi never changes.  ;-)
1475063638
chris b.
Pro
Sheet Author
API Scripter
The repeating_lvl-1-spells sections would be on the config tab and are old and not automatically updated anymore. You should use the new section on the spells tab, which are named "repeating_spells_xxxx" and are all in only one list.  It would have tried to copy them over in the past, but probably you'll have to manually fix them up.  Plus now on the spells section there is the big red button for "Spellbook" just above spells, which you can also drag to the macro bar. From there you can click on that, then click on the spell in chat, which is 2 clicks but no need to write more of your own macros if that is sufficient.
1475070676

Edited 1475070892
One more question... What if a spell entry doesn't have an ID number?  Can I get one assigned? So for example....I was just adding a spell to the list (Identify) and it is not coming up with it's own ID.  Neither is it showing up in the Spellbook, which is a great option that I didn't even realize was there!
1475072423

Edited 1475072452
chris b.
Pro
Sheet Author
API Scripter
When you first hit "add" there is no ID, the ID will be assigned after you fill in a field and tab/click to the next field, which causes it to save the row. You will need to toggle the arrow by "ID" to hide and display it again to see what the ID is. I suppose we should default that arrow to hide the id, so you have to hit it once, and thus prompt the sheet to look it up.
Hi Chris, That seemed to work great! So, here is what I hope is my last question for you... Is there a way to similarly 'refresh' the Spellbook?  Because the spells I've just added (and made sure had ID's), don't show up in the Spellbook... Sorry for the litany of questions....
1475085529
chris b.
Pro
Sheet Author
API Scripter
The refresh button on the upper right (circular arrow) Make sure to look at the status of the "show only prepared spells" checkbox in the spells per day. If it is checked, it will only display spells where the "uses" are set to > 0. Because it should keep updating the macro every time you change.
Works like a charm! Thanks again, Chris.  I appreciate your diligence and speed!