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

Yet another 4e damage automation script

1391062931
Alex L.
Pro
Sheet Author
Jarrod . said: Were they registering as 0s? no i just wasn't showing them correctly. Now it will say "Critical Miss".
Alex, i may have found one "bug" in your script. When making an attack roll that MATCHES a target's defense, it is being reported as a miss. I believe it should be a hit.
1391174241
Alex L.
Pro
Sheet Author
Kenny T. said: Alex, i may have found one "bug" in your script. When making an attack roll that MATCHES a target's defense, it is being reported as a miss. I believe it should be a hit. Check the top of the script, its a config option: var EQUAL_TO_DEF_HIT = false; True means that if Attack = Defence it will hit, False means it will miss. It is set to false because that is the rule my GM uses.
ah, sorry i missed that, thanks Alex!
1391414518
Alex L.
Pro
Sheet Author
New Update: Added resistances, just create a attribute with the name [damage type]_resist and give it the value you want it to resist, ie cold_resist.
1391422245

Edited 1391422287
Alex, This thing is shaping up into something epic! Is it possible to add a damage type "all" ? so one can have a stat "all_resist"?
1391429104
Alex L.
Pro
Sheet Author
Kenny T. said: Alex, This thing is shaping up into something epic! Is it possible to add a damage type "all" ? so one can have a stat "all_resist"? Done, will use typed resists first, then all resist.
when putting your script in I get this error "Cannot call method 'on' of undefined"
1391432518
Alex L.
Pro
Sheet Author
Saevar L. said: when putting your script in I get this error "Cannot call method 'on' of undefined" I don't get any errors during testing.
nvm it seems to work now ^^
SWEET! oh oh, sorry to be a pain, but what about a "-x" command that would allow the addition of temp hp to bar 3?
I've been testing and it doesn't seem to me that there is any damage reduction with corresponding damage types that my sheets have the _resist attribute for, and I can't find what I'm doing wrong.
Jarrod . said: I've been testing and it doesn't seem to me that there is any damage reduction with corresponding damage types that my sheets have the _resist attribute for, and I can't find what I'm doing wrong. Jarrod, seems to work for me, i would recommend double checking that in your macro's that all your damage types are lower case and that they are lower case in your attributes as well (also the first column) - so it should "cold-resist" 5/0 in your attributes and "-T cold" in your macro's.
Dunno I think you need all of nothing. For me they seem to only work if I set one with all_resist aswell. So if I put cold_resist 4/4 and all_resist 4/4 it works but in no other combin
1391510175

