RPTools.net

Discussion and Support

Skip to content

It is currently Thu Jul 27, 2017 5:43 pm 




Forum rules


This forum is LOCKED. If a thread belongs here, use the "Report" feature of the post to let a moderator know to move it. General discussion should occur in the User Creations or MapTool forums.



Reply to topic  [ 491 posts ]  Go to page Previous  1 ... 28, 29, 30, 31, 32, 33  Next

Previous topic | Next topic 

  Print view

Author Message
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Tue Dec 10, 2013 2:41 am 
Thank you for working with this...the numbers are not calculating. Major Impact has 34 rPD and 1/2 damage reduction. I applied 30 Stun 10 body Penetrating attack....it came out 15 stun 5 body. Now the 5 body is correct...but he should have only take a max of 5 stun too. Since his initial PD is 34...the 30 should not have gone through so the only thing that got applied was the 1/2 damage reduction to make it 15 stun.

Also, for just the Armor Piercing part. Express has 20pd I applied 30 Stun 12 Body, Armor Piercing it applied 19 stun and 1 body. It should have halved his PD to 10 so...he should have taken 20 stun 2 body.

Optionw


Top
 Profile  
 
User avatar  Offline
Dragon
 
Joined: Fri Sep 21, 2007 5:10 pm
Posts: 439
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Tue Dec 10, 2013 9:53 pm 
OptionW wrote:
Thank you for working with this...the numbers are not calculating. Major Impact has 34 rPD and 1/2 damage reduction. I applied 30 Stun 10 body Penetrating attack....it came out 15 stun 5 body. Now the 5 body is correct...but he should have only take a max of 5 stun too. Since his initial PD is 34...the 30 should not have gone through so the only thing that got applied was the 1/2 damage reduction to make it 15 stun.
Actually, the 10 Body should have been applied versus the hardened defenses (if any) before the damage reduction. The Stun should have been whatever Body was left (if any).

Quote:
Also, for just the Armor Piercing part. Express has 20pd I applied 30 Stun 12 Body, Armor Piercing it applied 19 stun and 1 body. It should have halved his PD to 10 so...he should have taken 20 stun 2 body.
Looks like a rounding issue.

Here is my latest attempt. See how that works. And thanks for testing it out.
Code:
[h: cLuck=getProperty ("CombatLuck")]
[h: getProperty ("currentCon")]
[h: useBleed=getLibProperty ("useBleeding", "Lib:Combat")]
[h: useStunned=getLibProperty ("useStunned", "Lib:Combat")]
[h: tNS=getProperty ("takesNoStun")]
[h: dNB=getProperty ("doesNotBleed")]
[h: cBS=getProperty ("cannotBeStunned")]



[h,if (dNB==1): useBleed=0]
[h,if (cBS==1): useStunned=0]

[h: damage = input (
   "defType|PD, ED, Sight, Hearing, Touch, Olfactory, Mental, Power, None|Type of Attack|RADIO|VALUE=STRING ORIENT=H",
   "dmgType|Normal, Killing|Type of Damage|RADIO|SELECT=1 ORIENT=H",
   "stunDmg|0|Input Stun Damage Taken (use positive numbers)",
   "bodyDmg|0|Input Body Damage Taken (use positive numbers)",
   "penetrating|0|Check is attack is Penetrating|CHECK",
   "armorPiercing|0|Check if attack is Armor Piercing|CHECK",
   "ignoreCL||Do not apply Combat Luck|CHECK",
   "dmgMultiStun|0.25, 0.5, 0.75, 1, 1.5, 2|Stun Damage Multiple|RADIO|ORIENT=H SELECT=3 VALUE=STRING",
   "dmgMultiBody|0.25, 0.5, 0.75, 1, 1.5, 2|Body Damage Multiple|RADIO|ORIENT=H SELECT=3 VALUE=STRING",
   "showHeader|0|Update/Show Character Sheet Header|CHECK"
   )
]

[h: abort (damage)]


[h: appCL = ABS(ignoreCL -1)]

