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

PowerCards, maybe I give up!

1564066544

Edited 1564067338
Two weeks ago this was all working, tested 100 times, ready to play. We skipped a week of game, and last night, it below all to hell.&nbsp; Did something change I am not aware of? I have made zero changes to my macro but now all of my data is all over the place on display.&nbsp; In fact, at times, some of it is not even triggering. If I compare one macro (for example melee att vs ranged attack) the code is the same... but melee displays just fine. Here is a picture of where the lines should be and where they are: <a href="https://www.screencast.com/t/hKICVvtuP" rel="nofollow">https://www.screencast.com/t/hKICVvtuP</a> EDIT: Here is one working as it should: <a href="https://www.screencast.com/t/WK3lXvTE" rel="nofollow">https://www.screencast.com/t/WK3lXvTE</a> Here is the code that does this, same code, folks helped me write two weeks ago. !power {{ --tokenid|@{selected|token_id} --emote|@{selected|token_name} shoots @{target|token_name} --name|Action --leftsub|Attack --rightsub|Ranged --bgcolor|#274E13 --?? $ranged == 0 ?? |~C//**@{selected|range_0_name}//**~C --?? $ranged == 1 ?? |~C//**@{selected|range_1_name}//**~C --?? $ranged == 2 ?? |~C//**@{selected|range_2_name}//**~C --?? $ranged == 3 ?? |~C//**@{selected|range_3_name}//**~C --hroll|[[ [$ranged] ?{Weapon|@{selected|range_0_name},0|@{selected|range_1_name},1|@{selected|range_2_name},2|@{selected|range_3_name},3} +0d0 ]] --?? $ranged == 0 ?? Attack|[[ [$Atk] ?{Boosted Attack|N,2d6|Y,3d6} + ?{RAT|0} ]] vs @{target|bar3} DEF --?? $Atk.total &lt; @{target|bar3}?? !Miss1:|$$#900|~R**Attack missed!**~R$$ --Damage|[[ [$Dmg] ?{Boosted Damage|N,2d6|Y,3d6} + ?{POW|0} ]] vs @{target|bar1} ARM --?? $Dmg.total &lt; @{target|bar1}?? !Miss2:|$$#900|~R**Damage mitigated!**~R$$ --Location|[[ d6 ]] --?? $ranged == 1 ?? Attack|[[ [$Atk] ?{Boosted Attack|N,2d6|Y,3d6} + ?{RAT|0} ]] vs @{target|bar3} DEF --?? $Atk.total &lt; @{target|bar3}?? !Miss1:|$$#900|~R**Attack missed!**~R$$ --Damage|[[ [$Dmg] ?{Boosted Damage|N,2d6|Y,3d6} + ?{POW|0} ]] vs @{target|bar1} ARM --?? $Dmg.total &lt; @{target|bar1}?? !Miss2:|$$#900|~R**Damage mitigated!**~R$$ --Location|[[ d6 ]] --?? $ranged == 2 ?? Attack|[[ [$Atk] ?{Boosted Attack|N,2d6|Y,3d6} + ?{RAT|0} ]] vs @{target|bar3} DEF --?? $Atk.total &lt; @{target|bar3}?? !Miss1:|$$#900|~R**Attack missed!**~R$$ --Damage|[[ [$Dmg] ?{Boosted Damage|N,2d6|Y,3d6} + ?{POW|0} ]] vs @{target|bar1} ARM --?? $Dmg.total &lt; @{target|bar1}?? !Miss2:|$$#900|~R**Damage mitigated!**~R$$ --Location|[[ d6 ]] --?? $ranged == 3 ?? Attack|[[ [$Atk] ?{Boosted Attack|N,2d6|Y,3d6} + ?{RAT|0} ]] vs @{target|bar3} DEF --?? $Atk.total &lt; @{target|bar3}?? !Miss1:|$$#900|~R**Attack missed!**~R$$ --Damage|[[ [$Dmg] ?{Boosted Damage|N,2d6|Y,3d6} + ?{POW|0} ]] vs @{target|bar1} ARM --?? $Dmg.total &lt; @{target|bar1}?? !Miss2:|$$#900|~R**Damage mitigated!**~R$$ --Location|[[ d6 ]] }} !ammo @{selected|token_id} range_?{Weapon}_ammo -1 Is there something better which can do this type of logic? We don't use a character sheet, so I can't use the features those have, we use a raw attributes sheet with values to pull from.
1564069915
GiGs
Pro
Sheet Author
API Scripter
The advantage of power cards is its flexibility - it can manage almost any kind of roll, but that also means it's so complex. i dont know of anything else which can do what it does, out of the box. But if all the macros you use for it work pretty much the same way, a custom script might not be too hard to replace it. Looking att hat macro, i see a lot of replicatio. Do all the macros you use Power Cards for do basically the same thing?
Well sort of.&nbsp; Melee attack does not care what weapon you use, its all based on 2d6 (or 3d6 if boosted) + MAT (melee attack bonus) so my sword, axe, etc. is not important to know. Spells are the same.&nbsp; Attacks are 2d6 (3d6 boosted) + ARC (spell power), so casting electric charge, static absorption, etc. is not important to know. Range is ALMOST the same, but I need to track ammo.&nbsp; Thus, my example above, gives them 4 slots for ranged weapons, and ammo.&nbsp; The attack is the same as melee (RAT instead of MAT) but the ammo is reduced for the weapon in question. Because I was tracking ammo, I also wanted to be able to show the players what weapon was used... thus the complexity of the macro above.&nbsp; It displays which weapon was fired, and then deducts ammo from that weapon. These are basically my first macros so they were done brute force method. The ONLY thing still to be added is critical.&nbsp; Any attack that scores doubles (2-6) on the roll is a critical.&nbsp; A critical does not change the damage roll, but activates both 1. the critical hit property of a weapon (if it has one) and 2. adds a feat point to the character (max 3) if it needs one. Make sense?
My guess... Since you are using the same tag multiple times, it is showing up as order of operation. --Damage --Location But your attack is coming from Long range If / then statement at the bottom of the macro.. that is- if $ranged 3 is long range....???