Edited 1391511241
That's odd, it works just fine for me...i wonder if it matters in what order you put all the macro modifiers? !power @{selected|token_id} "Pimp Slap" -t @{target|token_id} -a [[d20+9]] -d [[d8+6]] -C [[d8]] -v ac -T cold -H snail -h "target slowed, Save ends." -E interdiction -e "Target suffers a -2 to all defenses, end of my next turn." is generally the order i put mine in. /me berates his ally for lying down on the job! CLOSE: BURST 5 !power @{selected|token_id} "Majestic Word" -t @{target|token_id} -c [[@{target|svalue}+4]] -e "The target regains health! FEAT: Improved Majestic Word: target gains +4 Temporary HP" for heal spells.
Not sure. Would need more time to experiment with it. I use Radiance rpg similar to 4E but uses Danage reduction instead of armor so ofc it reduces aloy if not all damage alot of the time.
1391524355
Alex L.
Pro
Sheet Author
Damage types shouldn't be caps sensitive, Cold or cold should work. I will look at adding Temp HP healing soon.
Is everyone using both boxes for the attributes of the resist? I was thinking that it was only the first box like with AC, Fort, Reflex and Will and such..
Jarrod . said: Is everyone using both boxes for the attributes of the resist? I was thinking that it was only the first box like with AC, Fort, Reflex and Will and such.. i am only using the first
same here, and the reduction isn't going through.. hm.
Try useing all_resist and cold_resist. First boxes.
I've tried cold, fire, and poison.. Maybe I'll have to copy and paste the crypt again.
yeah the resist was a recent addition; perhaps you are using a older version of the script?
Honestly I had the same problem. It wouldnt detect cold_resist alone but would if I mixed it with all_resist
1391619703
Alex L.
Pro
Sheet Author
New update: Almost total recode, now more readable. -b will heal temp hp, same useage as -c.
Alex, awesome! my combat times are getting cut in half!
Alex L. said: Kenny T. said: Alex, i may have found one "bug" in your script. When making an attack roll that MATCHES a target's defense, it is being reported as a miss. I believe it should be a hit. Check the top of the script, its a config option: var EQUAL_TO_DEF_HIT = false; True means that if Attack = Defence it will hit, False means it will miss. It is set to false because that is the rule my GM uses. You should fix the comment in your script on line 26: var EQUAL_TO_DEF_HIT=false;//hit on Def == to_hit. Default 4e = false To say that 'Default 4e = true' instead.
1391685900
Alex L.
Pro
Sheet Author
HoneyBadger said: Alex L. said: Kenny T. said: Alex, i may have found one "bug" in your script. When making an attack roll that MATCHES a target's defense, it is being reported as a miss. I believe it should be a hit. Check the top of the script, its a config option: var EQUAL_TO_DEF_HIT = false; True means that if Attack = Defence it will hit, False means it will miss. It is set to false because that is the rule my GM uses. You should fix the comment in your script on line 26: var EQUAL_TO_DEF_HIT=false;//hit on Def == to_hit. Default 4e = false To say that 'Default 4e = true' instead. yes i realy should.
By far the best and most stable API I have used on roll20; thanks again for all your hard work Alex!
1391764086

Edited 1391764151
So i wanted to make a direct-heal macro for one of my cleric characters based on your script (for all those random type heals he can do). the macro goes: !power @{selected|token_id} "Healing" -t @{target|token_id} -c [[?{How Much HP?|0}]] -b [[?{How Much THP?|0}]] So it prompts the macro user for a set number to heal and a set number to add to the THP bar. typing in 5 for the hp prompt and 5 to the THP prompt should add 5 to each of those bars (in theory) However when healing target who has 25 health for 5 health and 5 Temp results in his health bar becoming 255 and his THP becoming 5. Does anyone see a mistake in my macro? EDIT- changing my macro to !power @{selected|token_id} "Healing" -t @{target|token_id} -c [[ 0+ ?{How Much HP?|0}]] -b [[?{How Much THP?|0}]] had no effect.
1391764293
Alex L.
Pro
Sheet Author
Kenny T. said: So i wanted to make a direct-heal macro for one of my cleric characters based on your script (for all those random type heals he can do). the macro goes: !power @{selected|token_id} "Healing" -t @{target|token_id} -c [[?{How Much HP?|0}]] -b [[?{How Much THP?|0}]] So it prompts the macro user for a set number to heal and a set number to add to the THP bar. typing in 5 for the hp prompt and 5 to the THP prompt should add 5 to each of those bars (in theory) However when healing target who has 25 health for 5 health and 5 Temp results in his health bar becoming 255 and his THP becoming 5. Does anyone see a mistake in my macro? Its a problem with javascripts soft typing, it sometimes decides that it will only treat something as a string and when you add 5 to a string of "25" you get "255". I will go through my code and add some fixes.
1391764341

