@wayward/types 2.14.0-beta.dev.20231228.1 → 2.14.0-beta.dev.20231230.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/entity/Human.d.ts +2 -1
- package/definitions/game/game/entity/action/ActionExecutor.d.ts +2 -0
- package/definitions/game/game/entity/action/ActionsRegistration.d.ts +1 -1
- package/definitions/game/game/entity/action/IAction.d.ts +12 -0
- package/definitions/game/game/entity/action/actions/UpdateOption.d.ts +1 -1
- package/definitions/game/game/entity/action/argument/ActionArgumentObjectKey.d.ts +23 -0
- package/definitions/game/game/inspection/infoProviders/doodad/WaterPurification.d.ts +1 -1
- package/definitions/game/game/inspection/inspections/RecipeInspection.d.ts +1 -0
- package/definitions/game/game/inspection/inspections/TileEventInspection.d.ts +1 -1
- package/definitions/game/language/dictionary/Message.d.ts +783 -782
- package/definitions/game/ui/component/Loading.d.ts +10 -0
- package/definitions/game/ui/screen/screens/game/component/container/ContainerBucketItemList.d.ts +3 -0
- package/definitions/game/ui/screen/screens/game/util/item/ItemStylesheet.d.ts +1 -0
- package/definitions/game/ui/screen/screens/game/util/item/SpriteEditor.d.ts +7 -0
- package/package.json +1 -1
|
@@ -294,7 +294,8 @@ export default abstract class Human<TypeType extends number = number, EntityRefe
|
|
|
294
294
|
unequipAll(displayMessage?: boolean, isArmorStandSwap?: boolean): IEquip[];
|
|
295
295
|
getJumpTile(): Tile | undefined;
|
|
296
296
|
hasDelay(): boolean;
|
|
297
|
-
addDelay(delay: number, replace?: boolean, addStaminaDelay?: boolean): void;
|
|
297
|
+
addDelay(delay: number, replace?: boolean, addStaminaDelay?: boolean, cap?: number): void;
|
|
298
|
+
ensureDelay(delay: number): void;
|
|
298
299
|
/**
|
|
299
300
|
* Gets a stamina penalty delay to be used for slowed actions and movement.
|
|
300
301
|
* @param staminaToStartAddingDelayAt Stat value where delays start getting added from.
|
|
@@ -130,6 +130,8 @@ export default class ActionExecutor<A extends ActionArguments, E extends Entity,
|
|
|
130
130
|
setItemsUsed(used?: boolean): this;
|
|
131
131
|
confirmItemsBroken(executor: E): Promise<boolean>;
|
|
132
132
|
private checkConfirmer;
|
|
133
|
+
private silent?;
|
|
134
|
+
setSilent(silent?: boolean): this;
|
|
133
135
|
private executeInternalOrMultiplayer;
|
|
134
136
|
private executeInternal;
|
|
135
137
|
private createActionPacket;
|
|
@@ -173,7 +173,7 @@ export declare const actionDescriptionsSlow: {
|
|
|
173
173
|
}, [import("../../../utilities/math/Direction").Direction.None | import("../../../utilities/math/Direction").Direction.East | import("../../../utilities/math/Direction").Direction.North | import("../../../utilities/math/Direction").Direction.West | import("../../../utilities/math/Direction").Direction.South, (number | undefined)?, (boolean | undefined)?]>;
|
|
174
174
|
105: import("./Action").Action<[import("@wayward/game/game/entity/action/IAction").ActionArgument.Object], import("../Human").default<number, import("../../reference/IReferenceManager").ReferenceType.NPC | import("../../reference/IReferenceManager").ReferenceType.Player>, void, import("@wayward/game/game/entity/action/IAction").IActionUsable, [any?]>;
|
|
175
175
|
89: import("./Action").Action<[import("@wayward/game/game/entity/action/IAction").ActionArgument.Container, [import("@wayward/game/game/entity/action/IAction").ActionArgument.UnsignedInteger32NumberArray, import("@wayward/game/game/entity/action/actions/UpdateItemOrder").ActionArgumentItemSort]], import("../Human").default<number, import("../../reference/IReferenceManager").ReferenceType.NPC | import("../../reference/IReferenceManager").ReferenceType.Player>, void, import("@wayward/game/game/entity/action/IAction").IActionUsable, [import("../../item/IItem").IContainer, number[] | import("../../item/IItemManager").IContainerSort]>;
|
|
176
|
-
104: import("./Action").Action<[import("
|
|
176
|
+
104: import("./Action").Action<[import("./argument/ActionArgumentObjectKey").default<import("../../../save/data/ISaveDataGlobal").IOptions>, import("@wayward/game/game/entity/action/IAction").ActionArgument.Object], import("../Human").default<number, import("../../reference/IReferenceManager").ReferenceType.NPC | import("../../reference/IReferenceManager").ReferenceType.Player>, void, import("@wayward/game/game/entity/action/IAction").IActionUsable, [keyof import("../../../save/data/ISaveDataGlobal").IOptions, any?]>;
|
|
177
177
|
106: import("./Action").Action<[[import("@wayward/game/game/entity/action/IAction").ActionArgument.Vector2Array, import("@wayward/game/game/entity/action/IAction").ActionArgument.Undefined], [import("@wayward/game/game/entity/action/IAction").ActionArgument.Boolean, import("@wayward/game/game/entity/action/IAction").ActionArgument.Undefined]], import("../Human").default<number, import("../../reference/IReferenceManager").ReferenceType.NPC | import("../../reference/IReferenceManager").ReferenceType.Player>, void, import("@wayward/game/game/entity/action/IAction").IActionUsable, [(import("../../../utilities/math/IVector").IVector2[] | undefined)?, (boolean | undefined)?]>;
|
|
178
178
|
91: import("./Action").Action<[import("@wayward/game/game/entity/action/IAction").ActionArgument.ItemNearby, [import("@wayward/game/game/entity/action/IAction").ActionArgument.ItemNearby, import("@wayward/game/game/entity/action/IAction").ActionArgument.Undefined]], import("../Human").default<number, import("../../reference/IReferenceManager").ReferenceType.NPC | import("../../reference/IReferenceManager").ReferenceType.Player>, void, import("@wayward/game/game/entity/action/actions/Upgrade").IUpgradeCanUse, [import("../../item/Item").default, (import("../../item/Item").default | undefined)?]>;
|
|
179
179
|
};
|
|
@@ -17,6 +17,7 @@ import type { EntityType } from "@wayward/game/game/entity/IEntity";
|
|
|
17
17
|
import type { SkillType } from "@wayward/game/game/entity/IHuman";
|
|
18
18
|
import type { ActionArgumentCustom } from "@wayward/game/game/entity/action/argument/ActionArgumentCustom";
|
|
19
19
|
import type ActionArgumentEnum from "@wayward/game/game/entity/action/argument/ActionArgumentEnum";
|
|
20
|
+
import type ActionArgumentObjectKey from "@wayward/game/game/entity/action/argument/ActionArgumentObjectKey";
|
|
20
21
|
import type Creature from "@wayward/game/game/entity/creature/Creature";
|
|
21
22
|
import type Corpse from "@wayward/game/game/entity/creature/corpse/Corpse";
|
|
22
23
|
import type NPC from "@wayward/game/game/entity/npc/NPC";
|
|
@@ -351,6 +352,10 @@ export interface IActionNotUsableHandlerApi<E extends Entity = Entity, CU extend
|
|
|
351
352
|
* Result of a non-usable canUse check.
|
|
352
353
|
*/
|
|
353
354
|
use: IActionNotUsable;
|
|
355
|
+
/**
|
|
356
|
+
* Disables sending a message to the executor for this action not being usable.
|
|
357
|
+
*/
|
|
358
|
+
setSilent(silent?: boolean): any;
|
|
354
359
|
}
|
|
355
360
|
export interface IActionConfirmerApi<E extends Entity = Entity, CU extends IActionUsable = IActionUsable> extends IActionApi<E, CU> {
|
|
356
361
|
/**
|
|
@@ -443,6 +448,13 @@ export declare namespace ActionArgument {
|
|
|
443
448
|
namespace ENUM {
|
|
444
449
|
let ActionArgumentEnumClass: typeof ActionArgumentEnum;
|
|
445
450
|
}
|
|
451
|
+
/**
|
|
452
|
+
* An action argument which is an entry from the given key in an object Performs validation when an object is passed
|
|
453
|
+
*/
|
|
454
|
+
function OBJECT_KEY<T extends Record<string, any>>(object?: T): ActionArgumentObjectKey<T>;
|
|
455
|
+
namespace OBJECT {
|
|
456
|
+
let ActionArgumentObjectKeyClass: typeof ActionArgumentObjectKey;
|
|
457
|
+
}
|
|
446
458
|
/**
|
|
447
459
|
* An action argument which is bit flags from the given enum. Performs validation.
|
|
448
460
|
*/
|
|
@@ -10,5 +10,5 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import { Action } from "@wayward/game/game/entity/action/Action";
|
|
12
12
|
import { ActionArgument } from "@wayward/game/game/entity/action/IAction";
|
|
13
|
-
declare const _default: Action<[
|
|
13
|
+
declare const _default: Action<[import("../argument/ActionArgumentObjectKey").default<import("../../../../save/data/ISaveDataGlobal").IOptions>, ActionArgument.Object], import("../../Human").default<number, import("../../../reference/IReferenceManager").ReferenceType.NPC | import("../../../reference/IReferenceManager").ReferenceType.Player>, void, import("@wayward/game/game/entity/action/IAction").IActionUsable, [keyof import("../../../../save/data/ISaveDataGlobal").IOptions, any?]>;
|
|
14
14
|
export default _default;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright 2011-2023 Unlok
|
|
3
|
+
* https://www.unlok.ca
|
|
4
|
+
*
|
|
5
|
+
* Credits & Thanks:
|
|
6
|
+
* https://www.unlok.ca/credits-thanks/
|
|
7
|
+
*
|
|
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
|
+
* https://github.com/WaywardGame/types/wiki
|
|
10
|
+
*/
|
|
11
|
+
import type Entity from "@wayward/game/game/entity/Entity";
|
|
12
|
+
import { ActionArgumentCustom } from "@wayward/game/game/entity/action/argument/ActionArgumentCustom";
|
|
13
|
+
/**
|
|
14
|
+
* An action argument which is an entry from the given key in an object Performs validation when an object is passed
|
|
15
|
+
*/
|
|
16
|
+
export default class ActionArgumentObjectKey<T extends Record<string, any>> extends ActionArgumentCustom<keyof T> {
|
|
17
|
+
private readonly object?;
|
|
18
|
+
constructor(object?: T | undefined);
|
|
19
|
+
validate(executor: Entity | undefined, value: unknown): value is keyof T;
|
|
20
|
+
read(): keyof T;
|
|
21
|
+
write(executor: Entity | undefined, value: keyof T): void;
|
|
22
|
+
static applyHelperToActionArgument(): void;
|
|
23
|
+
}
|
|
@@ -23,7 +23,7 @@ declare class TileEventInspection extends Inspection<TileEvent> {
|
|
|
23
23
|
static getFromTile(tile: Tile): TileEventInspection[];
|
|
24
24
|
static getFromTileFiltered(tile: Tile, minorEvents: boolean): TileEventInspection[];
|
|
25
25
|
static handles(type: InspectType, tileEvent: unknown): boolean;
|
|
26
|
-
constructor(tileEvent: TileEvent
|
|
26
|
+
constructor(tileEvent: TileEvent);
|
|
27
27
|
getId(): string;
|
|
28
28
|
get(context: InfoProviderContext): Array<Translation | InfoProvider>;
|
|
29
29
|
onRemove(_: any, event: TileEvent): void;
|