ps2census
Version:
Client to connect to the PS2 Event Stream websocket.
21 lines • 781 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.GainExperience = void 0;
const character_event_1 = require("./base/character.event");
class GainExperience extends character_event_1.CharacterEvent {
constructor(...params) {
super(...params);
this.emit = 'gainExperience';
this.amount = Number.parseInt(params[GainExperience.DATA].amount, 10);
}
async other() {
if (this.other_id.length == 19)
return this.client.characterManager.fetch(this.character_id);
return Promise.resolve(undefined);
}
toHash() {
return `GainExperience:${this.character_id}:${this.timestamp}`;
}
}
exports.GainExperience = GainExperience;
//# sourceMappingURL=gain-experience.event.js.map