fix recharge show current red / blue life during combat, skip if 0 recharge and apply css

This commit is contained in:
Mashy
2019-10-02 16:06:39 +10:00
parent 16d319c706
commit 962b72b85f
3 changed files with 45 additions and 18 deletions
+4 -1
View File
@@ -177,7 +177,10 @@ function getText(resolution, sequence) {
if (type === 'Recharge') {
const { red, blue } = event;
return { text: [`+${red}R ${blue}B`, ''], css: '' };
if (red > 0 && blue > 0) return { text: [`+${red}R +${blue}B`, ''], css: 'purple-damage' };
if (red > 0) return { text: [`+${red}R`, ''], css: 'red-damage' };
if (blue > 0) return { text: [`+${blue}B`, ''], css: 'blue-damage' };
return nullText;
}
if (type === 'Removal') {