[h, switch (defType), CODE:

   case "PD":
      {
      [temp_PD=getProperty ("currentPD")]
      [temp_PD=floor (temp_PD/(armorPiercing+1))]
      [temp_HPD=getProperty ("currentHPD")]
      [temp_RPD=getProperty ("currentRPD")]
      [temp_RPD=floor (temp_RPD/(armorPiercing+1))]
      [temp_HRPD=getProperty ("currentHRPD")]
      [temp_HRPD=temp_HRPD+(cLuck*3)]
      [rDef=temp_RPD+temp_HRPD]
      [tDef=temp_RPD+temp_HRPD+temp_PD+temp_HPD]
      [rhDef=temp_HRPD]
      [thrDef=temp_HPD + temp_HRPD]
      };
      
   case "ED":
      {
      [temp_ED=getProperty ("currentED")]
      [temp_ED=floor (temp_ED/(armorPiercing+1))]
      [temp_HED=getProperty ("currentHED")]
      [temp_RED=getProperty ("currentRED")]
      [temp_RED=floor (temp_RED/(armorPiercing+1))]
      [temp_HRED=getProperty ("currentHRED")]
      [temp_HRED=temp_HRED+(cLuck*3)]
      [rDef=temp_RED+temp_HRED]
      [tDef=temp_RED+temp_HRED+temp_ED+temp_HED]
      [rhDef=temp_HRED]
      [thrDef=temp_HED + tempHRED]
      };
   
   case "Sight":
      {
      [temp_SightDef=getProperty ("currentSightDef")]
      [temp_SightDef=floor (temp_SightDef/(armorPiercing+1))]
      [temp_HSightDef=getProperty ("currentHSightDef")]
      [temp_RSightDef=getProperty ("currentRSightDef")]
      [temp_RSightDef=floor (temp_RSightDef/(armorPiercing+1))]
      [temp_HRSightDef=getProperty ("currentHRSightDef")]
      [rDef=temp_RSightDef+temp_HRSightDef]
      [tDef=temp_RSightDef+temp_HRSightDef+temp_SightDef+temp_HSightDef]
      [rhDef=temp_HRSightDef]
      [thrDef=temp_HSightDef + tempHRSightDef]
      };
      
   case "Hearing":
      {
      [temp_HearingDef=getProperty ("currentHearingDef")]
      [temp_HearingDef=floor (temp_HearingDef/(armorPiercing+1))]
      [temp_HHearingDef=getProperty ("currentHHearingDef")]
      [temp_RHearingDef=getProperty ("currentRHearingDef")]
      [temp_RHearingDef=floor (temp_RHearingDef/(armorPiercing+1))]
      [temp_HRHearingDef=getProperty ("currentHRHearingDef")]
      [rDef=temp_RHearingDef+temp_HRHearingDef]
      [tDef=temp_RHearingDef+temp_HRHearingDef+temp_HearingDef+temp_HHearingDef]
      [rhDef=temp_HRHearingDef]
      [thrDef=temp_HHearingDef + tempHRHearingDef]
      };
      
   case "Touch":
      {
      [temp_TouchDef=getProperty ("currentTouchDef")]
      [temp_TouchDef=floor (temp_TouchDef/(armorPiercing+1))]
      [temp_HTouchDef=getProperty ("currentHTouchDef")]
      [temp_RTouchDef=getProperty ("currentRTouchDef")]
      [temp_RTouchDef=floor (temp_RTouchDef/(armorPiercing+1))]
      [temp_HRTouchDef=getProperty ("currentHRTouchDef")]
      [rDef=temp_RTouchDef+temp_HRTouchDef]
      [tDef=temp_RTouchDef+temp_HRTouchDef+temp_TouchDef+temp_HTouchDef]
      [rhDef=temp_HRTouchDef]
      [thrDef=temp_HTouchDef + tempHRTouchDef]
      };
      
   case "Olfactory":
      {
      [temp_SmellDef=getProperty ("currentSmellDef")]
      [temp_SmellDef=floor (temp_SmellDef/(armorPiercing+1))]
      [temp_HSmellDef=getProperty ("currentHSmellDef")]
      [temp_RSmellDef=getProperty ("currentRSmellDef")]
      [temp_RSmellDef=floor (temp_ESmellDef/(armorPiercing+1))]
      [temp_HRSmellDef=getProperty ("currentHRSmellDef")]
      [rDef=temp_RSmellDef+temp_HRSmellDef]
      [tDef=temp_RSmellDef+temp_HRSmellDef+temp_SmellDef+temp_HSmellDef]
      [rhDef=temp_HRSmellDef]
      [thrDef=temp_HSmellDef + tempHRSmellDef]
      };
   
   case "Mental":
      {
      [temp_MDef=getProperty ("currentMDef")]
      [temp_MDef=floor (temp_MDef/(armorPiercing+1))]
      [temp_HMDef=getProperty ("currentHMDef")]
      [temp_RMDef=getProperty ("currentRMDef")]
      [temp_RMDef=floor (temp_RMDef/(armorPiercing+1))]
      [temp_HRMDef=getProperty ("currentHRMDef")]
      [rDef=temp_RMDef+temp_HRMDef]
      [tDef=temp_RMDef+temp_HRMDef+temp_MDef+temp_HMDef]
      [rhDef=temp_HRMDef]
      [thrDef=temp_HMDef + tempHRMDef]
      };
   
   case "Power":
      {
      [temp_PowDef=getProperty ("currentPowDef")]
      [temp_PowDef=floor (temp_PowDef/(armorPiercing+1))]
      [temp_HPowDef=getProperty ("currentHPowDef")]
      [temp_RPowDef=getProperty ("currentRPowDef")]
      [temp_RPowDef=floor (temp_RPowDef/(armorPiercing+1))]
      [temp_HRPowDef=getProperty ("currentHRPowDef")]
      [rDef=temp_RPowDef+temp_HRPowDef]
      [tDef=temp_RPowDef+temp_HRPowDef+temp_PowDef+temp_HPowDef]
      [rhDef=temp_HRPowDef]
      [thrDef=temp_HPowDef + tempHRPowDef]
      };
   
   case "None":
      {
      [tDef=0]
      [rDef=0]
      [rhDef=0]
      [thrDef=0]
      }
   ]


