diff --git a/src/data/dialogue.ts b/src/data/dialogue.ts index e9a11dbf3..3e7be0dbc 100644 --- a/src/data/dialogue.ts +++ b/src/data/dialogue.ts @@ -504,8 +504,8 @@ export const trainerTypeDialogue = { $@c{smile_eclosed}It's like I can barely remember the memories we cherished together. $@c{smile_ehalf}Were they even real? They seem so far away now… $@c{angry_mopen}You need to keep pushing, because if you don't, it will never end. You're the only one who can do this. - $I… don't know what all this means… but I feel it's true. - $If you can't defeat me here and now, you won't stand a chance.` + $@c{smile_ehalf}I… don't know what all this means… but I feel it's true. + $@c{neutral}If you can't defeat me here and now, you won't stand a chance.` ], victory: [ `@c{smile_ehalf}I… I think I fulfilled my purpose… diff --git a/src/field/pokemon.ts b/src/field/pokemon.ts index 36c7bfde6..9ab17855c 100644 --- a/src/field/pokemon.ts +++ b/src/field/pokemon.ts @@ -752,6 +752,7 @@ export default abstract class Pokemon extends Phaser.GameObjects.Container { return this.isTerastallized() ? 2 : 1; const types = this.getTypes(true, true); let multiplier = getTypeDamageMultiplier(moveType, types[0]) * (types.length > 1 ? getTypeDamageMultiplier(moveType, types[1]) : 1) as TypeDamageMultiplier; + // Handle strong winds lowering effectiveness of types super effective against pure flying if (this.scene.arena.weather?.weatherType === WeatherType.STRONG_WINDS && !this.scene.arena.weather.isEffectSuppressed(this.scene) && multiplier >= 2 && this.isOfType(Type.FLYING) && getTypeDamageMultiplier(moveType, Type.FLYING) === 2) multiplier /= 2; return multiplier; diff --git a/src/ui/message-ui-handler.ts b/src/ui/message-ui-handler.ts index 7fd61c829..dc4fb9ce0 100644 --- a/src/ui/message-ui-handler.ts +++ b/src/ui/message-ui-handler.ts @@ -45,8 +45,23 @@ export default abstract class MessageUiHandler extends AwaitableUiHandler { soundMap.set(actionMatch.index, actionMatch[2]); break; } - text = text.slice(0, actionMatch.index) + text.slice(actionMatch.index + actionMatch[2].length + 4); + + // Predetermine overflow line breaks to avoid words breaking while displaying + const textWords = text.split(' '); + let lastLineCount = 1; + let newText = textWords[0]; + for (let w = 1; w < textWords.length; w++) { + const nextWordText = `${newText} ${textWords[w]}`; + const lineCount = this.message.runWordWrap(nextWordText).split(/\n/g).length; + if (lineCount > lastLineCount) { + lastLineCount = lineCount; + newText = `${newText}\n${textWords[w]}`; + } else + newText = nextWordText; + } + + text = newText; } if (this.textTimer) { this.textTimer.remove();