Edited 1391764393
oh wow, you were fast, you answered it before this post :-) Further experimenting: i think there may have been a bug in the new "-c" string macro; previous working healing macros no longer work as well. /me utter a soothing word that mends wounds of the body and spirit. !power @{selected|token_id} "Healing Word" -t @{target|token_id} -c [[@{target|svalue}+2d6+5]] -e "The target can spend a healing surge and regain d6 + Wis mod (3) additional hit points. Pacifist Healer: Add an additional d6 + Cha Mod (2) to the amount of health gained."
1391768370
Alex L.
Pro
Sheet Author
Update: Fixed some shit :P This update should fix your problem Kenny, let me know if it doesnt.
Flawless! only 2 cents is that you may wanna add the -b option to the list of grey options at the beginning of your script for follow on users :-) I'd also maybe have your APICMD link go directly to that GIST rather than the thread, with the various version of it littering that thread it may confuse other script-nubs like myself ;-)
This is amazing.. I love seeing all the progression and improvements done to this script since the start. It's by far my favorite script that I currently use. Thank you so much for this Alex. You are amazing!
Also, here's a modified script based on Brian 's character sheet generation script that will generate a sheet with all the required fields for this script. Hope this helps contribute to this project! <a href="https://gist.github.com/anonymous/8903593" rel="nofollow">https://gist.github.com/anonymous/8903593</a>
Is anyone else noticing a cumulative damage total when there's a critical hit rolled? Here's what I'm getting: The crit damage is fine as that is a roll and will vary. The normal damage, however, keeps going up. Here's the macro for the power:
1392017447
Alex L.
Pro
Sheet Author
Jarrod . said: Is anyone else noticing a cumulative damage total when there's a critical hit rolled? Here's what I'm getting: The crit damage is fine as that is a roll and will vary. The normal damage, however, keeps going up. Here's the macro for the power: Fixed. Update: Fixed bug in max damage calculation when using more than one dice. Added SHOW_ROLLS option that will add some mouse over details to the damage roll. (just a debug thing really)
Alex, I swear that if I could I would give you a massive bear hug lol. You're awesome! Thank you :)
How does the SHOW_Rolsl option work? when i set it to "true" i can mouse over the inline damage rolls? i#ve tried it with both true and false values but not seeing any noticable changes. do i have to add a variable to the macros as well?
1392048766
Alex L.
Pro
Sheet Author
Kenny T. said: How does the SHOW_Rolsl option work? when i set it to "true" i can mouse over the inline damage rolls? i#ve tried it with both true and false values but not seeing any noticable changes. do i have to add a variable to the macros as well? no set it to true then mouse over the damage value, its only for the damage value as i said it is just in there for debugging.
I cant get the output in the chat to be formated like yours. I get this. What am i doing wrong?
1392049759
Alex L.
Pro
Sheet Author
Kevin H. said: I cant get the output in the chat to be formated like yours. I get this. What am i doing wrong? looks like your missing a !
nevermind i found it. I was missing a ! in the marco.
Is it possible to have maybe a macro which creates one of these powers onto a character represented token? (To save time on prep)
1392057972
Alex L.
Pro
Sheet Author
Saevar L. said: Is it possible to have maybe a macro which creates one of these powers onto a character represented token? (To save time on prep) no.
a mouse over on attack rolls would be grand; i had my hunter hit between 13 and 15's 8 times on a row with her twin strike; so my party was like - "Kenny i don't know about these new macros, i think something is wrong." and i was like" it's cool, i just spent 3 hours changing all my macros to the new format, we can change back to the old ones, np." &gt;.&lt; /sigh what ever happened to "for Science!"
1392100187
Alex L.
Pro
Sheet Author
Kenny T. said: a mouse over on attack rolls would be grand; i had my hunter hit between 13 and 15's 8 times on a row with her twin strike; so my party was like - "Kenny i don't know about these new macros, i think something is wrong." and i was like" it's cool, i just spent 3 hours changing all my macros to the new format, we can change back to the old ones, np." &gt;.&lt; /sigh what ever happened to "for Science!" You can tell them its just how RNG works, all the rolls are exactly the same as they would be if you put them in a normal macro, I don't edit them in any way (unless it crits).
Alex, have you found out a way to implement vulnerabilities into the script?