@wayward/types 2.13.0-beta.dev.20230424.1 → 2.13.0-beta.dev.20230425.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.
@@ -42,7 +42,6 @@ export default abstract class Entity<DescriptionType = unknown, TypeType extends
42
42
  id: number;
43
43
  type: TypeType;
44
44
  referenceId?: number;
45
- private _humansVisible;
46
45
  renamed?: string | ISerializedTranslation;
47
46
  x: number;
48
47
  y: number;
@@ -50,7 +49,7 @@ export default abstract class Entity<DescriptionType = unknown, TypeType extends
50
49
  private _tags?;
51
50
  islandId: IslandId;
52
51
  preventRendering?: boolean;
53
- private _inFov;
52
+ private _humansWithinBound;
54
53
  /**
55
54
  * Cached tile the entity is on.
56
55
  * This should be cleared when x,y,z is changing.
@@ -94,8 +93,11 @@ export default abstract class Entity<DescriptionType = unknown, TypeType extends
94
93
  protected setCachedTile(tile: Tile): void;
95
94
  clearTileCache(): void;
96
95
  isNearby(entity: Entity<DescriptionType>): boolean;
97
- isInFov(): boolean;
98
- setInFov(inFov: boolean, humansWithinBound: IHumanBound[]): void;
96
+ /**
97
+ * Checks if the entity is within the viewport bounds of one or more humans
98
+ */
99
+ isWithinHumanBounds(): boolean;
100
+ setHumansWithinBound(humansWithinBound: IHumanBound[]): void;
99
101
  humansVisible(): Human[];
100
102
  isOnFire(): FireType;
101
103
  queueSoundEffect(type: SfxType, delay?: number, speed?: number): void;
@@ -30,7 +30,7 @@ export declare enum MerchantCustomerKnowledgeState {
30
30
  HasSeenInventory = 2
31
31
  }
32
32
  export default class MerchantNPC extends NPC {
33
- credit: Record<string, number>;
33
+ credit: Map<string, number>;
34
34
  customerKnowledge: Map<string, MerchantCustomerKnowledgeState>;
35
35
  constructor(options?: INPCConstructorOptions);
36
36
  knowsOfUnseenStock(customer: Human): boolean;
@@ -26,10 +26,11 @@ export declare enum CanASeeBType {
26
26
  CreatureRandomSpawn = 3,
27
27
  CreatureScarecrow = 4,
28
28
  CreatureTrapping = 5,
29
- FieldOfView = 6,
30
- GetNearestPlayer = 7,
31
- GetPlayersThatSeePosition = 8,
32
- Shipper = 9,
33
- SkeletalMage = 10,
34
- ZombieHorde = 11
29
+ EntityHumansVisible = 6,
30
+ FieldOfView = 7,
31
+ GetNearestPlayer = 8,
32
+ GetPlayersThatSeePosition = 9,
33
+ Shipper = 10,
34
+ SkeletalMage = 11,
35
+ ZombieHorde = 12
35
36
  }
@@ -45,7 +45,8 @@ export declare enum NotifierIconType {
45
45
  Untame = 1,
46
46
  Water = 2,
47
47
  Warning = 3,
48
- Decay = 4
48
+ Decay = 4,
49
+ Talk = 5
49
50
  }
50
51
  export declare const itemDamageNotifierThreshold = 3;
51
52
  export declare const doodadDamageNotifierThreshold = 5;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@wayward/types",
3
3
  "description": "TypeScript declarations for Wayward, used for modding.",
4
- "version": "2.13.0-beta.dev.20230424.1",
4
+ "version": "2.13.0-beta.dev.20230425.1",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",