[Bug/Enhancement] Fix stat change color (#1461)
* fix: use orange for stat increase and blue for stat decrease like in main games * fix: run eslint
This commit is contained in:
parent
dfdb1909f1
commit
73d3d8648f
|
@ -3092,7 +3092,10 @@ export class StatChangePhase extends PokemonPhase {
|
||||||
const tileWidth = 156 * this.scene.field.scale * pokemon.getSpriteScale();
|
const tileWidth = 156 * this.scene.field.scale * pokemon.getSpriteScale();
|
||||||
const tileHeight = 316 * this.scene.field.scale * pokemon.getSpriteScale();
|
const tileHeight = 316 * this.scene.field.scale * pokemon.getSpriteScale();
|
||||||
|
|
||||||
const statSprite = this.scene.add.tileSprite(tileX, tileY, tileWidth, tileHeight, "battle_stats", filteredStats.length > 1 ? "mix" : BattleStat[filteredStats[0]].toLowerCase());
|
// On increase, show the red sprite located at ATK
|
||||||
|
// On decrease, show the blue sprite located at SPD
|
||||||
|
const spriteColor = levels.value >= 1 ? BattleStat[BattleStat.ATK].toLowerCase() : BattleStat[BattleStat.SPD].toLowerCase();
|
||||||
|
const statSprite = this.scene.add.tileSprite(tileX, tileY, tileWidth, tileHeight, "battle_stats", spriteColor);
|
||||||
statSprite.setPipeline(this.scene.fieldSpritePipeline);
|
statSprite.setPipeline(this.scene.fieldSpritePipeline);
|
||||||
statSprite.setAlpha(0);
|
statSprite.setAlpha(0);
|
||||||
statSprite.setScale(6);
|
statSprite.setScale(6);
|
||||||
|
|
Loading…
Reference in New Issue