Various Error Fixes (#1580)

* Add @types/node to the package lock to resolve node_module errors

Devs will need to run npm install --save-dev @types/node on their end as well

* Final Various Fixes
This commit is contained in:
Benjamin Odom 2024-05-29 18:14:32 -05:00 committed by GitHub
parent 8e157edce9
commit 700ccf3afc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
9 changed files with 10 additions and 9 deletions

View File

@ -129,6 +129,7 @@ export default class BattleScene extends SceneBase {
public fusionPaletteSwaps: boolean = true; public fusionPaletteSwaps: boolean = true;
public enableTouchControls: boolean = false; public enableTouchControls: boolean = false;
public enableVibration: boolean = false; public enableVibration: boolean = false;
public gamepadSupport: boolean = false;
public abSwapped: boolean = false; public abSwapped: boolean = false;
public disableMenu: boolean = false; public disableMenu: boolean = false;
@ -300,7 +301,7 @@ export default class BattleScene extends SceneBase {
this.fieldUI = fieldUI; this.fieldUI = fieldUI;
const transition = this.make.rexTransitionImagePack({ const transition = (this.make as any).rexTransitionImagePack({
x: 0, x: 0,
y: 0, y: 0,
scale: 6, scale: 6,

View File

@ -566,7 +566,7 @@ export default class PokemonSpecies extends PokemonSpeciesForm implements Locali
catchRate: integer, baseFriendship: integer, baseExp: integer, growthRate: GrowthRate, malePercent: number, catchRate: integer, baseFriendship: integer, baseExp: integer, growthRate: GrowthRate, malePercent: number,
genderDiffs: boolean, canChangeForm?: boolean, ...forms: PokemonForm[]) { genderDiffs: boolean, canChangeForm?: boolean, ...forms: PokemonForm[]) {
super(type1, type2, height, weight, ability1, ability2, abilityHidden, baseTotal, baseHp, baseAtk, baseDef, baseSpatk, baseSpdef, baseSpd, super(type1, type2, height, weight, ability1, ability2, abilityHidden, baseTotal, baseHp, baseAtk, baseDef, baseSpatk, baseSpdef, baseSpd,
catchRate, baseFriendship, baseExp, genderDiffs); catchRate, baseFriendship, baseExp, genderDiffs, false);
this.speciesId = id; this.speciesId = id;
this.formIndex = 0; this.formIndex = 0;
this.generation = generation; this.generation = generation;

View File

@ -691,7 +691,7 @@ export class TrainerConfig {
initI18n(); initI18n();
} }
// Check if the female version exists in the i18n file // Check if the female version exists in the i18n file
if (i18next.exists(`trainerClasses:${this.name.toLowerCase().replace()}`)) { if (i18next.exists(`trainerClasses:${this.name.toLowerCase()}`)) {
// If it does, return // If it does, return
return ret + "_female"; return ret + "_female";
} else { } else {

View File

@ -421,7 +421,7 @@ export default class Trainer extends Phaser.GameObjects.Container {
this.scene.arena.findTagsOnSide(t => t instanceof ArenaTrapTag, ArenaTagSide.ENEMY).map(t => score *= (t as ArenaTrapTag).getMatchupScoreMultiplier(p)); this.scene.arena.findTagsOnSide(t => t instanceof ArenaTrapTag, ArenaTagSide.ENEMY).map(t => score *= (t as ArenaTrapTag).getMatchupScoreMultiplier(p));
} }
return [party.indexOf(p), score]; return [party.indexOf(p), score];
}); }) as [integer, integer][];
return partyMemberScores; return partyMemberScores;
} }

View File

@ -12,7 +12,7 @@ export default class AbilityBar extends Phaser.GameObjects.Container {
private abilityNameText: Phaser.GameObjects.Text; private abilityNameText: Phaser.GameObjects.Text;
private tween: Phaser.Tweens.Tween; private tween: Phaser.Tweens.Tween;
private autoHideTimer: number; private autoHideTimer: NodeJS.Timeout;
public shown: boolean; public shown: boolean;

View File

@ -12,7 +12,7 @@ export default class CandyBar extends Phaser.GameObjects.Container {
private speciesId: Species; private speciesId: Species;
private tween: Phaser.Tweens.Tween; private tween: Phaser.Tweens.Tween;
private autoHideTimer: number; private autoHideTimer: NodeJS.Timeout;
public shown: boolean; public shown: boolean;

View File

@ -87,7 +87,7 @@ export function addTextInputObject(scene: Phaser.Scene, x: number, y: number, wi
return ret; return ret;
} }
function getTextStyleOptions(style: TextStyle, uiTheme: UiTheme, extraStyleOptions?: Phaser.Types.GameObjects.Text.TextStyle): [ Phaser.Types.GameObjects.Text.TextStyle | InputText.IConfig, string, integer ] { function getTextStyleOptions(style: TextStyle, uiTheme: UiTheme, extraStyleOptions?: Phaser.Types.GameObjects.Text.TextStyle): [ Phaser.Types.GameObjects.Text.TextStyle | InputText.IConfig, string, number, number ] {
const lang = i18next.language; const lang = i18next.language;
let shadowXpos = 4; let shadowXpos = 4;
let shadowYpos = 5; let shadowYpos = 5;

View File

@ -14,7 +14,7 @@ export default class TitleUiHandler extends OptionSelectUiHandler {
private splashMessage: string; private splashMessage: string;
private splashMessageText: Phaser.GameObjects.Text; private splashMessageText: Phaser.GameObjects.Text;
private titleStatsTimer: number; private titleStatsTimer: NodeJS.Timeout;
constructor(scene: BattleScene, mode: Mode = Mode.TITLE) { constructor(scene: BattleScene, mode: Mode = Mode.TITLE) {
super(scene, mode); super(scene, mode);

View File

@ -5,7 +5,7 @@ import { Mode } from "./ui";
import { updateUserInfo } from "#app/account"; import { updateUserInfo } from "#app/account";
export default class UnavailableModalUiHandler extends ModalUiHandler { export default class UnavailableModalUiHandler extends ModalUiHandler {
private reconnectTimer: number; private reconnectTimer: NodeJS.Timeout;
private reconnectDuration: number; private reconnectDuration: number;
private reconnectCallback: () => void; private reconnectCallback: () => void;