Samarium
I successfully updated dependencies,
but unfortunately, issue persists.
I prepared a branch if you want to reproduce: title-screen-integration
I save data on level-up (to gain level just kill 2 mobs with C button):
onLevelUp(player: RpgPlayer, leveledUpBy: number) {
player.showAnimation('level-up', 'default');
player.allRecovery();
player.save();
},
Then I refresh the page, login in and I am getting the same error: An error has occurred
without any error in console :/
I have this dynamic database for items with custom properties:
import { v4 } from 'uuid';
import Shield from './../../../item/Shield';
import { RpgPlayer } from '@rpgjs/server';
export default function CircleShield() {
@Shield({
id: v4(),
name: 'Shield',
graphic: 'shield',
price: 100,
pdef: Math.round(Math.random() * 5) + 3,
})
class CircleShield {
}
return CircleShield;
}
and also I added custom properties for player:
declare module '@rpgjs/server' {
export interface RpgPlayer {
inventoryGui?: Gui;
isInventoryOpened: boolean;
profileGui?: Gui;
profileGuiOpened: boolean;
inventory?: Backpacks,
}
}