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

Spell macro freezes

not sure what the problem is, it gets to the popout for concentration and then stops &{template:DnD35StdRoll} {{spellflag=true}} {{name= @{character_name} casts Vampiric Touch }} {{School:=Necromancy}} {{Level: =Duskblade 3}} {{Comp'nts:=V, S }} {{Casting Time:= 1 std action}} {{Range:=Touch}} {{Target:= living creature}} {{Duration:=Instant (1 hour (See text)}} {{Saving Throw:= None}]]) }} {{Spell Resist:= Yes }} {{ Caster level check: = [[1d20+@{casterlevel2}+@{spellpen}]] vs SR.}} {{compcheck= Conc:[[{1d20+@{concentration} }>?{Concentration DC=15+Spell Level or 10+Damage Received|18}]] }} {{succeedcheck=Streams of dark energy wreath his hand.}} {{failcheck=Spell fails, AoO provoked! }} {{notes=Your touch deals 1d6 per 2 caster levels ( [[5d6]] ) damage. You gain temporary hit points equal to the damage you deal. However, you can’t gain more than the subject’s current hit points +10, which is enough to kill the subject. The temporary hit points disappear 1 hour later.}}
1435609613
Wes
Sheet Author
Just a bit of Extra stuff: {{Saving Throw:= None }]]) }} Should Read: {{Saving Throw:= None }} Now Back to touching things!
That seemed to fix it, thanks! Is there a way to cap out the roll for damage? In this case it's 10d6, but how would I write it for that? I tried [[@{casterlevel2}/2*1d6]] but got nothing, and not sure how to put the cap in there for the max die.
1435647134

Edited 1435647537
[[ [[{floor(@{casterlevel2}/2),10}kl1]]d6]] This will use a nested inline roll to calculate CL2/2 and compare it to the max of 10 keeping the lower and then using that as the number of d6 rolled. The nested inline roll is nessisary for this to work. Without it the roll will result in an error since neither floor() or {}kl1 can normally be used as a function within a dynamic dice roll. But when placced in a nested inline roll the dice roll works as if it were a static roll, though it's infact a dynamic roll. It's also worth noting that your attempt with [[@{casterleve2}/2*1d6]] would have resulted in multiplying the ressult of CL2/2 by the result of 1d6. To increase the number of dice rolled (without a cap) it would have had to read [[(@{casterlevel2}/2-0.5)d6]].... or [[ [[floor(@{casterlevel2}/2)]]d6]]
[[(@{casterlevel2}/2-0.5)d6]] What function does the -0.5 serve in this? does that offset the partial when referring to an odd numbered caster level?
Yes. Roll20's dice roller automatially rounds to the nearest whole number when rolling fractional dice... so a CL of 5 would roll 3 dice instead of 2 since 2.5 rounds to 3.
That makes sense. I should find a good thread explaining these as each of your answers makes me think of another question and I'd hate to keep using your time. Now I'm thinking about how to apply that to the range increment roll to prevent partial results.
1436256135
Ziechael
Forum Champion
Sheet Author
API Scripter
Justin L. said: I should find a good thread explaining these as each of your answers makes me think of another question... I can't recommend the wiki enough, there are many pages dedicated to macros and the various ways they can be used to get desired effects. First off though i would familiarise yourself with the dice reference , a really useful page! Then there are macros , useful macros and since you referred to 3.5 in your OP i'm assuming these 3.5 specific macros might be of use. I'm also a 3.5 DM with well over 300 macros (well i use powercards, an API script which is a mentor level perk) under my belt should you have any questions i'd be happy to help out.
Justin L. said: That makes sense. I should find a good thread explaining these as each of your answers makes me think of another question and I'd hate to keep using your time. Now I'm thinking about how to apply that to the range increment roll to prevent partial results. I honestly don't mind. I'm glad to help out where I can ^-^