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

5e Shaped Sheet Automatic Damage Application

1490318757

Edited 1490320902
For the D&D 5e Shaped Character Sheet with the Companion API, I'm wondering if anyone knows how (if it's already built into it) or of any scripts that allow damage to be automatically applied to the target. I notice that when an attack targets a token, you can have it roll and list the AC for the target. What I'm wondering is if there is any way to have it automatically take the damage rolled for that attack (if it was successful) and subtract it from the target. Some additional features that would be even more helpful is if there was a way for it to either automatically detect resistances/vulnerabilities/immunities/etc. compared to the damage type, or a manual drop down option or something similar to choose. This sheet and API has already revolutionized my games, but this would speed up gameplay even further to the point where combat becomes more of a continuous flow.
I personally would very much like something like `apply damage` button next to every attack output which will apply damage to selected token. Ideally it would also respect resistances and immunities of linked sheet. This button should probably only be visible to GM though. It should be possible to do this in separate script since you can handle chat output but I haven't seen ready to use solution so it might be hard to do...
It seems like it would be a really simple short modification/script, but I know that in programming simple things can end up being super complex to implement.
1490368954

Edited 1490369135
Try looking into this: Customizable Roll Listener
1490397477
Kryx
Pro
Sheet Author
API Scripter
Aaron K. said: It seems like it would be a really simple short modification/script, but I know that in programming simple things can end up being super complex to implement. This would not be simple. Just look at the basic level of complexity in the post you replied to: Roman said: Ideally it would also respect resistances and immunities of linked sheet. I've linked Lucian to this thread to get his thoughts as this would have to be API driven..
Aaron K. said: It seems like it would be a really simple short modification/script, but I know that in programming simple things can end up being super complex to implement. I wrote a script that automatically applies damage based on the 5e OGL sheet for single target attack rolls. I did not include saving throws, because the script would not know if the target had advantage or not. It's actually a pretty simple script to get just the damage and damage types from the 5e OGL templates, including saving throws. The difficult part would be adding in all the checks and balances to prevent players from mashing the button over and over and preventing players from triggering damage that the GM should apply.
1490429567

Edited 1490429799
SkyCaptainXIII said: The difficult part would be adding in all the checks and balances to prevent players from mashing the button over and over and preventing players from triggering damage that the GM should apply. It would probably be best to leave something like that to GM/PC communication. Players should clearly communicate what they're doing before they start smashing buttons left and right attacking creatures. The most difficult thing I could think of is when a single attack has multiple types of damage involved, but if I remember right I think the chat output already separates it like that such as 5 Piercing + 7 Necrotic + etc. Area effects and saves should be done manually though because there are so many variables involved that it would be a nightmare to make it fully automatic.
1490438325

Edited 1490442230
Lucian
Pro
API Scripter
Yeah, I've thought about doing this several times, but as Kryx says, it's actually more complicated than it looks. In the single damage, single target case, it's usually trivial, but D&D contains so many special cases for this stuff - resistances and special abilities that can change how damage is applied, and then there are spells and attacks that have multiple targets etc. My guess is that with a naive implementation you'd spend nearly as much time undoing/fixing damage application as you currently do applying the damage. Furthermore, automating this stuff has the potential to cause people to miss stuff that's potentially significant. In the end there's a fine balance between this being an assisted VTT for pen-and-paper RPGs and it trying to become a MMORPG. A *lot* of users still like to be involved in the mechanics of the game - which is why they're playing D&D and not WoW. I totally get the desire to make combats run as smoothly as possible, but my strong suspicion is that people's requirements/expectations of this feature will diverge extremely quickly, and it will be very hard to make something that works well even for a majority of people. All that said, I'm open to suggestions if people want to do the grunt work of thinking through the complexities of this and discussing it as a community.
1490439054

Edited 1490439942
@ Lucian How about click-to-apply-damage though? If you don't want it you can apply damage manually. Moreover it can ba an option in sheet you need to enable first. Ideally the number in damage output should be clickable but I'm not sure if it's even possible to make button with hover text (which shows how roll was calculated and is kinda essential). You can even ignore resistances and immunities and just add a warning next to option which enables this. The expected behaviour(at least for me) would be: - If token or multiple tokens are selected apply clicked damage to all of them and wisper it to DM. - If no tokens selected prompt targeting UI to click on token and wisper result to DM.
1490439917
Jakob
Sheet Author
API Scripter
Lucian said: Yeah, I've thought about doing this several times, but as Kryx says, it's actually more complicated than it looks. In the single damage, single target case, it's usually trivial, but D&D contains so many special cases for this stuff - resistances and special abilities that can change how damage is applied, and then there are spells and attacks that have multiple targets etc. My guess is that with a naive implementation you'd spend nearly as much time undoing/fixing damage application as you currently do applying the damage. Furthermore, automating this stuff has the potential to cause people to miss stuff that's potentially significant. In the end there's a fine balance between this being an assisted VTT for pen-and-paper RPGs and it trying to become a MMORPG. A *lot* of users still like to be involved in the mechanics of the game - which is why they're playing D&D and not WoW. I totally get the desire to make combats run as smoothly as possible, but my strong suspicion is that people's requirements/expectations of this feature will diverge extremely quickly, and it will be very hard to make something that works well even more a majority of people. All that said, I'm open to suggestions if people want to do the grunt work of thinking through the complexities of this and discussing it as a community. Yeah, when I wrote the applyDamage snippet for GroupCheck to (essentially) apply damage for area effects with a saving throw for half or none, I had the option of either making it completely automatic or outputting a button for the GM to click, and I made it a button click because total automation would be too little tabletop and too much computer game for me. The reason it was relatively simple to do was that I didn't intend for it to be complete with respecting resistances or anything, with the basic philosophy: in 80% of cases, this will be good enough and the GM can just click the button, and in the remainder of cases, they can do it the old-school way.
Lucian said: Yeah, I've thought about doing this several times, but as Kryx says, it's actually more complicated than it looks. In the single damage, single target case, it's usually trivial, but D&D contains so many special cases for this stuff - resistances and special abilities that can change how damage is applied, and then there are spells and attacks that have multiple targets etc. Yes, automating damage is very complicated however... automatically adding a damage application button after a template is sent to chat is pretty simple. Applying the damage is also pretty simple, given that I already have a script written to do so. If the template splits the damage types up in a reliable manner, comparing resistances and immunities is very straightforward.
1490440246

