@wayward/types 2.14.4-beta.dev.20250103.1 → 2.14.4-beta.dev.20250105.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/definitions/game/game/reference/ReferenceManager.d.ts +1 -1
- package/definitions/game/language/dictionary/Message.d.ts +160 -160
- package/definitions/game/ui/component/dropdown/IslandDropdown.d.ts +1 -1
- package/definitions/game/ui/input/InputManager.d.ts +1 -0
- package/definitions/game/ui/screen/screens/game/InspectionsTooltipHandler.d.ts +5 -1
- package/definitions/game/ui/screen/screens/game/ReferenceTooltipHandler.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/dialog/equipment/EquipmentSlotTooltip.d.ts +1 -1
- package/definitions/game/ui/tooltip/Tooltip.d.ts +2 -2
- package/definitions/game/ui/util/ComponentManipulator.d.ts +6 -5
- package/definitions/game/utilities/memory/MemoryLeakDetector.d.ts +7 -1
- package/definitions/utilities/event/EventEmitter.d.ts +4 -1
- package/definitions/utilities/memory/ILifetime.d.ts +5 -1
- package/package.json +1 -1
@@ -53,5 +53,5 @@ export default class ReferenceManager {
|
|
53
53
|
private resolveInternal;
|
54
54
|
inspect<REFTYPE extends ReferenceType>(reference: Reference<REFTYPE>, context?: InfoProviderContext): Inspection<any> | undefined;
|
55
55
|
inspect(reference: Reference, context?: InfoProviderContext): Inspection<any> | undefined;
|
56
|
-
tooltip(reference: Reference, initializer?: (tooltip: Tooltip, handler: ReferenceTooltipHandler) => any, context?: InfoProviderContext): (tooltip: Tooltip) => Promise<
|
56
|
+
tooltip(reference: Reference, initializer?: (tooltip: Tooltip, handler: ReferenceTooltipHandler) => any, context?: InfoProviderContext): (tooltip: Tooltip) => Promise<boolean>;
|
57
57
|
}
|
@@ -55,8 +55,8 @@ declare enum Message {
|
|
55
55
|
ActionDetachContainerDetachContainer = 43,
|
56
56
|
ActionDetachContainerNoDetach = 44,
|
57
57
|
ActionDigTooDeep = 45,
|
58
|
-
|
59
|
-
|
58
|
+
ActionDigWaterFilledHole = 46,
|
59
|
+
ActionDigWaterTooDeep = 47,
|
60
60
|
ActionDisassembleNoItemsSalvaged = 48,
|
61
61
|
ActionDisassembleSalvaged = 49,
|
62
62
|
ActionDismantleSeparated = 50,
|
@@ -586,164 +586,164 @@ declare enum Message {
|
|
586
586
|
Prepare = 574,
|
587
587
|
Prepared = 575,
|
588
588
|
PreservedFood = 576,
|
589
|
-
|
590
|
-
|
591
|
-
|
592
|
-
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
602
|
-
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
611
|
-
|
612
|
-
|
613
|
-
|
614
|
-
|
615
|
-
|
616
|
-
|
617
|
-
|
618
|
-
|
619
|
-
|
620
|
-
|
621
|
-
|
622
|
-
|
623
|
-
|
624
|
-
|
625
|
-
|
626
|
-
|
627
|
-
|
628
|
-
|
629
|
-
|
630
|
-
|
631
|
-
|
632
|
-
|
633
|
-
|
634
|
-
|
635
|
-
|
636
|
-
|
637
|
-
|
638
|
-
|
639
|
-
|
640
|
-
|
641
|
-
|
642
|
-
|
643
|
-
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
660
|
-
|
661
|
-
|
662
|
-
|
663
|
-
|
664
|
-
|
665
|
-
|
666
|
-
|
667
|
-
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
672
|
-
|
673
|
-
|
674
|
-
|
675
|
-
|
676
|
-
|
677
|
-
|
678
|
-
|
679
|
-
|
680
|
-
|
681
|
-
|
682
|
-
|
683
|
-
|
684
|
-
|
685
|
-
|
686
|
-
|
687
|
-
|
688
|
-
|
689
|
-
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
|
694
|
-
|
695
|
-
|
696
|
-
|
697
|
-
|
698
|
-
|
699
|
-
|
700
|
-
|
701
|
-
|
702
|
-
|
703
|
-
|
704
|
-
|
705
|
-
|
706
|
-
|
707
|
-
|
708
|
-
|
709
|
-
|
710
|
-
|
711
|
-
|
712
|
-
|
713
|
-
|
714
|
-
|
715
|
-
|
716
|
-
|
717
|
-
|
718
|
-
|
719
|
-
|
720
|
-
|
721
|
-
|
722
|
-
|
723
|
-
|
724
|
-
|
725
|
-
|
726
|
-
|
727
|
-
|
728
|
-
|
729
|
-
|
730
|
-
|
731
|
-
|
732
|
-
|
733
|
-
|
734
|
-
|
735
|
-
|
736
|
-
|
737
|
-
|
738
|
-
|
739
|
-
|
740
|
-
|
741
|
-
|
742
|
-
|
743
|
-
|
744
|
-
|
745
|
-
|
746
|
-
|
589
|
+
PurifiedWaterInBottom = 577,
|
590
|
+
PurifiedWaterInStill = 578,
|
591
|
+
RandomEventsFire = 579,
|
592
|
+
ReduceLength = 580,
|
593
|
+
RefusedToBeTamed = 581,
|
594
|
+
Repair = 582,
|
595
|
+
RequiredForDisassembly = 583,
|
596
|
+
RequiresFireToBeLit = 584,
|
597
|
+
RequiresYouToBeAround = 585,
|
598
|
+
Resistant = 586,
|
599
|
+
Rest = 587,
|
600
|
+
Rested = 588,
|
601
|
+
Resting = 589,
|
602
|
+
RestingOnGroundNotEffective = 590,
|
603
|
+
RestInterrupted = 591,
|
604
|
+
RestInterruptedDamage = 592,
|
605
|
+
RestInterruptedDying = 593,
|
606
|
+
RestInterruptedLoudNoise = 594,
|
607
|
+
RestInterruptedPain = 595,
|
608
|
+
RestInterruptedStirring = 596,
|
609
|
+
RestInterruptedWaterPoured = 597,
|
610
|
+
RestLongTime = 598,
|
611
|
+
RestModerateTime = 599,
|
612
|
+
RestOnBoat = 600,
|
613
|
+
RestShortTime = 601,
|
614
|
+
RestTime = 602,
|
615
|
+
ReturnedToCivilization = 603,
|
616
|
+
ReturningToCivilizationSetOffAgain = 604,
|
617
|
+
ReturnsToLife = 605,
|
618
|
+
Reverse = 606,
|
619
|
+
Sailing = 607,
|
620
|
+
ScrollMaster = 608,
|
621
|
+
ScrollProvidedNoUsefulInsight = 609,
|
622
|
+
Seawater = 610,
|
623
|
+
SeemsToHaveDrawnEnergy = 611,
|
624
|
+
SetTrapOffButNoDamage = 612,
|
625
|
+
SetUp = 613,
|
626
|
+
ShadowInTheWater = 614,
|
627
|
+
SkillHasRaised = 615,
|
628
|
+
Skills = 616,
|
629
|
+
Sleep = 617,
|
630
|
+
Sleeping = 618,
|
631
|
+
SleepOnBoat = 619,
|
632
|
+
Slept = 620,
|
633
|
+
SlitherSuckerConstricts = 621,
|
634
|
+
SlitherSuckerFailedToRemove = 622,
|
635
|
+
SlitherSuckerFailedToRemoveOuch = 623,
|
636
|
+
SlitherSuckerJumpedOnHead = 624,
|
637
|
+
SolarStill = 625,
|
638
|
+
SomethingInTheWayOf = 626,
|
639
|
+
SomethingInTheWayOfButcherFirst = 627,
|
640
|
+
SomethingInTheWayOfFire = 628,
|
641
|
+
SomethingInTheWayOfFishing = 629,
|
642
|
+
SomethingInTheWayOfPerforming = 630,
|
643
|
+
SomethingInTheWayOfPlacing = 631,
|
644
|
+
SomethingInTheWayOfReleasing = 632,
|
645
|
+
SomethingInTheWayOfSummoning = 633,
|
646
|
+
SomethingInWayOfClosingDoor = 634,
|
647
|
+
SoothedTheirBurnInjuries = 635,
|
648
|
+
SoothedYourBurnInjuries = 636,
|
649
|
+
SortedByCategory = 637,
|
650
|
+
SortedByCraftableOnly = 638,
|
651
|
+
SortedByName = 639,
|
652
|
+
SortedBySkill = 640,
|
653
|
+
SortedByUnlockedTime = 641,
|
654
|
+
StaminaIsFull = 642,
|
655
|
+
StartedFire = 643,
|
656
|
+
StartTravelInWater = 644,
|
657
|
+
StarvingToDeath = 645,
|
658
|
+
StatAmount = 646,
|
659
|
+
StatChangeUnknown = 647,
|
660
|
+
StatGained = 648,
|
661
|
+
StatIncreasing = 649,
|
662
|
+
StatLost = 650,
|
663
|
+
StatQuenched = 651,
|
664
|
+
StatRegained = 652,
|
665
|
+
StatSated = 653,
|
666
|
+
SteppingOn = 654,
|
667
|
+
Still = 655,
|
668
|
+
StillHasNoWaterToPurify = 656,
|
669
|
+
StirredUpClawWorm = 657,
|
670
|
+
StirredUpCreature = 658,
|
671
|
+
StoppedYourBleeding = 659,
|
672
|
+
StopUsingVehicle = 660,
|
673
|
+
SummonedGuardiansByDiggingTreasure = 661,
|
674
|
+
SummonedGuardiansByLockpicking = 662,
|
675
|
+
SummonVoidDwellerItem = 663,
|
676
|
+
SummonVoidDwellerRinging = 664,
|
677
|
+
SummonVoidDwellerShiver = 665,
|
678
|
+
SunNotBrightEnoughToStartFire = 666,
|
679
|
+
SwampWater = 667,
|
680
|
+
Swimming = 668,
|
681
|
+
TakenFromGroundBecomeTamed = 669,
|
682
|
+
TeleportBlocked = 670,
|
683
|
+
Teleported = 671,
|
684
|
+
TheirFist = 672,
|
685
|
+
TheirInventory = 673,
|
686
|
+
ThePlant = 674,
|
687
|
+
ThereIsNoContainerOnTheStill = 675,
|
688
|
+
ThereIsNoSunToStartFire = 676,
|
689
|
+
ThisCannotBeMilked = 677,
|
690
|
+
Throw = 678,
|
691
|
+
ThrownIntoDepths = 679,
|
692
|
+
ThrownIntoObstacle = 680,
|
693
|
+
ThrownIntoVoid = 681,
|
694
|
+
TierGroup = 682,
|
695
|
+
Till = 683,
|
696
|
+
Tilling = 684,
|
697
|
+
TimeIs = 685,
|
698
|
+
TimeIsDawn = 686,
|
699
|
+
TimeIsDaytime = 687,
|
700
|
+
TimeIsDusk = 688,
|
701
|
+
TimeIsNighttime = 689,
|
702
|
+
TimeIsSunrise = 690,
|
703
|
+
TimeIsSunset = 691,
|
704
|
+
ToFight = 692,
|
705
|
+
TooDamaged = 693,
|
706
|
+
TooExhaustedToJump = 694,
|
707
|
+
Touching = 695,
|
708
|
+
TrampledFire = 696,
|
709
|
+
TrampledFireFail = 697,
|
710
|
+
TrampledFirePartial = 698,
|
711
|
+
TrampledIntoGround = 699,
|
712
|
+
TrampleIntoGround = 700,
|
713
|
+
Trampling = 701,
|
714
|
+
TransmogrificationNotPossible = 702,
|
715
|
+
Transmogrified = 703,
|
716
|
+
TrapMissed = 704,
|
717
|
+
TrapStoppedYou = 705,
|
718
|
+
Traveling = 706,
|
719
|
+
Treasure = 707,
|
720
|
+
TreasureIsBlocked = 708,
|
721
|
+
UiActionCannotUseInaccessibleItem = 709,
|
722
|
+
UiActionCannotUseInThisSituation = 710,
|
723
|
+
UiActionCannotUseNoItemHovered = 711,
|
724
|
+
UiActionCannotUseNotInRange = 712,
|
725
|
+
UiActionCannotUseOnThisIsland = 713,
|
726
|
+
UiActionCannotUseRequiresCreature = 714,
|
727
|
+
UiActionCannotUseRequiresDoodad = 715,
|
728
|
+
UiActionCannotUseRequiresItem = 716,
|
729
|
+
UiActionCannotUseRequiresNPC = 717,
|
730
|
+
UiActionCannotUseRequiresVehicle = 718,
|
731
|
+
UiDialogTradeIndicateTradeAlreadyTradedBuyDialogue1 = 719,
|
732
|
+
UiDialogTradeIndicateTradeAlreadyTradedBuyDialogue2 = 720,
|
733
|
+
UiDialogTradeIndicateTradeAlreadyTradedBuyDialogue3 = 721,
|
734
|
+
UiDialogTradeIndicateTradeAlreadyTradedSellDialogue1 = 722,
|
735
|
+
UiDialogTradeIndicateTradeAlreadyTradedSellDialogue2 = 723,
|
736
|
+
UiDialogTradeIndicateTradeAlreadyTradedSellDialogue3 = 724,
|
737
|
+
UiDialogTradeIndicateTradeTooMuchTradesDialogue1 = 725,
|
738
|
+
UiDialogTradeIndicateTradeTooMuchTradesDialogue2 = 726,
|
739
|
+
UiDialogTradeIndicateTradeTooMuchTradesDialogue3 = 727,
|
740
|
+
UnhitchCreature = 728,
|
741
|
+
Unknown = 729,
|
742
|
+
Unlimited = 730,
|
743
|
+
UnlockedChest = 731,
|
744
|
+
UnpurifiedFreshWater = 732,
|
745
|
+
UnpurifiedWaterInStill = 733,
|
746
|
+
UnpurifiedWaterInTop = 734,
|
747
747
|
Use = 735,
|
748
748
|
UsingBareHands = 736,
|
749
749
|
VehicleDefense = 737,
|
@@ -20,7 +20,7 @@ export default class IslandDropdown<OTHER_OPTIONS extends string = never> extend
|
|
20
20
|
protected getTranslation(islandId: IslandId): TranslationImpl;
|
21
21
|
protected sortEnumOptions(o1: IDropdownSortableOption<string>, o2: IDropdownSortableOption<string>): number;
|
22
22
|
protected getGroupName(biome: BiomeType): string;
|
23
|
-
protected optionTooltipInitializer: (tooltip: Tooltip, option: string) => Promise<
|
23
|
+
protected optionTooltipInitializer: (tooltip: Tooltip, option: string) => Promise<boolean> | undefined;
|
24
24
|
protected shouldIncludeOtherOptionsInGroupFilter(): boolean;
|
25
25
|
protected isInGroup(islandId: IslandId, biome: BiomeType): boolean;
|
26
26
|
protected getGroups(): BiomeType[];
|
@@ -74,6 +74,7 @@ export declare class GlobalMouseInfo extends EventEmitter.Host<IGlobalMouseInfoE
|
|
74
74
|
* @param recalcTarget Whether to recalculate the target before this operation. Defaults to `false`
|
75
75
|
*/
|
76
76
|
isTarget<W extends Component | Element | string | undefined>(what?: W, recalcTarget?: boolean): (W extends Component ? W : HTMLElement) | undefined;
|
77
|
+
clearTarget(target?: Element): void;
|
77
78
|
private _updateTarget;
|
78
79
|
}
|
79
80
|
interface IInputInfoEvents {
|
@@ -28,7 +28,11 @@ export interface IInspectionsTooltipHandlerEvents<INSPECTIONS_LIST extends Inspe
|
|
28
28
|
export default abstract class InspectionsTooltipHandler<INSPECTIONS_LIST extends InspectionsList, TOOLTIP_ARGS extends any[] = []> extends EventEmitter.Host<IInspectionsTooltipHandlerEvents<INSPECTIONS_LIST, TOOLTIP_ARGS>> {
|
29
29
|
protected current: IInspectionsTooltipHandlerCurrent<INSPECTIONS_LIST, TOOLTIP_ARGS> | undefined;
|
30
30
|
private lastMousePosition?;
|
31
|
-
|
31
|
+
/**
|
32
|
+
* Initializes tooltips
|
33
|
+
* @returns True if the tooltip was initialized. False if it was removed or replaced before so.
|
34
|
+
*/
|
35
|
+
initializeTooltip(tooltip: Tooltip, ...args: TOOLTIP_ARGS): Promise<boolean>;
|
32
36
|
remove(tooltip?: IInspectionsTooltipHandlerCurrent<INSPECTIONS_LIST, TOOLTIP_ARGS> | undefined): void;
|
33
37
|
onInitInspections(handler: (inspections: INSPECTIONS_LIST) => any): void;
|
34
38
|
protected abstract initializeInspections(...args: TOOLTIP_ARGS): INSPECTIONS_LIST | undefined;
|
@@ -21,7 +21,7 @@ export default class ReferenceTooltipHandler extends InspectionsTooltipHandler<R
|
|
21
21
|
private readonly reference;
|
22
22
|
private readonly initializer?;
|
23
23
|
constructor(context: InfoProviderContext, reference: Reference, initializer?: ((tooltip: Tooltip, handler: ReferenceTooltipHandler) => any) | undefined);
|
24
|
-
initializeTooltip(tooltip: Tooltip): Promise<
|
24
|
+
initializeTooltip(tooltip: Tooltip): Promise<boolean>;
|
25
25
|
protected initializeInspections(): ReferenceInspectionsList;
|
26
26
|
protected initializeHints(hints: InspectionTooltipHints): void;
|
27
27
|
}
|
@@ -24,7 +24,7 @@ export declare enum EquipmentSlotTooltipClasses {
|
|
24
24
|
Hints = "game-dialog-equipment-slot-tooltip-hints"
|
25
25
|
}
|
26
26
|
export default class EquipmentSlotTooltipHandler extends InspectionsTooltipHandler<EquipmentSlotInspectionsList, [slot: EquipType]> {
|
27
|
-
initializeTooltip(tooltip: Tooltip, slot: EquipType): Promise<
|
27
|
+
initializeTooltip(tooltip: Tooltip, slot: EquipType): Promise<boolean>;
|
28
28
|
protected initializeInspections(slot: EquipType): EquipmentSlotInspectionsList;
|
29
29
|
protected initializeHints(hints: InspectionTooltipHints, slot: EquipType): void;
|
30
30
|
private onSlotChanged;
|
@@ -43,9 +43,9 @@ export default class Tooltip extends Component {
|
|
43
43
|
private forceShown;
|
44
44
|
private maxWidth;
|
45
45
|
private hasSetPosition;
|
46
|
-
initialized?: Promise<
|
46
|
+
initialized?: Promise<boolean>;
|
47
47
|
context?: InfoProviderContext;
|
48
|
-
constructor(source: Component | HTMLElement, initialize?: (tooltip: Tooltip) =>
|
48
|
+
constructor(source: Component | HTMLElement, initialize?: (tooltip: Tooltip) => Promise<boolean>);
|
49
49
|
protected onRemove(): void;
|
50
50
|
setSecondary(): this;
|
51
51
|
setForceShown(forceShown?: boolean): this;
|
@@ -8,6 +8,7 @@
|
|
8
8
|
* Wayward is a copyrighted and licensed work. Modification and/or distribution of any source files is prohibited. If you wish to modify the game in any way, please refer to the modding guide:
|
9
9
|
* https://github.com/WaywardGame/types/wiki
|
10
10
|
*/
|
11
|
+
import type Component from "@wayward/game/ui/component/Component";
|
11
12
|
export type Until<T> = Record<string, (...args: any[]) => T>;
|
12
13
|
export type UntilHandler<T, U extends Until<T>> = {
|
13
14
|
[key in keyof U]: {
|
@@ -16,7 +17,7 @@ export type UntilHandler<T, U extends Until<T>> = {
|
|
16
17
|
};
|
17
18
|
};
|
18
19
|
type EmptyIfUndefined<T> = T extends undefined ? Empty : T;
|
19
|
-
export declare abstract class Manipulator<T, U extends Until<T> | undefined = undefined> {
|
20
|
+
export declare abstract class Manipulator<T extends Component, U extends Until<T> | undefined = undefined> {
|
20
21
|
protected readonly element: () => HTMLElement;
|
21
22
|
protected readonly host: T;
|
22
23
|
protected getUntilHandler?(): UntilHandler<T, EmptyIfUndefined<U>>;
|
@@ -32,7 +33,7 @@ export interface ClassUntil<T> extends Until<T> {
|
|
32
33
|
remove(...classes: string[]): T;
|
33
34
|
toggle(hasClass: boolean, ...classes: string[]): T;
|
34
35
|
}
|
35
|
-
export declare class ClassManipulator<T> extends Manipulator<T, ClassUntil<T>> {
|
36
|
+
export declare class ClassManipulator<T extends Component> extends Manipulator<T, ClassUntil<T>> {
|
36
37
|
protected getUntilHandler(): {
|
37
38
|
add: {
|
38
39
|
start: (...classes: string[]) => T;
|
@@ -68,7 +69,7 @@ export interface AttributeUntil<T> extends Until<T> {
|
|
68
69
|
set(attribute: string, value: string): T;
|
69
70
|
set(attributes: Iterable<[string, string | null]>): T;
|
70
71
|
}
|
71
|
-
export declare class AttributeManipulator<T> extends Manipulator<T, AttributeUntil<T>> {
|
72
|
+
export declare class AttributeManipulator<T extends Component> extends Manipulator<T, AttributeUntil<T>> {
|
72
73
|
protected getUntilHandler(): {
|
73
74
|
set: any;
|
74
75
|
};
|
@@ -80,7 +81,7 @@ export declare class AttributeManipulator<T> extends Manipulator<T, AttributeUnt
|
|
80
81
|
has(...attributes: string[]): boolean;
|
81
82
|
private getAttributeIterator;
|
82
83
|
}
|
83
|
-
export declare class DataManipulator<T> extends Manipulator<T> {
|
84
|
+
export declare class DataManipulator<T extends Component> extends Manipulator<T> {
|
84
85
|
set(name: string, value: string): T;
|
85
86
|
set(data: Iterable<[string, string | undefined]>): T;
|
86
87
|
get(name: string): string;
|
@@ -92,7 +93,7 @@ export declare class DataManipulator<T> extends Manipulator<T> {
|
|
92
93
|
export interface StyleUntil<T> extends Until<T> {
|
93
94
|
set(rule: string, value: string): T;
|
94
95
|
}
|
95
|
-
export declare class StyleManipulator<T> extends Manipulator<T, StyleUntil<T>> {
|
96
|
+
export declare class StyleManipulator<T extends Component> extends Manipulator<T, StyleUntil<T>> {
|
96
97
|
protected getUntilHandler(): {
|
97
98
|
set: {
|
98
99
|
start: (rule: string, value: string | number) => T;
|
@@ -16,11 +16,17 @@ declare class MemoryLeakDetector {
|
|
16
16
|
private objectsCollected;
|
17
17
|
private readonly objects;
|
18
18
|
private activeTask;
|
19
|
+
private queuedGarbageCollectionTimeoutId;
|
19
20
|
get isReportingErrors(): boolean;
|
20
21
|
get isMonitoring(): boolean;
|
21
22
|
getCount(prefix: string): number;
|
23
|
+
/**
|
24
|
+
* Queues a garbage collection to run after a delay
|
25
|
+
* @param delay Delay in milliseconds
|
26
|
+
*/
|
27
|
+
queueNextGarbageCollection(delay?: number): void;
|
22
28
|
waitForIdle(): Promise<void>;
|
23
|
-
register(object: object, objectName: string, expectedLifetime: ExpectedLifetime, parentObjectIdentifier?: string): void;
|
29
|
+
register(object: object, objectName: string, expectedLifetime: ExpectedLifetime, parentObjectIdentifier?: string, includeStackTrace?: boolean): void;
|
24
30
|
registerMultiple<T extends object>(prefix: string, objects: SaferArray<T>, objectNamer: (object: T) => string, expectedLifetime: ExpectedLifetime): void;
|
25
31
|
onStopPlay(): void;
|
26
32
|
onScreenShow(_: any, screen: Screen): Promise<any>;
|
@@ -111,7 +111,10 @@ declare class EventEmitter<H, E> {
|
|
111
111
|
* Closes an event emitter, which will prevent any further subscriptions from being made.
|
112
112
|
*/
|
113
113
|
close(): void;
|
114
|
-
|
114
|
+
/**
|
115
|
+
* @returns True if closed
|
116
|
+
*/
|
117
|
+
private throwErrorIfClosed;
|
115
118
|
raw(): IEventEmitter<H, E>;
|
116
119
|
emitSelf<K extends keyof E>(event: K, ...args: ArgsOf<E[K]>): H;
|
117
120
|
emit<K extends keyof E>(event: K, ...args: ArgsOf<E[K]>): H;
|
@@ -16,5 +16,9 @@ export declare enum ExpectedLifetime {
|
|
16
16
|
/**
|
17
17
|
* should only exist while playing the game
|
18
18
|
*/
|
19
|
-
WhilePlaying = 1
|
19
|
+
WhilePlaying = 1,
|
20
|
+
/**
|
21
|
+
* The object is expected to last until the next garbage collection system
|
22
|
+
*/
|
23
|
+
UntilNextGarbageCollection = 2
|
20
24
|
}
|
package/package.json
CHANGED