@wayward/types 2.12.0-beta.dev.20220907.9 → 2.12.0-beta.dev.20220910.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/Game.d.ts +2 -2
- package/definitions/game/game/IObject.d.ts +2 -2
- package/definitions/game/game/doodad/Doodad.d.ts +2 -2
- package/definitions/game/game/entity/Entity.d.ts +3 -0
- package/definitions/game/game/entity/Human.d.ts +2 -1
- package/definitions/game/game/entity/IHuman.d.ts +7 -1
- package/definitions/game/game/entity/action/ActionsRegistration.d.ts +1 -1
- package/definitions/game/game/entity/action/actions/Equip.d.ts +1 -1
- package/definitions/game/game/entity/action/usable/UsableAction.d.ts +9 -0
- package/definitions/game/game/entity/action/usable/UsableActionType.d.ts +1 -1
- package/definitions/game/game/entity/action/usable/actions/UsableActionsWorld.d.ts +1 -1
- package/definitions/game/game/entity/creature/Creature.d.ts +1 -2
- package/definitions/game/game/entity/npc/NPC.d.ts +1 -5
- package/definitions/game/game/entity/player/IPlayer.d.ts +0 -6
- package/definitions/game/game/entity/player/Player.d.ts +0 -2
- package/definitions/game/game/inspection/IInspection.d.ts +11 -11
- package/definitions/game/game/inspection/InfoProvider.d.ts +1 -1
- package/definitions/game/game/inspection/Inspection.d.ts +1 -2
- package/definitions/game/game/inspection/InspectionTypeMap.d.ts +11 -11
- package/definitions/game/game/inspection/InspectionsHandler.d.ts +2 -2
- package/definitions/game/game/inspection/infoProviders/item/ItemDetails.d.ts +1 -1
- package/definitions/game/game/inspection/infoProviders/stat/AttackInfo.d.ts +1 -1
- package/definitions/game/game/inspection/inspections/ActionInspection.d.ts +1 -1
- package/definitions/game/game/inspection/inspections/CorpseInspection.d.ts +1 -1
- package/definitions/game/game/inspection/inspections/EquipSlotInspection.d.ts +1 -1
- package/definitions/game/game/inspection/inspections/IslandInspection.d.ts +2 -1
- package/definitions/game/game/island/Island.d.ts +1 -1
- package/definitions/game/game/item/IItem.d.ts +1 -1
- package/definitions/game/game/item/IItemManager.d.ts +7 -0
- package/definitions/game/game/item/Item.d.ts +8 -4
- package/definitions/game/game/item/ItemManager.d.ts +4 -3
- package/definitions/game/game/reference/IReferenceManager.d.ts +48 -0
- package/definitions/game/game/reference/ReferenceManager.d.ts +3 -38
- package/definitions/game/language/ITranslation.d.ts +1 -1
- package/definitions/game/language/dictionary/UiTranslation.d.ts +753 -755
- package/definitions/game/language/impl/TranslationImpl.d.ts +1 -1
- package/definitions/game/multiplayer/packets/HumanTargetedClientPacket.d.ts +18 -0
- package/definitions/game/multiplayer/packets/client/{SetPlayerZPacket.d.ts → SetHumanZPacket.d.ts} +2 -2
- package/definitions/game/renderer/Renderer.d.ts +6 -0
- package/definitions/game/renderer/Renderers.d.ts +4 -0
- package/definitions/game/steamworks/Steamworks.d.ts +0 -1
- package/definitions/game/ui/component/dropdown/PlayerDropdown.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/InspectionHandlers.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/ReferenceIconRenderer.d.ts +2 -1
- package/definitions/game/ui/screen/screens/game/ReferenceTooltipHandler.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/component/Dialog.d.ts +2 -1
- package/definitions/game/ui/screen/screens/game/component/Item.d.ts +18 -1
- package/definitions/game/ui/screen/screens/game/dialog/BookDialog.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/dialog/EquipmentDialog.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/dialog/InspectDialog.d.ts +1 -1
- package/definitions/game/ui/screen/screens/game/static/actions/ActionBarBindableManager.d.ts +4 -1
- package/definitions/game/ui/screen/screens/game/static/actions/IActionBar.d.ts +1 -2
- package/definitions/game/ui/screen/screens/game/static/menubar/MenuBarButton.d.ts +2 -1
- package/definitions/game/ui/screen/screens/game/static/stats/IStatDisplayDescription.d.ts +1 -1
- package/definitions/game/utilities/Version.d.ts +1 -1
- package/definitions/game/utilities/math/Bezier.d.ts +27 -0
- package/definitions/game/utilities/math/Math2.d.ts +14 -0
- package/definitions/game/utilities/string/Interpolator.d.ts +1 -1
- package/package.json +1 -1
|
@@ -10,56 +10,22 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import Doodad from "game/doodad/Doodad";
|
|
12
12
|
import { ActionType } from "game/entity/action/IAction";
|
|
13
|
-
import Corpse from "game/entity/creature/corpse/Corpse";
|
|
14
13
|
import Creature from "game/entity/creature/Creature";
|
|
15
|
-
import type { EquipType } from "game/entity/IHuman";
|
|
16
14
|
import { SkillType } from "game/entity/IHuman";
|
|
17
15
|
import { Stat } from "game/entity/IStats";
|
|
18
|
-
import NPC from "game/entity/npc/NPC";
|
|
19
16
|
import Player from "game/entity/player/Player";
|
|
20
17
|
import type Inspection from "game/inspection/Inspection";
|
|
21
18
|
import Island from "game/island/Island";
|
|
22
19
|
import { ItemType } from "game/item/IItem";
|
|
23
20
|
import Item from "game/item/Item";
|
|
24
21
|
import { Milestone } from "game/milestones/IMilestone";
|
|
25
|
-
import {
|
|
26
|
-
import
|
|
22
|
+
import type { EnumReferenceTypes, IReferenceTypeMap, Referenceable } from "game/reference/IReferenceManager";
|
|
23
|
+
import { Reference, ReferenceType } from "game/reference/IReferenceManager";
|
|
27
24
|
import ReferenceTooltipHandler from "ui/screen/screens/game/ReferenceTooltipHandler";
|
|
28
25
|
import type Tooltip from "ui/tooltip/Tooltip";
|
|
29
|
-
declare const enumRefTypes: Set<ReferenceType.Skill | ReferenceType.Milestone | ReferenceType.Recipe | ReferenceType.ItemType | ReferenceType.Dismantle | ReferenceType.Stat | ReferenceType.Action | ReferenceType.EquipSlot>;
|
|
30
|
-
export declare type EnumReferenceTypes = (typeof enumRefTypes) extends Set<infer R> ? R : never;
|
|
31
|
-
export declare type ReferenceableReferenceTypes = Exclude<ReferenceType, EnumReferenceTypes>;
|
|
32
|
-
interface IReferenceTypeMap {
|
|
33
|
-
[ReferenceType.Item]: Item;
|
|
34
|
-
[ReferenceType.Creature]: Creature;
|
|
35
|
-
[ReferenceType.Doodad]: Doodad;
|
|
36
|
-
[ReferenceType.NPC]: NPC;
|
|
37
|
-
[ReferenceType.Player]: Player;
|
|
38
|
-
[ReferenceType.TileEvent]: TileEvent;
|
|
39
|
-
[ReferenceType.Island]: Island;
|
|
40
|
-
[ReferenceType.Corpse]: Corpse;
|
|
41
|
-
[ReferenceType.Skill]: [ReferenceType.Skill, SkillType];
|
|
42
|
-
[ReferenceType.Milestone]: [ReferenceType.Milestone, Milestone];
|
|
43
|
-
[ReferenceType.Recipe]: [ReferenceType.Recipe, ItemType];
|
|
44
|
-
[ReferenceType.ItemType]: [ReferenceType.ItemType, ItemType];
|
|
45
|
-
[ReferenceType.Dismantle]: [ReferenceType.Dismantle, ItemType];
|
|
46
|
-
[ReferenceType.Stat]: [ReferenceType.Stat, Stat];
|
|
47
|
-
[ReferenceType.Action]: [ReferenceType.Action, ActionType | string, Item?];
|
|
48
|
-
[ReferenceType.EquipSlot]: [ReferenceType.EquipSlot, EquipType];
|
|
49
|
-
}
|
|
50
|
-
declare type ReferenceId<REFTYPE extends ReferenceType> = IReferenceTypeMap[REFTYPE] extends [REFTYPE, infer IdType, any?] ? IdType : number;
|
|
51
|
-
export declare type Reference<REFTYPE extends ReferenceType | undefined = ReferenceType | undefined> = REFTYPE extends ReferenceType ? [id: ReferenceId<REFTYPE>, type: REFTYPE, context?: [number, ReferenceType?]] : [number];
|
|
52
|
-
export declare type Referenceable = IReferenceTypeMap[ReferenceableReferenceTypes];
|
|
53
|
-
export declare type ResolveReference<REFTYPE extends ReferenceType> = IReferenceTypeMap[REFTYPE];
|
|
54
|
-
export declare type EnumReferenceResolved<REFTYPE extends EnumReferenceTypes = EnumReferenceTypes> = IReferenceTypeMap[REFTYPE];
|
|
55
|
-
export declare module Reference {
|
|
56
|
-
function create(id: number): Reference;
|
|
57
|
-
function create<REFTYPE extends ReferenceType>(id: ReferenceId<REFTYPE>, type: REFTYPE, context?: Referenceable | number | [number, ReferenceType?]): Reference;
|
|
58
|
-
function context(reference?: Reference): [number] | [id: number, type: ReferenceType.Item, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.Creature, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.Doodad, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.NPC, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.Player, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.TileEvent, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.Island, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: number, type: ReferenceType.Corpse, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: SkillType, type: ReferenceType.Skill, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: Milestone, type: ReferenceType.Milestone, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: ItemType, type: ReferenceType.Recipe, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: ItemType, type: ReferenceType.ItemType, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: ItemType, type: ReferenceType.Dismantle, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: Stat, type: ReferenceType.Stat, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: string | ActionType, type: ReferenceType.Action, context?: [number, (ReferenceType | undefined)?] | undefined] | [id: EquipType, type: ReferenceType.EquipSlot, context?: [number, (ReferenceType | undefined)?] | undefined] | undefined;
|
|
59
|
-
}
|
|
60
26
|
export default class ReferenceManager {
|
|
61
27
|
static isEnumReference(type: ReferenceType): type is EnumReferenceTypes;
|
|
62
|
-
static getList(type: ReferenceType, gameIsland?: Island): import("../entity/creature/corpse/CorpseManager").default | import("../entity/creature/CreatureManager").default | import("../doodad/DoodadManager").default | import("../item/ItemManager").default | import("../entity/npc/NPCManager").default | import("../tile/TileEventManager").default | (Player | undefined)[] | readonly Milestone[] | readonly SkillType[] |
|
|
28
|
+
static getList(type: ReferenceType, gameIsland?: Island): import("../entity/creature/corpse/CorpseManager").default | import("../entity/creature/CreatureManager").default | import("../doodad/DoodadManager").default | import("../item/ItemManager").default | import("../entity/npc/NPCManager").default | import("../tile/TileEventManager").default | (Player | undefined)[] | readonly Milestone[] | readonly SkillType[] | import("game/entity/IHuman").EquipType[] | readonly ItemType[] | IterableIterator<Island> | readonly Stat[] | (string | ActionType)[];
|
|
63
29
|
static get(thing: Referenceable): Reference | undefined;
|
|
64
30
|
static getReferenceType(thing: Value<IReferenceTypeMap>): ReferenceType;
|
|
65
31
|
private referenceCursor;
|
|
@@ -75,4 +41,3 @@ export default class ReferenceManager {
|
|
|
75
41
|
inspect(reference: Reference, ...args: any[]): Inspection<any> | undefined;
|
|
76
42
|
tooltip(reference: Reference, initializer?: (tooltip: Tooltip, handler: ReferenceTooltipHandler) => any): (tooltip: Tooltip) => Promise<void>;
|
|
77
43
|
}
|
|
78
|
-
export {};
|
|
@@ -8,7 +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 { Reference } from "game/reference/
|
|
11
|
+
import type { Reference } from "game/reference/IReferenceManager";
|
|
12
12
|
import type { Segment } from "language/segment/Segments";
|
|
13
13
|
import type { IInterpolationOptions, IStringSection } from "utilities/string/Interpolator";
|
|
14
14
|
export declare enum ListEnder {
|