Apply suggestions from code review

Co-authored-by: NightKev <34855794+DayKev@users.noreply.github.com>
This commit is contained in:
Mumble 2024-09-25 19:18:16 -07:00 committed by GitHub
parent 8caa39f27c
commit 2d09c5c2c1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 9 additions and 9 deletions

View File

@ -2590,7 +2590,7 @@ export class ImprisonTag extends MoveRestrictionBattlerTag {
} }
/** /**
* Battler Tag that applies the effects of Syrup Bomb to the target Pokemon * Battler Tag that applies the effects of Syrup Bomb to the target Pokemon.
* For three turns, starting from the turn of hit, at the end of each turn, the target Pokemon's speed will decrease by 1. * For three turns, starting from the turn of hit, at the end of each turn, the target Pokemon's speed will decrease by 1.
* The tag can also expire by taking the target Pokemon off the field. * The tag can also expire by taking the target Pokemon off the field.
*/ */
@ -2600,7 +2600,7 @@ export class SyrupBombTag extends BattlerTag {
} }
/** /**
* Adds the Syrup Bomb battler tag to the target Pokemon * Adds the Syrup Bomb battler tag to the target Pokemon.
* In addition, this also contains a check for a pre-existing Syrup Bomb tag on the target Pokemon to determine whether the tag should be applied or not * In addition, this also contains a check for a pre-existing Syrup Bomb tag on the target Pokemon to determine whether the tag should be applied or not
* @param {Pokemon} pokemon the target Pokemon * @param {Pokemon} pokemon the target Pokemon
*/ */

View File

@ -85,5 +85,5 @@ export enum BattlerTagType {
TORMENT = "TORMENT", TORMENT = "TORMENT",
TAUNT = "TAUNT", TAUNT = "TAUNT",
IMPRISON = "IMPRISON", IMPRISON = "IMPRISON",
SYRUP_BOMB = "SYRUP_BOMB" SYRUP_BOMB = "SYRUP_BOMB",
} }

View File

@ -6,7 +6,7 @@ import { BattlerTagType } from "#enums/battler-tag-type";
import { Stat } from "#enums/stat"; import { Stat } from "#enums/stat";
import GameManager from "#test/utils/gameManager"; import GameManager from "#test/utils/gameManager";
import Phaser from "phaser"; import Phaser from "phaser";
import { afterEach, beforeAll, beforeEach, describe, expect, test, vi } from "vitest"; import { afterEach, beforeAll, beforeEach, describe, expect, it, vi } from "vitest";
describe("Moves - SYRUP BOMB", () => { describe("Moves - SYRUP BOMB", () => {
let phaserGame: Phaser.Game; let phaserGame: Phaser.Game;
@ -36,7 +36,7 @@ describe("Moves - SYRUP BOMB", () => {
//Bulbapedia Reference: https://bulbapedia.bulbagarden.net/wiki/syrup_bomb_(move) //Bulbapedia Reference: https://bulbapedia.bulbagarden.net/wiki/syrup_bomb_(move)
test("decreases the target Pokemon's speed stat once per turn for 3 turns", it("decreases the target Pokemon's speed stat once per turn for 3 turns",
async () => { async () => {
await game.startBattle([Species.MAGIKARP]); await game.startBattle([Species.MAGIKARP]);
@ -60,7 +60,7 @@ describe("Moves - SYRUP BOMB", () => {
} }
); );
test("does not affect Pokemon with the ability Bulletproof", it("does not affect Pokemon with the ability Bulletproof",
async () => { async () => {
game.override.enemyAbility(Abilities.BULLETPROOF); game.override.enemyAbility(Abilities.BULLETPROOF);
await game.startBattle([Species.MAGIKARP]); await game.startBattle([Species.MAGIKARP]);
@ -69,7 +69,7 @@ describe("Moves - SYRUP BOMB", () => {
game.move.select(Moves.SYRUP_BOMB); game.move.select(Moves.SYRUP_BOMB);
await game.toNextTurn(); await game.toNextTurn();
expect(targetPokemon.getMaxHp()).toBe(targetPokemon.hp); expect(targetPokemon.isFullHp()).toBe(true);
expect(targetPokemon.getTag(BattlerTagType.SYRUP_BOMB)).toBeUndefined(); expect(targetPokemon.getTag(BattlerTagType.SYRUP_BOMB)).toBeUndefined();
expect(targetPokemon.getStatStage(Stat.SPD)).toBe(0); expect(targetPokemon.getStatStage(Stat.SPD)).toBe(0);
} }