[h, if (penetrating==1 && dmgType==0), CODE: { [adjStunDmg=floor ((stunDmg-thrDef) *dmgMultiStun)] [adjBodyDmg=0] }; {}]
[h, if (penetrating==1 && dmgType==1), CODE: { [adjBodyDmg=floor ((bodyDmg-rhDef) * dmgMultiBody)] [adjStunDmg=adjBodyDmg]  }; {}]

[h, if (penetrating==0 && dmgType==1), CODE: { [adjStunDmg = round ((stunDmg - tDef)  * dmgMultiStun)] [adjBodyDmg=round ((bodyDmg - rDef)  * dmgMultiBody)] }; {}]
[h, if (penetrating==0 && dmgType==0), CODE: { [adjStunDmg = round ((stunDmg - tDef)  * dmgMultiStun)] [adjBodyDmg=round ((bodyDmg - tDef)  * dmgMultiBody)] }; {}]

[h, if (adjBodyDmg < 0): adjBodyDmg=0]
[h, if (adjStunDmg < adjBodyDmg): adjStunDmg = adjBodyDmg]

[h: setProperty ("stunDamage", stunDamage+adjStunDmg)]
[h: setProperty ("bodyDamage", bodyDamage+adjBodyDmg)]


<b>Final Stun Damage: [adjStunDmg]
<br>Final Body Damage: [adjBodyDmg]
<br>
<font size=4><b>Damage Applied</b></font>
<br>
[h, if (dmgType==0): bleedThreshhold=bodyDamage-6 ; bleedThreshhold=bodyDamage]
[h, if (bleedThreshhold <0): bleedThreshhold=0]

