@wayward/types 2.13.2-beta.dev.20230522.1 → 2.13.2-beta.dev.20230525.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/README.md +22 -6
- package/definitions/game/game/doodad/IDoodad.d.ts +1 -1
- package/definitions/game/game/entity/player/IPlayer.d.ts +1 -0
- package/definitions/game/game/inspection/InfoProvider.d.ts +1 -1
- package/definitions/game/game/island/IIsland.d.ts +5 -0
- package/definitions/game/game/island/Island.d.ts +17 -4
- package/definitions/game/game/tile/ITerrain.d.ts +2 -1
- package/definitions/game/game/tile/Tile.d.ts +5 -1
- package/definitions/game/language/dictionary/UiTranslation.d.ts +100 -102
- package/definitions/game/mod/BaseMod.d.ts +18 -4
- package/definitions/game/renderer/world/IWorldLayer.d.ts +3 -2
- package/definitions/game/renderer/world/WorldLayer.d.ts +1 -1
- package/definitions/game/renderer/world/WorldLayerRenderer.d.ts +3 -2
- package/definitions/game/ui/old/screens/InGameScreen.d.ts +2 -2
- package/definitions/game/ui/screen/screens/game/util/item/SpriteGlow.d.ts +2 -2
- package/definitions/game/ui/screen/screens/menu/menus/pause/MultiplayerOptionsMenu.d.ts +0 -2
- package/definitions/matchmakingserver/globalServerDirectory.d.ts +0 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,11 +1,27 @@
|
|
|
1
|
-
# Wayward
|
|
1
|
+
# [Wayward Modding Guide](https://github.com/WaywardGame/types/wiki)
|
|
2
|
+
Learn how to mod Wayward.
|
|
2
3
|
|
|
3
|
-
|
|
4
|
+
## **[➡ New Modders Start Here! ⬅](https://github.com/WaywardGame/types/wiki)**
|
|
4
5
|
|
|
5
|
-
##
|
|
6
|
+
## Documentation
|
|
7
|
+
- [`+mod create` & `+mod update`](https://github.com/WaywardGame/types/wiki/mod-create-&-update) — Documentation on the commands used to generate starter files for modding, and updating script mods.
|
|
8
|
+
- [`mod.json`](https://github.com/WaywardGame/types/wiki/mod.json) — Documentation on what all can be declared in the main mod metadata file.
|
|
9
|
+
- [Extracting assets](https://github.com/WaywardGame/types/wiki/Extracting-Wayward-Assets) — A guide on extracting textures, sounds, and more from Wayward.
|
|
6
10
|
|
|
7
|
-
|
|
11
|
+
## Mod Content
|
|
12
|
+
- [Scripts](https://github.com/WaywardGame/types/wiki/Script-Mods) — Create mods that change the functionality of the game, or add new content
|
|
13
|
+
- [Languages & Extensions](https://github.com/WaywardGame/types/wiki/Languages-&-Extensions) — Adding new languages to Wayward, or adding translatable strings to mods.
|
|
14
|
+
- [Customizations](https://github.com/WaywardGame/types/wiki/Customizations) — Adding new hair styles, hair colours, and skin tones
|
|
15
|
+
- [Image Overrides](https://github.com/WaywardGame/types/wiki/Image-Overrides) — Replacing default sprites & textures
|
|
16
|
+
- [Stylesheets](https://github.com/WaywardGame/types/wiki/Stylesheets) — Changing the appearance of the UI
|
|
8
17
|
|
|
9
|
-
|
|
18
|
+
# Other Useful Links
|
|
19
|
+
|
|
20
|
+
## [Wayward Types Viewer](https://waywardgame.github.io/)
|
|
21
|
+
A pretty, searchable list of all the type definitions in Wayward. This `types` repository is actually the same stuff you can find on this website, but it's the *raw* form of it!
|
|
22
|
+
|
|
23
|
+
## [Modding Examples](https://github.com/WaywardGame)
|
|
24
|
+
Every official mod created for Wayward, and some other Wayward-related projects.
|
|
10
25
|
|
|
11
|
-
|
|
26
|
+
## [Steam Workshop](http://steamcommunity.com/app/379210/workshop/)
|
|
27
|
+
Where Wayward mods are published.
|
|
@@ -420,7 +420,7 @@ export declare enum DoodadTag {
|
|
|
420
420
|
* All tree types that can be spawned during map gen
|
|
421
421
|
* !! This must be kept in sync with the tree list in setupTiles !!
|
|
422
422
|
*/
|
|
423
|
-
export type MapGenDoodadTrees = DoodadType.MapleTree | DoodadType.CoconutTree | DoodadType.JoshuaTree | DoodadType.SpruceTree | DoodadType.CypressTree | DoodadType.AppleTree | DoodadType.SpruceTreeWithSnow | DoodadType.WhitePineTree | DoodadType.WhitePineTreeWithSnow | DoodadType.PapayaTree | DoodadType.Palapalai | DoodadType.ButtonMushrooms | DoodadType.PoisonIvy | DoodadType.Cattails;
|
|
423
|
+
export type MapGenDoodadTrees = DoodadType.MapleTree | DoodadType.CoconutTree | DoodadType.JoshuaTree | DoodadType.SpruceTree | DoodadType.CypressTree | DoodadType.AppleTree | DoodadType.SpruceTreeWithSnow | DoodadType.WhitePineTree | DoodadType.WhitePineTreeWithSnow | DoodadType.PapayaTree | DoodadType.Palapalai | DoodadType.ButtonMushrooms | DoodadType.PoisonIvy | DoodadType.Cattails | DoodadType.FlyAmanita;
|
|
424
424
|
export declare enum DoodadTypeGroup {
|
|
425
425
|
Invalid = 400,
|
|
426
426
|
LitCampfire = 401,
|
|
@@ -103,6 +103,7 @@ export interface IPlayerEvents extends Events<Human> {
|
|
|
103
103
|
* @param isAbsentPlayer True if the player is absent
|
|
104
104
|
*/
|
|
105
105
|
idChanged(currentId: number, newId: number, isAbsentPlayer: boolean): any;
|
|
106
|
+
updateCraftTable(): any;
|
|
106
107
|
}
|
|
107
108
|
export declare enum TurnTypeFlag {
|
|
108
109
|
CheckUnderPlayer = 1,
|
|
@@ -140,6 +140,11 @@ export interface IWell {
|
|
|
140
140
|
export interface IWaterFill {
|
|
141
141
|
count: number;
|
|
142
142
|
tiles: Record<number, Record<number, boolean>>;
|
|
143
|
+
tile?: Tile;
|
|
144
|
+
}
|
|
145
|
+
export interface IWaterFillReturn {
|
|
146
|
+
count: number;
|
|
147
|
+
tile?: Tile;
|
|
143
148
|
}
|
|
144
149
|
export interface IWaterContamination {
|
|
145
150
|
x: number;
|
|
@@ -24,7 +24,7 @@ import type { IDamageInfo, IDamageOutcome, IDamageOutcomeInput } from "game/enti
|
|
|
24
24
|
import CorpseManager from "game/entity/creature/corpse/CorpseManager";
|
|
25
25
|
import FlowFieldManager from "game/entity/flowfield/FlowFieldManager";
|
|
26
26
|
import NPCManager from "game/entity/npc/NPCManager";
|
|
27
|
-
import type { IIslandEvents, IIslandLoadOptions, IMobCheck, ISeeds, IWaterContamination, IWaterFill, IWell, IslandId } from "game/island/IIsland";
|
|
27
|
+
import type { IIslandEvents, IIslandLoadOptions, IMobCheck, ISeeds, IWaterContamination, IWaterFill, IWaterFillReturn, IWell, IslandId } from "game/island/IIsland";
|
|
28
28
|
import { WaterType } from "game/island/IIsland";
|
|
29
29
|
import { PortManager } from "game/island/Port";
|
|
30
30
|
import type { ILiquidGather } from "game/item/IItem";
|
|
@@ -109,6 +109,7 @@ export default class Island extends EventEmitter.Host<IIslandEvents> implements
|
|
|
109
109
|
readonly id: IslandId;
|
|
110
110
|
readonly mapSizeSq: number;
|
|
111
111
|
spawnPoint: IVector3;
|
|
112
|
+
private _activated;
|
|
112
113
|
private _loadedReferences;
|
|
113
114
|
private _tiles;
|
|
114
115
|
modifiersCollection?: IslandModifiersCollection;
|
|
@@ -134,8 +135,20 @@ export default class Island extends EventEmitter.Host<IIslandEvents> implements
|
|
|
134
135
|
get isActive(): boolean;
|
|
135
136
|
get isDefaultIsland(): boolean;
|
|
136
137
|
getDetails(): IIslandDetails;
|
|
137
|
-
|
|
138
|
-
|
|
138
|
+
/**
|
|
139
|
+
* Activates the island.
|
|
140
|
+
* Islands should be activated when a player is going to load onto it
|
|
141
|
+
*/
|
|
142
|
+
private activate;
|
|
143
|
+
/**
|
|
144
|
+
* Runs some logic while ensuring the island is activated
|
|
145
|
+
*/
|
|
146
|
+
private runWhileActivated;
|
|
147
|
+
/**
|
|
148
|
+
* Deactivates the island.
|
|
149
|
+
* Islands should be deactivated when the last player leaves it or when it's being unloaded.
|
|
150
|
+
*/
|
|
151
|
+
private deactivate;
|
|
139
152
|
private gameOptionsCached?;
|
|
140
153
|
getGameOptions(): IGameOptions;
|
|
141
154
|
clearGameOptionsCache(): void;
|
|
@@ -199,7 +212,7 @@ export default class Island extends EventEmitter.Host<IIslandEvents> implements
|
|
|
199
212
|
/**
|
|
200
213
|
* Check the amount of water tiles there is connected to a supplied x/y area
|
|
201
214
|
*/
|
|
202
|
-
checkWaterFill(tile: Tile, needed: number, waterType: WaterType, waterFill?: IWaterFill):
|
|
215
|
+
checkWaterFill(tile: Tile, needed: number, waterType: WaterType, waterFill?: IWaterFill): IWaterFillReturn;
|
|
203
216
|
getSpawnPoint(): Tile;
|
|
204
217
|
getSuitableSpawnPoint(): Tile;
|
|
205
218
|
calculateDamageOutcome(input: IDamageOutcomeInput): IDamageOutcome | undefined;
|
|
@@ -110,7 +110,11 @@ export default class Tile implements IVector4, Partial<ITileContainer>, IFieldOf
|
|
|
110
110
|
get variation(): number;
|
|
111
111
|
get isMapEdge(): boolean;
|
|
112
112
|
/**
|
|
113
|
-
* Check if this
|
|
113
|
+
* Check if this tile is Void type
|
|
114
|
+
*/
|
|
115
|
+
get isVoid(): boolean;
|
|
116
|
+
/**
|
|
117
|
+
* Check if this tile contains some items
|
|
114
118
|
*/
|
|
115
119
|
get hasTileContainer(): boolean;
|
|
116
120
|
/**
|
|
@@ -768,107 +768,105 @@ declare enum UiTranslation {
|
|
|
768
768
|
MenuMultiplayerOptionsCheckConnectionResultSteamRelayNetwork = 753,
|
|
769
769
|
MenuMultiplayerOptionsCheckConnectionResultSteamRelayNetworkFail = 754,
|
|
770
770
|
MenuMultiplayerOptionsCheckConnectionResultSteamRelayNetworkUnavailable = 755,
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
WindowTitleContainer = 856,
|
|
872
|
-
WindowTitleInventory = 857
|
|
771
|
+
MenuMultiplayerOptionsCheckConnectionResultWebSocket = 756,
|
|
772
|
+
MenuMultiplayerOptionsCheckConnectionResultWebSocketFail = 757,
|
|
773
|
+
MenuMultiplayerOptionsCheckConnectionResultWebSocketUnavailable = 758,
|
|
774
|
+
MenuMultiplayerOptionsCheckConnectionResultSuccess = 759,
|
|
775
|
+
MenuJoinServerTitle = 760,
|
|
776
|
+
MenuJoinServerDescription = 761,
|
|
777
|
+
MenuJoinServerInputPlaceholder = 762,
|
|
778
|
+
MenuJoinServerChooseModifiersTitle = 763,
|
|
779
|
+
MenuJoinServerChooseModifiersDescription = 764,
|
|
780
|
+
MenuSharedMultiplayerChoiceLobbyTypeFriends = 765,
|
|
781
|
+
MenuSharedMultiplayerChoiceLobbyTypeFriendsDescription = 766,
|
|
782
|
+
MenuSharedMultiplayerChoiceLobbyTypePublic = 767,
|
|
783
|
+
MenuSharedMultiplayerChoiceLobbyTypePublicDescription = 768,
|
|
784
|
+
MenuSharedMultiplayerChoiceLobbyTypePrivate = 769,
|
|
785
|
+
MenuSharedMultiplayerChoiceLobbyTypePrivateDescription = 770,
|
|
786
|
+
MenuSharedMultiplayerChoicePVP = 771,
|
|
787
|
+
MenuSharedMultiplayerChoicePVPDescription = 772,
|
|
788
|
+
MenuSharedMultiplayerChoiceAllowTraveling = 773,
|
|
789
|
+
MenuSharedMultiplayerChoiceAllowTravelingDescription = 774,
|
|
790
|
+
MenuSharedMultiplayerChoiceAllowHardcoreRespawns = 775,
|
|
791
|
+
MenuSharedMultiplayerChoiceAllowHardcoreRespawnsDescription = 776,
|
|
792
|
+
MenuSharedMultiplayerDescription = 777,
|
|
793
|
+
MenuSharedMultiplayerMessageOfTheDay = 778,
|
|
794
|
+
MenuSharedMultiplayerMaxPlayers = 779,
|
|
795
|
+
MenuSharedRealTimeTickSpeedTooltip = 780,
|
|
796
|
+
MenuSharedRealTimeTickSpeedLabel = 781,
|
|
797
|
+
MenuSharedMaxTravelTimeLabel = 782,
|
|
798
|
+
MenuSharedMaxTravelTimeLabelTooltip = 783,
|
|
799
|
+
MenuSharedButtonDefault = 784,
|
|
800
|
+
MenuSharedValueSeconds = 785,
|
|
801
|
+
MenuSharedValueMillseconds = 786,
|
|
802
|
+
MenuSharedValueTurns = 787,
|
|
803
|
+
MenuSharedValuePercentage = 788,
|
|
804
|
+
MenuSharedMilestonesNotUnlockable = 789,
|
|
805
|
+
MenuSharedMilestonesNotUnlockableDescription = 790,
|
|
806
|
+
MenuSharedMilestonesNotUnlockableButtonShowMods = 791,
|
|
807
|
+
MenuSharedButtonDisableAll = 792,
|
|
808
|
+
MenuSharedButtonEnableAll = 793,
|
|
809
|
+
MenuSharedMilestoneModifiersSelected = 794,
|
|
810
|
+
MiscSortBy = 795,
|
|
811
|
+
MiscSortDirection = 796,
|
|
812
|
+
MiscFilter = 797,
|
|
813
|
+
MiscPlayerNameDefault = 798,
|
|
814
|
+
MiscPlayerNameServer = 799,
|
|
815
|
+
MiscSaveNameDefault = 800,
|
|
816
|
+
MiscSaveNameDailyChallenge = 801,
|
|
817
|
+
MiscSaveNameChallenge = 802,
|
|
818
|
+
MiscSaveVersionUnknown = 803,
|
|
819
|
+
MiscVersion = 804,
|
|
820
|
+
MiscVersionBuildInfoTooltip = 805,
|
|
821
|
+
MiscVersionUpdate = 806,
|
|
822
|
+
MiscTime = 807,
|
|
823
|
+
MiscTimeMeridiem = 808,
|
|
824
|
+
MiscError = 809,
|
|
825
|
+
MiscContextMenuCopyTooltip = 810,
|
|
826
|
+
MiscBindableNoBindings = 811,
|
|
827
|
+
DifficultyOptionsPeaceful = 812,
|
|
828
|
+
DifficultyOptionsAberrantSpawnsDisabled = 813,
|
|
829
|
+
DifficultyOptionsAberrantSpawnsOnly = 814,
|
|
830
|
+
DifficultyOptionsCreatureSpawningDisabled = 815,
|
|
831
|
+
DifficultyOptionsCreatureAlwaysSpawns = 816,
|
|
832
|
+
DifficultyOptionsCreatureSpawnsDefault = 817,
|
|
833
|
+
DifficultyOptionsCreatureSpawnsAberrantOnly = 818,
|
|
834
|
+
DifficultyOptionsCreatureSpawnsNoAberrants = 819,
|
|
835
|
+
DifficultyOptionsSpawnLimit = 820,
|
|
836
|
+
DifficultyOptionsRespawn = 821,
|
|
837
|
+
DifficultyOptionsEternalNight = 822,
|
|
838
|
+
DifficultyOptionsEternalDay = 823,
|
|
839
|
+
DifficultyOptionsTimeInitial = 824,
|
|
840
|
+
DifficultyOptionsTimeFrozen = 825,
|
|
841
|
+
DifficultyOptionsTimeDayLength = 826,
|
|
842
|
+
DifficultyOptionsTimeDayPercent = 827,
|
|
843
|
+
DifficultyOptionsNoItems = 828,
|
|
844
|
+
DifficultyOptionsRecipes = 829,
|
|
845
|
+
DifficultyOptionsStartingIsland = 830,
|
|
846
|
+
DifficultyOptionsTravelingEffectsDisabled = 831,
|
|
847
|
+
DifficultyOptionsBenignityInitial = 832,
|
|
848
|
+
DifficultyOptionsBenignityMultiplier = 833,
|
|
849
|
+
DifficultyOptionsMalignityInitial = 834,
|
|
850
|
+
DifficultyOptionsMalignityMultiplier = 835,
|
|
851
|
+
DifficultyOptionsWeightBonus = 836,
|
|
852
|
+
DifficultyOptionsStatInitial = 837,
|
|
853
|
+
DifficultyOptionsStatMax = 838,
|
|
854
|
+
DifficultyOptionsStatMultiplier = 839,
|
|
855
|
+
DifficultyOptionsStatusEffectStartWith = 840,
|
|
856
|
+
DifficultyOptionsStatusEffectUntreatable = 841,
|
|
857
|
+
DifficultyOptionsStatusEffectPassChanceMultiplier = 842,
|
|
858
|
+
DifficultyOptionsNoRandomSkills = 843,
|
|
859
|
+
DifficultyOptionsSkillStartingCount = 844,
|
|
860
|
+
DifficultyOptionsSkillGainMultiplier = 845,
|
|
861
|
+
DifficultyOptionsSkillInitial = 846,
|
|
862
|
+
DifficultyOptionsStatusEffectPermanent = 847,
|
|
863
|
+
DifficultyOptionsStatusEffectRateMultiplier = 848,
|
|
864
|
+
DifficultyOptionsStatusEffectMultiplier = 849,
|
|
865
|
+
DifficultyOptionsItemDurabilityMultiplier = 850,
|
|
866
|
+
DifficultyOptionsItemDecayMultiplier = 851,
|
|
867
|
+
TabCrafting = 852,
|
|
868
|
+
TabDismantle = 853,
|
|
869
|
+
WindowTitleContainer = 854,
|
|
870
|
+
WindowTitleInventory = 855
|
|
873
871
|
}
|
|
874
872
|
export default UiTranslation;
|
|
@@ -24,29 +24,43 @@ export interface IRegistry {
|
|
|
24
24
|
[SYMBOL_MOD_REGISTRATIONS]: ModRegistration[];
|
|
25
25
|
}
|
|
26
26
|
export declare abstract class BaseMod extends EventEmitter.Host<IModEvents> {
|
|
27
|
-
|
|
27
|
+
readonly index: number;
|
|
28
28
|
private allocatedEnums;
|
|
29
29
|
private registeredPackets;
|
|
30
30
|
private readonly subRegistries;
|
|
31
31
|
private subscribedHandlers;
|
|
32
32
|
constructor(index: number);
|
|
33
|
+
/** @deprecated Use the `index` property */
|
|
33
34
|
getIndex(): number;
|
|
34
35
|
/**
|
|
35
36
|
* Returns the name of this mod.
|
|
37
|
+
* @deprecated Use the `name` property
|
|
36
38
|
*/
|
|
37
39
|
getName(): string;
|
|
38
40
|
/**
|
|
39
41
|
* Returns the prefix for this mod used in registrations. Example: A mod named `Debug Tools` would be `ModDebugTools`
|
|
42
|
+
* @deprecated Use the `prefix` property
|
|
40
43
|
*/
|
|
41
44
|
getPrefix(): string;
|
|
45
|
+
/** @deprecated Use the `log` property */
|
|
46
|
+
getLog(): Log;
|
|
47
|
+
/** @deprecated Use the `path` property */
|
|
48
|
+
getPath(): string;
|
|
49
|
+
/** @deprecated Use the `version` property */
|
|
50
|
+
getVersion(): string;
|
|
51
|
+
get name(): string;
|
|
52
|
+
/**
|
|
53
|
+
* The prefix for this mod used in registrations. Example: A mod named `Debug Tools` would be `ModDebugTools`
|
|
54
|
+
*/
|
|
55
|
+
get prefix(): string;
|
|
56
|
+
get log(): Log;
|
|
57
|
+
get path(): string;
|
|
58
|
+
get version(): string;
|
|
42
59
|
/**
|
|
43
60
|
* Returns the full registry name for the given registration name, concatenating the mod registration prefix.
|
|
44
61
|
* Example: A mod named `Debug Tools` registering `Cool Thingy` would be `ModDebugToolsCoolThingy`
|
|
45
62
|
*/
|
|
46
63
|
getRegistryName(name: string): string;
|
|
47
|
-
getLog(): Log;
|
|
48
|
-
getPath(): string;
|
|
49
|
-
getVersion(): string;
|
|
50
64
|
loadFile(file: string): Promise<string | undefined>;
|
|
51
65
|
/**
|
|
52
66
|
* Called when the save data for this mod is retrieved from a field decorated with `@Mod.saveData`.
|
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
import type DoodadInfo from "game/doodad/DoodadInfo";
|
|
12
12
|
import type { DoodadType, IDoodadDescription } from "game/doodad/IDoodad";
|
|
13
13
|
import type { TerrainType } from "game/tile/ITerrain";
|
|
14
|
+
import type Tile from "game/tile/Tile";
|
|
14
15
|
import type ExploreMap from "renderer/exploreMap/ExploreMap";
|
|
15
16
|
export interface ITileUpdate {
|
|
16
17
|
terrainType: TerrainType;
|
|
@@ -27,8 +28,8 @@ export interface IDoodadUpdate {
|
|
|
27
28
|
hasGraphicVariation: boolean;
|
|
28
29
|
terrainMasks: TerrainMask;
|
|
29
30
|
}
|
|
30
|
-
export type onTileUpdateDelegate = (
|
|
31
|
-
export type onDoodadUpdateDelegate = (
|
|
31
|
+
export type onTileUpdateDelegate = (tile: Tile, flushTileImmediately: boolean, debug?: boolean) => void;
|
|
32
|
+
export type onDoodadUpdateDelegate = (tile: Tile, flushTileImmediately: boolean, doodadUpdate: IDoodadUpdate) => void;
|
|
32
33
|
export type TerrainData = number;
|
|
33
34
|
export declare enum TerrainMask {
|
|
34
35
|
None = 0,
|
|
@@ -60,7 +60,7 @@ export default class WorldLayer implements IPreSerializeCallback {
|
|
|
60
60
|
* Updates the rendered tile.
|
|
61
61
|
* All neighbors are updated by default, but the neighbor tile update is only done when updateNeighbors is true
|
|
62
62
|
*/
|
|
63
|
-
updateTile(
|
|
63
|
+
updateTile(tile: Tile, shouldUpdate: boolean, updateNeighbors: boolean, flushTileImmediately: boolean, isUpdatingNeighbors?: boolean, debug?: boolean): void;
|
|
64
64
|
getTileUpdate(tile: Tile): ITileUpdate;
|
|
65
65
|
private setTileInternal;
|
|
66
66
|
/**
|
|
@@ -19,6 +19,7 @@ import type { IBound3 } from "utilities/math/Bound3";
|
|
|
19
19
|
import type RendererContext from "renderer/context/RendererContext";
|
|
20
20
|
import type ExploredMapClientData from "save/clientStore/clientData/ExploredMap";
|
|
21
21
|
import type { IWorldLayerRendererEvents } from "renderer/world/IWorldLayerRenderer";
|
|
22
|
+
import type Tile from "game/tile/Tile";
|
|
22
23
|
export default class WorldLayerRenderer extends EventEmitter.Host<IWorldLayerRendererEvents> {
|
|
23
24
|
readonly context: RendererContext;
|
|
24
25
|
protected readonly worldRenderer: WorldRenderer;
|
|
@@ -58,7 +59,7 @@ export default class WorldLayerRenderer extends EventEmitter.Host<IWorldLayerRen
|
|
|
58
59
|
* Note: You must call bind the texture before calling this
|
|
59
60
|
*/
|
|
60
61
|
setExploredAlpha(x: number, y: number, alpha: Uint8Array): void;
|
|
61
|
-
updateDoodad(x
|
|
62
|
+
updateDoodad({ x, y }: Tile, flushTileImmediately: boolean, { doodadDescription, doodadType, doodadInfo, doodadVariationX, doodadVariationY, terrainMasks }: IDoodadUpdate): void;
|
|
62
63
|
renderFullbright(x: number, y: number, tileScale: number, viewWidth: number, viewHeight: number, renderFixedDepth: boolean, flags?: RenderLayerFlag): void;
|
|
63
64
|
getDataIndex(x: number, y: number): number;
|
|
64
65
|
setLayer(layer: TileLayer, dataIndex: number, tileAdaptation: TileAdaptor.ITileAdaptation): void;
|
|
@@ -78,7 +79,7 @@ export default class WorldLayerRenderer extends EventEmitter.Host<IWorldLayerRen
|
|
|
78
79
|
* Processes pending tile/doodad updates
|
|
79
80
|
*/
|
|
80
81
|
private processUpdates;
|
|
81
|
-
updateTile(
|
|
82
|
+
updateTile(tile: Tile, flushTileImmediately?: boolean, debug?: boolean): void;
|
|
82
83
|
private computeDoodad;
|
|
83
84
|
private computeTilled;
|
|
84
85
|
private computeDecorations;
|
|
@@ -94,8 +94,8 @@ export default class InGameScreen extends BaseScreen {
|
|
|
94
94
|
private sortingCancelled;
|
|
95
95
|
private onSortableAction;
|
|
96
96
|
private isCurrentlySorting;
|
|
97
|
-
|
|
98
|
-
|
|
97
|
+
craftableItemTypes: ItemType[] | undefined;
|
|
98
|
+
nonCraftableItemTypes: ItemType[] | undefined;
|
|
99
99
|
private dismantleItems;
|
|
100
100
|
private craftingDialogDirty;
|
|
101
101
|
private dismantleDialogDirty;
|
|
@@ -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 {
|
|
11
|
+
import type { IRGBA } from "utilities/Color";
|
|
12
12
|
export default class SpriteGlow {
|
|
13
13
|
private readonly data;
|
|
14
14
|
private readonly canvas;
|
|
@@ -24,7 +24,7 @@ export default class SpriteGlow {
|
|
|
24
24
|
* Releases a cache of data used for generation.
|
|
25
25
|
*/
|
|
26
26
|
releaseGenerationImageDataCache(): void;
|
|
27
|
-
render(path: string, color:
|
|
27
|
+
render(path: string, color: IRGBA, signal: AbortSignal): Promise<string | undefined>;
|
|
28
28
|
private renderInternal;
|
|
29
29
|
private getVersion;
|
|
30
30
|
private getGitVersionID;
|
|
@@ -18,10 +18,8 @@ export default class MultiplayerOptionsMenu extends Menu {
|
|
|
18
18
|
private readonly choiceLobbyFriends;
|
|
19
19
|
private readonly choiceLobbyPrivate;
|
|
20
20
|
private readonly textSteamRelayNetworkResult;
|
|
21
|
-
private readonly textWebRTCResult;
|
|
22
21
|
private readonly textWebSocketResult;
|
|
23
22
|
private readonly steamRelayNetworkSpacer;
|
|
24
|
-
private readonly webRTCSpacer;
|
|
25
23
|
private readonly pvp;
|
|
26
24
|
private readonly allowTraveling;
|
|
27
25
|
private readonly allowHardcoreRespawns;
|
|
@@ -21,10 +21,6 @@ export default class GlobalServerDirectory extends Server {
|
|
|
21
21
|
protected onMessage(connection: shared.ClientConnection, data: ws.Data, ipAddress: string): void;
|
|
22
22
|
private sendResponse;
|
|
23
23
|
private checkConnection;
|
|
24
|
-
/**
|
|
25
|
-
* Creates a new websocket connection to the matchmaking server and "joins" the game via webrtc
|
|
26
|
-
*/
|
|
27
|
-
private checkWebRTCConnection;
|
|
28
24
|
/**
|
|
29
25
|
* Connects to the servers websocket
|
|
30
26
|
* @param serverAddress Address to connect to
|
package/package.json
CHANGED