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 .
×

Pathfinder Simple (Cazra) template issue with macros

Hey there! Several of my Pathfinder 1e games on Roll20 use the Pathfinder Simple (Cazra) character sheet. I tried to use the character sheet's roll template for my macros and can't bring it to work at all. E.g. using this macro code: &{template:default} {{name=Sand Blast 30ft.}} {{attack=[[1d20cs>20 + @{bab} [BAB] + @{dex_mod} [DEX] ]]}} {{confirm Crit=[[1d20cs>20 + @{bab} [BAB] + @{dex_mod} [DEX] ]]}} {{damage=[[(2d6+2) [BaseDamage] + @con_mod [CON] + 2 [KiPoolNotEmpty] +1 [PointBlank] ]] magic slashing damage}} {{critical Damage=[[(4d6+4) [BaseDamage] + @con_mod [CON] + 4 [KiPoolNotEmpty] + 2 [PointBlank] ]] magic slashing damage}} Provides a nice formatted roll output: Now this is using the default template, so the result differs from the character sheet's usual roll visuals: Trying to use the same macro code with the sheet's own template: &{template: pf } {{name=Sand Blast 30ft.}} {{attack=[[1d20cs>20 + @{bab} [BAB] + @{dex_mod} [DEX] ]]}} {{confirm Crit=[[1d20cs>20 + @{bab} [BAB] + @{dex_mod} [DEX] ]]}} {{damage=[[(2d6+2) [BaseDamage] + @con_mod [CON] + 2 [KiPoolNotEmpty] +1 [PointBlank] ]] magic slashing damage}} {{critical Damage=[[(4d6+4) [BaseDamage] + @con_mod [CON] + 4 [KiPoolNotEmpty] +2 [PointBlank] ]] magic slashing damage}} Unfortunately just results in an empty box: I found the sheet's git repository, but neither there nor in the wiki is any documentation to be found on how the template can be properly used in macros. Has anyone used templated macros in this character sheet before or is able to point me in the direction of any kind of documentation?
1597898013

Edited 1597898098
Andreas J.
Forum Champion
Sheet Author
Translator
Your attempts fails because the built in template works differently, and have different keywords. It seems the {{charName=}} part of the template must be included, or the complete thing breaks. If we look at the code for one of the attack buttons : &{template:pf} {{charName=@{character_name}}} {{attr=@{attack_name}}} {{result=[[1d20cs>@{attack_critRange} + @{attack}]]}} {{damage=[[@{attack_damage}]]}} {{critConfirm=[[1d20cs>@{attack_critRange} + @{attack}]]}} {{critDamage=[[(@{attack_damage}) * @{attack_critMultiplier}]]}}{{isAttack=true}} {{notes=@{attack_notes}}} we see that things have different names. You should change your macro to be something like &{template:pf} {{charName=@{character_name}}} {{attr=Sand Blast 30ft.}} {{result=[[1d20cs>20 + @{bab} [BAB] + @{dex_mod} [DEX] ]]}} {{damage=[[(2d6+2) [BaseDamage] + @con_mod [CON] + 2 [KiPoolNotEmpty] +1 [PointBlank] ]] magic slashing damage}} {{critConfirm=[[1d20cs>20 + @{bab} [BAB] + @{dex_mod} [DEX] ]]}} {{critDamage=[[(4d6+4) [BaseDamage] + @con_mod [CON] + 4 [KiPoolNotEmpty] +2 [PointBlank] ]] magic slashing damage}}{{isAttack=true}} {{notes=Maybe optional dunno}} (remove linebreaks and it should work) So always look at the code of existing buttons to figure out how roll templates work. You can roll a button and then go to the chat and press the up key, and the last macro comes up in the chat window.
📜🗡Andreas J.🏹📜 said: Your attempts fails because the built in template works differently, and have different keywords. It seems the {{charName=}} part of the template must be included, or the complete thing breaks. If we look at the code for one of the attack buttons : [code] we see that things have different names. You should change your macro to be something like [code] (remove linebreaks and it should work) So always look at the code of existing buttons to figure out how roll templates work. Ah, thank you very much. While I figured that my syntax can't be translated 1on1, I wasn't able to find any usage example in the code to extrapolate the committed attributes. Probably shouldn't do those things at 4am. You can roll a button and then go to the chat and press the up key, and the last macro comes up in the chat window. Okay, that changes everything. This is some powerful debugging sorcery. xD