[if (useBleed==1), CODE:
   {
   [h: bleedAmount= tbl ("Bleeding", bleedThreshhold)]
   [h: setProperty ("bleedDamage", bleedAmount)]
   };{ [h: bleedAmount=0] }]

[if (useBleed==1 && bleedAmount >0), CODE:{ [h: setState ("bleeding", 1)] [r:"<br>"+token.name+" is bleeding. Damage will start next Segment 1."] }; {}]

<!--IF STUNNING RULES ARE USED, SETS STUNNED STATUS IF STUN DAMAGE EXCEEDS CON SCORE-->

[h, if (adjStunDmg > currentCon && useStunned==1), CODE:
   {
   [stunMessage="<br>"+token.name+" is Stunned"]
   [setState ("stunned", 1)]
   };
   {
   [stunMessage=""]
   }
]
[r: stunMessage]
[h, if (currentStun <=0), CODE:
   {
   [uncMessage="<br>"+token.name+" is Unconscious"]
   [h: setState ("unconscious", 1)]
   };
   {
   [uncMessage=""]
   }
]
[r: uncMessage]

<br>
[h, if (currentBody <= 0), CODE:
   {
   [dieMessage="<br>"+token.name+" is Dying"]
   [h: setState ("dieing", 1)]
   };
   {
   [dieMessage=""]
   }
]

[r: dieMessage]

[if (showHeader==0), CODE: {}; {[r, macro ("CharacterSheetHeader@Lib:Combat"): getSelected()]} ]


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Wed Dec 11, 2013 4:15 am 
Much better :-). Still has the rounding issue, but that is ok.

Time Rider had 30 PD with 25% Damage Reduction. He is hit by 30 stun 15 body PD attack. It has him taking 11 Stun 0 Body.

Should be 12 Stun 0 body. (75% of 15 =12.)

Also with the Express example. I did the same attack. Express has 20 PD, I applied 30 stun 12 Body , now it hits 21 Stun and 3 body. Should be 20 Stun and 2 body.

Optionw


Top
 Profile  
 
User avatar  Offline
Dragon
 
Joined: Fri Sep 21, 2007 5:10 pm
Posts: 439
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Wed Dec 11, 2013 6:58 pm 
I think I see the problem. I believe that I went the wrong way. Try changing wherever it says "round" (follows general rounding rules) or "floor" (rounds down) to "ceil" (rounds up). See how that works for you. Let me know. I hope it is that simple.


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Thu Dec 12, 2013 3:09 am 
Tried the ceil instead of the "round" and "Floor", didn't work. I applied 30 PD Stun, 12 PD Body AP to a def of 30 PD. Results came out 14 Stun and 1 body. Should have been 15 stun 2 body.


Top
 Profile  
 
User avatar  Offline
Dragon
 
Joined: Fri Sep 21, 2007 5:10 pm
Posts: 439
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Thu Dec 12, 2013 9:20 am 
Okay, now try "floor" on each one. :)

The non-hardened defenses had "round" as the method. If I would have been thinking, I would have realized that standard rounding rules round up at >=5.

Tip: Cut all the text to a text editor. Search and replace all instances of ceil with floor. Copy all the text back to the macro. It will be quicker.


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Thu Dec 12, 2013 11:33 am 
Ok, did the switch to floor, didn't work. Express has 20 PD . Applied 30 stun 12 body AP attack. output 21 stun 3 body. Should be 20 Stun 2 body.

Optionw


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Thu Dec 12, 2013 11:42 am 
ah huh! Express' Def was 11 PD 9 rPD for a total of 20. The output when I applied the 30 Stun 12 Body AP, was 21 Stun 3 Body. Then I thought to change the def a bit to 10 PD and 10 rPD for a total of 20. The output when I applied the 30 Stun 12 Body AP, was 20 Stun 2 Body. So it has something to do with the way it is calculating from the Defenses.

Optionw


Top
 Profile  
 
User avatar  Offline
Dragon
 
