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

Variable dice with penalty.

I'm using this damage string for psionic powers that do d6+1 per power point invested. [[(?{PowerUsed [1-@{casterlevel}]?|1})d6 + ?{PowerUsed [1-@{casterlevel}]?|1} ]] But if I use Sonic, it's d6-1 per power point invested, with a minimum of 1 on each die. I can make it subtract easily by changing the sign, but any die that comes up 1 shouldn't get the penalty, since it's minimum 1 damage per die. How do I fix it?
1493400585

Edited 1493400621
You could wrap your roll in a {}kh1 function , e.g. [[ { (?{PowerUsed [1-@{casterlevel}]?|1})d6 - ?{PowerUsed [1-@{casterlevel}]?} , {1} }kh1 ]]
1493403752

Edited 1493403783
Thanks, but that doesn't appear to work. If you add it up, the rolls were 17, minus 5, for 12. &nbsp;The "1" I rolled shouldn't get a penalty (or needs to automatically become a 2, and then take the penalty). &nbsp;Damage should be 13. Here's the full macro I used for that screenshot. &{template:DnD35StdRoll} {{spellflag=true}} {{name=@{character_name} manifests [Energy Ray (Sonic)]( <a href="http://www.d20srd.org/srd/psionic/powers/energyRay.htm" rel="nofollow">http://www.d20srd.org/srd/psionic/powers/energyRay.htm</a> ).}} {{Discipline:= Psychokinesis (Sonic)}} {{Level:= Ardent 1}} {{Display:= Auditory}} {{Manifesting Time:=1 std action}} {{Range:= Close ( [[d1*25+5*floor(@{casterlevel}/2)]] ft)}} {{Effect = Ray}} {{Duration:= Instantaneous}} {{Saving Throw:= None}} {{Power Resist.:= Yes}} {{Caster level check: = [[ 1d20+@{casterlevel}+@{spellpen} ]] vs spell resistance.}} {{compcheck= Conc: [[ {1d20 + [[ @{concentration} ]] }&gt;?{Concentration DC=15+Spell Level or 10+Damage Received|0} ]] }}?{PowerUsed [1-@{casterlevel}]?|1} {{succeedcheck=Success! He manifests a ray of focused sound hitting a Touch AC of [[1d20 +[[@{rangedattackbonus}]]]] for [[ { (?{PowerUsed [1-@{casterlevel}]?|1})d6 - ?{PowerUsed [1-@{casterlevel}]?}, {1} }kh1 ]] sonic damage and using ?{PowerUsed [1-@{casterlevel}]?|1} power points}} {{failcheck=He fails, wasting ?{PowerUsed [1-@{casterlevel}]?|1} power points }}
I just realized the D&D3.5 sheet will return damages less than 1 for the default weapon damage macros as well. &nbsp;Minimum damage in 3.5 is always 1. Is there a way to make /r [[1d4-2]] give possible results of 1,1,1,2 ? I know I can make it reroll 1s and 2s, but that isn't the same. &nbsp;I'd get 1,1,2,2.
1493407339

Edited 1493407819
You might (with the help of your GM) set up Rollable Tables to handle this. If you choose to do so, your GM would be required to create a separate Rollable Table for each individual combination of die size and power point usage. For example: make /r [[1d4-2]] give possible results of 1,1,1,2 ? You GM could create the following Rollable Table, which emulates this specific roll: Table Item Weight 1 3 2 1 After your GM names the Table (e.g. "4minus2"), saves it, and allows players to roll it, you could use [[ 1t[4minus2] ]] or [[ ?{Number of dice|1}t[4minus2] ]] Alternatively, an Advanced Roll Query could also handle this.
This does most of what I want. /r {{1d6 + 1d6 + 1d6 + 1d6 + 1d6 + {0d1+2} + {0d1+2} +{ 0d1+2} + {0d1+2} +{0d1+2}}k5}-5 But it's hardcoded at 5 dice. &nbsp;Is there a way to get my variable number of dice back in there?
1493410208

Edited 1493410327
You can add some conditional statements to that roll to be able to choose a number of dice to roll that varies between 1 and the number of rolls you've hardcoded. e.g. [[ { 1d6, [[{-1,?{Dice|1|2|3|4|5}}&gt;2]]d6, [[{-1,?{Dice}}&gt;3]]d6, [[{-1,?{Dice}}&gt;4]]d6, [[{-1,?{Dice}}&gt;5]]d6, {2+0d0}, {[[2*{-1,?{Dice}}&gt;2]]+0d0}, {[[2*{-1,?{Dice}}&gt;3]]+0d0}, {[[2*{-1,?{Dice}}&gt;4]]+0d0}, {[[2*{-1,?{Dice}}&gt;5]]+0d0} }kh?{Dice} - ?{Dice} ]]
That's perfect! &nbsp;Well, it will be for a few levels anyway. &nbsp;When I have to extend it for 20 dice it won't be fun. Thanks a bunch!
Happy rolling!