Fix text disappearing while in transferMode (#3740)
Co-authored-by: flx-sta <50131232+flx-sta@users.noreply.github.com>
This commit is contained in:
parent
e0bcb2ef27
commit
35f522fd99
|
@ -5,7 +5,7 @@ import { Command } from "./command-ui-handler";
|
|||
import MessageUiHandler from "./message-ui-handler";
|
||||
import { Mode } from "./ui";
|
||||
import * as Utils from "../utils";
|
||||
import { PokemonBaseStatModifier, PokemonFormChangeItemModifier, PokemonHeldItemModifier, SwitchEffectTransferModifier } from "../modifier/modifier";
|
||||
import { PokemonFormChangeItemModifier, PokemonHeldItemModifier, SwitchEffectTransferModifier } from "../modifier/modifier";
|
||||
import { allMoves, ForceSwitchOutAttr } from "../data/move";
|
||||
import { getGenderColor, getGenderSymbol } from "../data/gender";
|
||||
import { StatusEffect } from "../data/status-effect";
|
||||
|
@ -989,14 +989,8 @@ export default class PartyUiHandler extends MessageUiHandler {
|
|||
optionText.setOrigin(0, 0);
|
||||
|
||||
/** For every item that has stack bigger than 1, display the current quantity selection */
|
||||
if (this.partyUiMode === PartyUiMode.MODIFIER_TRANSFER && this.transferQuantitiesMax[option] > 1) {
|
||||
const itemModifier = itemModifiers[option];
|
||||
|
||||
/** Not sure why getMaxHeldItemCount had an error, but it only checks the Pokemon parameter if the modifier is PokemonBaseStatModifier */
|
||||
if (itemModifier === undefined || itemModifier instanceof PokemonBaseStatModifier) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (this.partyUiMode === PartyUiMode.MODIFIER_TRANSFER && this.transferQuantitiesMax[option] > 1 && !this.transferMode && itemModifier !== undefined && itemModifier.type.name === optionName) {
|
||||
let amountText = ` (${this.transferQuantities[option]})`;
|
||||
|
||||
/** If the amount held is the maximum, display the count in red */
|
||||
|
|
Loading…
Reference in New Issue