Fix #73 : Power damage type
This commit is contained in:
parent
18a69ba993
commit
9394e0e851
@ -1758,7 +1758,7 @@ export class PegasusActor extends Actor {
|
|||||||
processSizeBonus( rollData) {
|
processSizeBonus( rollData) {
|
||||||
if ( rollData.defenderTokenId) {
|
if ( rollData.defenderTokenId) {
|
||||||
let diffSize = rollData.defenderSize - this.system.biodata.sizenum+this.system.biodata.sizebonus
|
let diffSize = rollData.defenderSize - this.system.biodata.sizenum+this.system.biodata.sizebonus
|
||||||
console.log("Diffsize", diffSize)
|
//console.log("Diffsize", diffSize)
|
||||||
if( rollData.subKey == "melee-atk" || rollData.subKey == "ranged-atk") {
|
if( rollData.subKey == "melee-atk" || rollData.subKey == "ranged-atk") {
|
||||||
if ( diffSize > 0) {
|
if ( diffSize > 0) {
|
||||||
rollData.effectsList.push({ label: "Size Bonus", type: "effect", applied: false, isdynamic: true, value: diffSize })
|
rollData.effectsList.push({ label: "Size Bonus", type: "effect", applied: false, isdynamic: true, value: diffSize })
|
||||||
@ -1774,7 +1774,7 @@ export class PegasusActor extends Actor {
|
|||||||
rollData.effectsList.push({ label: "Size Bonus", type: "effect", applied: false, isdynamic: true, value: Math.abs(diffSize) })
|
rollData.effectsList.push({ label: "Size Bonus", type: "effect", applied: false, isdynamic: true, value: Math.abs(diffSize) })
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if( rollData.subKey == "melee-dmg" || rollData.subKey == "ranged-dmg") {
|
if( rollData.subKey == "melee-dmg" || rollData.subKey == "ranged-dmg" || rollData.subKey == "power-dmg") {
|
||||||
if ( diffSize < 0) {
|
if ( diffSize < 0) {
|
||||||
rollData.effectsList.push({ label: "Size Bonus", type: "effect", applied: false, isdynamic: true, value: Math.abs(diffSize) })
|
rollData.effectsList.push({ label: "Size Bonus", type: "effect", applied: false, isdynamic: true, value: Math.abs(diffSize) })
|
||||||
}
|
}
|
||||||
|
@ -566,6 +566,7 @@
|
|||||||
"activatedtext": "",
|
"activatedtext": "",
|
||||||
"deactivatedtext": "",
|
"deactivatedtext": "",
|
||||||
"powerlevelcost": "",
|
"powerlevelcost": "",
|
||||||
|
"powerdamagetype": "",
|
||||||
"dmgroll": false,
|
"dmgroll": false,
|
||||||
"dmgstatistic": "",
|
"dmgstatistic": "",
|
||||||
"description": ""
|
"description": ""
|
||||||
|
@ -45,6 +45,10 @@
|
|||||||
{{/if}}
|
{{/if}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
{{#if power}}
|
||||||
|
<li>Power Damage type : {{power.system.powerdamagetype}}</li>
|
||||||
|
{{/if}}
|
||||||
|
|
||||||
{{#if isResistance}}
|
{{#if isResistance}}
|
||||||
<li><strong>Defense Result : {{finalScore}}</strong>
|
<li><strong>Defense Result : {{finalScore}}</strong>
|
||||||
{{else}}
|
{{else}}
|
||||||
|
@ -112,6 +112,10 @@
|
|||||||
{{/select}}
|
{{/select}}
|
||||||
</select>
|
</select>
|
||||||
</li>
|
</li>
|
||||||
|
<li class="flexrow"><label class="generic-label">Power Damage Type</label>
|
||||||
|
<input type="text" class="padd-right" name="system.powerdamagetype" value="{{data.powerdamagetype}}"
|
||||||
|
data-dtype="String" />
|
||||||
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
<li class="flexrow"><label class="generic-label">When purchased display text</label>
|
<li class="flexrow"><label class="generic-label">When purchased display text</label>
|
||||||
|
Loading…
Reference in New Issue
Block a user