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

Shadowrun Macro - Output?

So, as far as i can tell, everything is layed out correctly for this particular macro, and it should be outputting, except it isn't, at all. @{selected|token_name}&{template:shadowrun}{{name=@{selected|token_name}}}{{roll_name=?{Ability|Body, Body|Agility, Agility|Reaction, Reaction|Strength, Strength|Charisma, Charisma|Intuition, Intuition|Logic, Logic|Willpower, Willpower|Magic, Magic}}}{{val1=[[@{selected|token_name}?{Ability|Body, Body|Agility, Agility|Reaction, Reaction|Strength, Strength|Charisma, Charisma|Intuition, Intuition|Logic, Logic|Willpower, Willpower|Magic, Magic}]]}} {{val1_num=[[@{selected|token_name}?{Ability|Body, bod_total|Agility, agi_total|Reaction, rea_total|Strength, str_total|Charisma, cha_total|Intuition, int_total|Logic, log_total|Willpower, wil_total|Magic, mag_total}]]}}{{mod_num=[[{?Situational Modifiers|0}]]}}{{edge=@{selected|token_name|edgeroll}}}{{edge_num=[[@{selected|token_name|edg_total}]]}}{{wounds_num=[[?{Apply Wounds|Yes, 1|No, 0}*(@{selected|token_name|wound_total})]]}}{{result=[[(@{selected|token_name|?{Ability|Body, bod_total|Agility, agi_total|Reaction, rea_total|Strength, str_total|Charisma, cha_total|Intuition, int_total|Logic, log_total|Willpower, wil_total|Magic, mag_total}}+?{Situational Modifiers}-?{Apply Wounds}*[[@{selected|token_name|wound_total}]]+[[@{selected|token_name|edgn}*@{selected|token_name|edg_total}]])@{selected|token_name|standardroll}@{selected|token_name|edgeroll}]]} Yes, this is very large, and kind of cumbersome, as you can probably see though i am trying to get around a couple of query issues. 1: Using the same query names, to get the Roll name, the attribute names, and the values. 2: Be usable for any PC token, by using the selected|token_name 3: Output on the shadowrun template Most of this was taken from a standard roll, It asks for the query correctly, and works if i remove the result The issue is somewhere in the bolded section, that is as far as i have been able to narrow it down. I would also really like to be able to make that output the number of failures alongside the success, which the standardroll doesn't do Any suggestions will be tested and apprecieated
You can't use the same Query names for more than one value in the same macro. In order do what you want you would need to get into some advanced query usage . You would need to put all of the fields for the template inside the query. It's possible but messy.
1492432972

Edited 1492433103
Ok, that explains the issue, thanks. I don't mind messy, messy is fine, so long as it works. ill give it a shot, if it works ill be happy How?
1492450830

Edited 1492450894
Silvyre
Forum Champion
Hi, Daniel I. I noticed that you were trying to "build" an Attribute call using a Roll Query (e.g. @{selected|?{Attribute Name|STR|DEX|...}}). This can't really work because of how the Order of Operations plays out. To work with the OoO, you'd need to place your Attribute calls within the Roll Query. (e.g. ?{Attribute|STR, @{selected|strength}|DEX, ...}). I rewrote your macro using this technique (with an added trick to prevent the need to mess with advanced Roll Query stuff): &{template:shadowrun} {{name=@{selected|token_name} }} {{roll_name= ``?{Ability|    Body, [Body](@{selected|bod_total})|    Agility, [Agility](@{selected|agi_total})|    Reaction, [Reaction](@{selected|rea_total})|    Strength, [Strength](@{selected|str_total})|    Charisma, [Charisma](@{selected|cha_total})|    Intuition, [Intuition](@{selected|int_total})|    Logic, [Logic](@{selected|log_total})|    Willpower, [Willpower](@{selected|wil_total})|    Magic, [Magic](@{selected|mag_total}) }`` }} {{val1=``?{Ability}``}} {{val1_num=[[ ?{Ability} + {0} ]]}} {{mod_num=[[ ?{Situational Modifiers|0} ]]}} {{edge=@{selected|edgeroll}}} {{edge_num=[[ @{selected|edg_total} ]]}} {{wounds_num=[[ ?{Apply Wounds|Yes, 1|No, 0} * (@{selected|wound_total}) ]]}} {{result=[[ ([[ ?{Ability} + {0} ]] + ?{Situational Modifiers} - [[?{Apply Wounds} * (@{selected|wound_total})]] + [[@{selected|edgn} * @{selected|edg_total}]])@{selected|standardroll}@{selected|edgeroll} ]]}}
Thank you so much Silvyre. I was starting to despair at being able to get this working.
1492534452
Silvyre
Forum Champion
You're very welcome, Daniel I. Macros like these are never easy to pin down.