Adrian T 5d358fc57f
[Enhancement] Refactor egg counter (#1996)
* refactor egg counter

* add documentation
2024-06-10 20:20:00 -05:00

22 lines
483 B
TypeScript

export enum EggEventType {
/**
* Triggers when egg count is changed.
* @see {@linkcode MoveUsedEvent}
*/
EGG_COUNT_CHANGED = "onEggCountChanged"
}
/**
* Container class for {@linkcode EggEventType.EGG_COUNT_CHANGED} events
* @extends Event
*/
export class EggCountChangedEvent extends Event {
/** The updated egg count. */
public eggCount: integer;
constructor(eggCount: number) {
super(EggEventType.EGG_COUNT_CHANGED);
this.eggCount = eggCount;
}
}