Joined: Fri Sep 21, 2007 5:10 pm
Posts: 439
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Thu Dec 12, 2013 8:23 pm 
Figured out what is going on. It is figuring each type of defense separately. For example, the 11 PD is being figured as 11/2=5.5 rounded up to 6 or down to 5. Then it figures rPD. In your example, 9/2=4.5 rounded up to 5 or down to 4. Added together, they add up to either 11 or 9. From your Body damage of 12, that means the final damage is either going to be 1 or 3, not the 2 you are expecting. There is no easy way to fix this and still maintain the differentiated defenses (Hardened Normal and Resistant plus Normal and Resistant without Hardening). I can kludge it by having Normal Defenses round up and Resistant Defenses round down. That outputs as you would expect for your example. I am not sure if there are any unintended consequences down the road though.

If you decide to go that route, in each DefType set the Normal defense to ceil and the Resistant defense to floor.

Example:
Code:
case "PD":
      {
      [temp_PD=getProperty ("currentPD")]
      [temp_PD=ceil (temp_PD/(armorPiercing+1))]   <<< this is the Normal Defense
      [temp_HPD=getProperty ("currentHPD")]
      [temp_RPD=getProperty ("currentRPD")]
      [temp_RPD=floor (temp_RPD/(armorPiercing+1))]  <<< this is the Resistant Defense
      [temp_HRPD=getProperty ("currentHRPD")]
      [temp_HRPD=temp_HRPD+(cLuck*3)]
      [rDef=temp_RPD+temp_HRPD]
      [tDef=temp_RPD+temp_HRPD+temp_PD+temp_HPD]
      [rhDef=temp_HRPD]
      [thrDef=temp_HPD + temp_HRPD]
      };


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Fri Dec 13, 2013 3:30 am 
Yes, thanks. I understand it now. :-)


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Fri Feb 07, 2014 2:02 am 
Hello Again, :-) I have a question. I don't use the initiative Window, but I really like the GM Stat Sheet. My only problem is I would like it to sort the characters by highest Initiative that way it would help me a lot as a initiative guide. Would that be hard to input? I really have had way to many issues with the current Initiative window and it still freezes my players turns, even when not using it.

Optionw


Top
 Profile  
 
User avatar  Offline
Dragon
 
Joined: Fri Sep 21, 2007 5:10 pm
Posts: 439
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Sat Feb 08, 2014 4:12 pm 
Should not be too hard. Should be a simple matter of pulling each token's initiative score and adding another column. Give me a couple of days and you should have it.

Edit: I actually took a second an re-read your post. That might be a little more difficult to accomplish. Still possible I think. Let me take a closer look.


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Sun Feb 23, 2014 9:39 pm 
Any luck with this? :-)
if not that's cool, you've help me so much in the past.

Optionw


Top
 Profile  
 
 Offline
Giant
 
Joined: Tue May 29, 2012 9:07 pm
Posts: 102
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Fri Feb 28, 2014 2:23 pm 
Hello Again, I also have another question...is it possible to have the Macro Access Bar show the actions on top of each other rather than to the side? :-)

Optionw


Top
 Profile  
 
User avatar  Offline
Dragon
 
Joined: Fri Sep 21, 2007 5:10 pm
Posts: 439
 Post subject: Re: Hero 6th Edition Framework
PostPosted: Sat Mar 01, 2014 3:45 pm 
OptionW wrote:
Any luck with this? :-)
if not that's cool, you've help me so much in the past.

Optionw

Truthfully, I have not looked too deeply after some initial failures. I mean, I can pull up the Initiative of each person, but I can only sort by Initiative, not Initiative + Name. At least, I haven't figured it out yet.


Top
 Profile  
 
Display posts from previous:  Sort by  
Reply to topic  [ 491 posts ]  Go to page Previous  1 ... 28, 29, 30, 31, 32, 33  Next

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:

Who is online

In total there are 2 users online :: 0 registered, 0 hidden and 2 guests (based on users active over the past 5 minutes)
Most users ever online was 243 on Sun Nov 04, 2012 6:14 am

Users browsing this forum: No registered users and 2 guests





Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

Style based on Andreas08 by Andreas Viklund

Style by Elizabeth Shulman