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

Starfinder Macro transfert attaque

Hi my name is Dimitri, I use for my game the Starfinder simple sheet. With the character sheet, I can create a weapon but when I transfer it doesn't work.  Thank you very for any help . :)  @{trick-attack} &{template:pf_attack} {{name=@{character_name}'s @{pc-weapon-name}}} {{subtags=@{pc-weapon-type}}} {{attack=[[1d20cs>20 + [[@{pc-weapon-total-attack}]] + ?{Any other modifiers?|0} ]]}} {{damage=[[@{pc-damage-dice-num}d@{pc-damage-die}+@{pc-weapon-total-damage}+[[@{pc-solarion-crystal}]] ]]}} {{dmgcrit=[[@{pc-damage-dice-num}d@{pc-damage-die}+@{pc-weapon-total-damage}+[[@{pc-solarion-crystal}]] ]] and @{pc-weapon-critical}}} {{notes=@{pc-weapon-notes}}} {{attk-notes=@{attack-notes}}}
1569696215

Edited 1569706584
vÍnce
Pro
Sheet Author
Copying the macro-text from the roll's macro-text to an ability macro should probably be updated to include "selected|" for the attribute calls to resolve properly. try this; &{template:pf_attack} {{name=@{selected|character_name}'s @{selected|pc-weapon-name}}} {{subtags=@{selected|pc-weapon-type}}} {{attack=[[1d20cs>20 + [[@{selected|pc-weapon-total-attack}]] + ?{Any other modifiers?|0} ]]}} {{damage=[[@{selected|pc-damage-dice-num}d@{selected|pc-damage-die}+@{selected|pc-weapon-total-damage}+[[@{selected|pc-solarion-crystal}]] ]]}} {{dmgcrit=[[@{selected|pc-damage-dice-num}d@{selected|pc-damage-die}+@{selected|pc-weapon-total-damage}+[[@{selected|pc-solarion-crystal}]] ]] and @{selected|pc-weapon-critical}}} {{notes=@{selected|pc-weapon-notes}}} {{attk-notes=@{selected|attack-notes}}} EDIT/UPDATE: since this is a repeating section, there is a little more info that must be included to pull the correct attribute values. Explained further down the thread...
Hello, thanks for your helping! I have the same error. But it works for the character name 
1569705852

Edited 1569706649
vÍnce
Pro
Sheet Author
Sorry, I should have realized the attributes that are throwing the error are located within a repeating section (repeating_pc-weapon) which requires additional "path" information in order to pull the correct attribute. e.g. @{selected|repeating_pc-weapon_$X_pc-weapon-name}  where X is the row number or $X is the "rowID" of the attack.  Using the rowID is the better option since your macro will continue to work even if you rearrange your attacks. I don't believe the simple sheet displays the rowID, so you'll need to use the browser's inspector tool to determine the rowID by looking at the HTML of the sheet.  Example; right-click on the weapon's name field and choose "Inspect" and you'll need to scroll up a little looking for data-reprowid ="<THE NUMBER LISTED HERE IS THE ROWID>". Then you need to update your ability macro accordingly example (this macro is simply using row 0) &{template:pf_attack} {{name=@{selected|character_name}'s @{selected|repeating_pc-weapon_$0_pc-weapon-name}}} {{subtags=@{selected|repeating_pc-weapon_$0_pc-weapon-type}}} {{attack=[[1d20cs>20 + [[@{selected|repeating_pc-weapon_$0_pc-weapon-total-attack}]] + ?{Any other modifiers?|0} ]]}} {{damage=[[@{selected|repeating_pc-weapon_$0_pc-damage-dice-num}d@{selected|repeating_pc-weapon_$0_pc-damage-die}+@{selected|repeating_pc-weapon_$0_pc-weapon-total-damage}+[[@{selected|repeating_pc-weapon_$0_pc-solarion-crystal}]] ]]}} {{dmgcrit=[[@{selected|repeating_pc-weapon_$0_pc-damage-dice-num}d@{selected|repeating_pc-weapon_$0_pc-damage-die}+@{selected|repeating_pc-weapon_$0_pc-weapon-total-damage}+[[@{selected|repeating_pc-weapon_$0_pc-solarion-crystal}]] ]] and @{selected|repeating_pc-weapon_$0_pc-weapon-critical}}} {{notes=@{selected|repeating_pc-weapon_$0_pc-weapon-notes}}} {{attk-notes=@{selected|repeating_pc-weapon_$0_attack-notes}}} example (this macro is using the rowID as determined by viewing the HTML of the repeating attack) &{template:pf_attack} {{name=@{selected|character_name}'s @{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-name}}} {{subtags=@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-type}}} {{attack=[[1d20cs>20 + [[@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-total-attack}]] + ?{Any other modifiers?|0} ]]}} {{damage=[[@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-damage-dice-num}d@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-damage-die}+@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-total-damage}+[[@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-solarion-crystal}]] ]]}} {{dmgcrit=[[@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-damage-dice-num}d@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-damage-die}+@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-total-damage}+[[@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-solarion-crystal}]] ]] and @{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-critical}}} {{notes=@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_pc-weapon-notes}}} {{attk-notes=@{selected|repeating_pc-weapon_-LpthEvcMY5IDFJYZU6p_attack-notes}}} .
Hello Vince thank you very much it's working! 
1569714852
vÍnce
Pro
Sheet Author
You're welcome. :-)