Edited 1490440845
Roman said: @ Lucian How about click-to-apply-damage though? If you don't want it you can apply damage manually. Moreover it can ba an option in sheet you need to enable first. Ideally the number in damage output should be clickable but I'm not sure if it's even possible to make button with hover text (which shows how roll was calculated and is kinda essential). You can even ignore resistances and immunities and just add a worning next to option which enables this. The expected behaviour(at least for me) would be: - If token or multiple tokens are selected apply clicked damage to all of them and wisper it to DM. - If no tokens selected prompt targeting UI to click on token and wisper result to DM. This would be the best since it's semi-automatic and almost just as fast as if it was fully automatic. It would also definitely be an optional thing in the configuration settings. What I could imagine it looking like (I'm not too keen on how coding works in roll20, so I don't know if this is possible) is like this: 24 Piercing Damage | [Vul] [Norm] [Res] [1/2] 8 Necrotic Damage | [Vul] [Norm] [Res] [1/2] // Vul = Vulnerable, Norm = Normal, Res = Resistant. There's no need for Immune because it would never be selected anyways. // The [1/2] would be a toggle button that modifies the other buttons. For example, if someone succeeds on a dexterity save against a fireball for half damage while also being resistant to fire damage. If the attack is a single target, selecting any of these will automatically apply it to said target. If the attack involves multiple targets or an area, you would have to select each token individually or multiple at once and apply them separately, as some may have succeeded on saves or have resistance/vulnerability. As for player preference, I understand that some players prefer to be heavily involved in the mechanics. I also like to be involved in them myself, but I would rather keep all of the mechanics in the background and focus instead on describing what's happening verbally rather than describing them numerically.
1490440419

Edited 1490440467
Kryx
Pro
Sheet Author
API Scripter
Aaron K. said: 24 Piercing Damage | [Vul] [Norm] [Res] [1/2] 8 Necrotic Damage | [Vul] [Norm] [Res] [1/2] This is madness. "Apply damage" which compares against a @{target} and checks vulnerabilites/immunities/resistances and automatically applies the damage would result in a better user experience than the GM having to open the sheet to see what type to use. I agree with Jakob - it should work for the vast majority of cases and if a GM thinks it won't work then they can use the manual way.
1490441172

Edited 1490441540
Kryx said: Aaron K. said: 24 Piercing Damage | [Vul] [Norm] [Res] [1/2] 8 Necrotic Damage | [Vul] [Norm] [Res] [1/2] This is madness. "Apply damage" which compares against a @{target} and checks vulnerabilites/immunities/resistances and automatically applies the damage would result in a better user experience than the GM having to open the sheet to see what type to use. I agree with Jakob - it should work for the vast majority of cases and if a GM thinks it won't work then they can use the manual way. I know that a single [Apply Damage] button would be much more convenient. My suggestion was more of an alternative approach in the case that having it be completely automatic ends up being difficult to implement. Heck, if anything there could be an option to switch between the semi-automatic and fully automatic in configuration options if both ended up being implemented at some point. I personally would only have to open the sheet once before an encounter to memorize the resistances/vulns. unless I'm dealing with many types of monsters or a particularly unique monster with tons of various resistances/vulnerabilities/immunities/etc. Point being, having the 4 buttons would be effective in most situations, but there would be some exceptions especially at high level encounters.
I preface this by saying that I'm in no way a programmer so I have no clear idea as to the difficulty: How hard would it be to develop a combat tracker that parses through the PCs' and the critters' sheets and presents a table to the GM and the players?  The table would include all the PCs and enemies ordered by initiative (and could perhaps leverage the turn tracker for its base).  The parsed array would include information like target AC, attacks, vulnerabilities, resistances with links back to the sheets to do saves.  Even if you don't 'semi-automate' the application of damage, it could make it much simpler for the GM to see at a glance what vulnerabilities and resistances come into play and do the math themselves.  'Semi-automating' things through an 'apply damage' button with the ability to get feedback would be icing on the cake.