genshin-world 4.1.2 → 4.2.0
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/package.json +8 -8
- package/dist/ReactionType-BBSdxyO3.js +0 -47
- package/dist/addKitEffect-DBqTfm_3.js +0 -17
- package/dist/ainoKit-Dy3vTp3B.js +0 -28
- package/dist/albedoKit-CU5N1Hnm.js +0 -43
- package/dist/alhaithamKit-Bhs-coX9.js +0 -212
- package/dist/aloyKit-C7x_Jf16.js +0 -32
- package/dist/amberKit-BO7ZAQgU.js +0 -38
- package/dist/arlecchinoKit-DJawwVVl.js +0 -4
- package/dist/ayakaKit-Bu_QuYsR.js +0 -26
- package/dist/ayatoKit-BXZNajk7.js +0 -108
- package/dist/baizhuKit-8_4IzZ3A.js +0 -33
- package/dist/barbaraKit-B5DpLyHJ.js +0 -58
- package/dist/beidouKit-sQUahtIk.js +0 -59
- package/dist/bennettKit-Cr-zZ_25.js +0 -66
- package/dist/candaceKit-BUs_wwFU.js +0 -84
- package/dist/characterPack-YAEqbhAX.d.ts +0 -116
- package/dist/characterPack-zycIUHje.js +0 -641
- package/dist/characterPack.d.ts +0 -2
- package/dist/characterPack.js +0 -1
- package/dist/charlotteKit-BOZiCPEb.js +0 -90
- package/dist/chascaKit-C1Csj0Yf.js +0 -4
- package/dist/chevreuseKit-DDHga8Tj.js +0 -20
- package/dist/chioriKit-CxRUSHNw.js +0 -28
- package/dist/chongyunKit-jrWQKRkG.js +0 -104
- package/dist/citlaliKit-sv7XrzVx.js +0 -4
- package/dist/clorindeKit-DxtRn_To.js +0 -4
- package/dist/colleiKit-CO_n9qra.js +0 -28
- package/dist/columbinaKit-DrW0EvqN.js +0 -31
- package/dist/constants--ARZpp1u.js +0 -49
- package/dist/constants-BqrUOf2M.js +0 -48
- package/dist/constants-CSFiwyHy.js +0 -46
- package/dist/createWindriseGroundPaint-BmZkGq-r.js +0 -295
- package/dist/cynoKit-DpfT5dmS.js +0 -179
- package/dist/dahliaKit-B8fOPvvi.js +0 -16
- package/dist/dehyaKit-42tyEI0Z.js +0 -4
- package/dist/dilucKit-EwLUSPgs.js +0 -63
- package/dist/dionaKit-89B1hwYL.js +0 -48
- package/dist/doriKit-G9XTwwCP.js +0 -24
- package/dist/durinKit-BIYdUkbh.js +0 -49
- package/dist/emilieKit-0b2vhNtl.js +0 -21
- package/dist/escoffierKit-Da5UAvAF.js +0 -48
- package/dist/eulaKit-DAENHIEx.js +0 -129
- package/dist/faruzanKit-BcW6D-N3.js +0 -71
- package/dist/fischlKit-Bm8vNmuV.js +0 -98
- package/dist/flinsKit-GUnFJdUg.js +0 -9
- package/dist/freminetKit-CpwsVmTT.js +0 -4
- package/dist/furinaKit-BREisAdJ.js +0 -279
- package/dist/gamingKit-D9ekWGMJ.js +0 -4
- package/dist/ganyuKit-DLJa1t-Z.js +0 -74
- package/dist/gorouKit-DkpaGNA8.js +0 -94
- package/dist/heizouKit-B6kRXVCP.js +0 -35
- package/dist/huTaoKit-drjrzLjf.js +0 -58
- package/dist/iansanKit-RNjD9nSq.js +0 -4
- package/dist/ifaKit-CXWxCOPI.js +0 -4
- package/dist/illugaKit-BFtXIf3P.js +0 -4
- package/dist/index-DQB91Tfq.d.ts +0 -19820
- package/dist/index.d.ts +0 -4
- package/dist/index.js +0 -29218
- package/dist/ineffaKit-3J0FJo2E.js +0 -51
- package/dist/ittoKit-CfwXkR0g.js +0 -112
- package/dist/jahodaKit-C1sdSDfr.js +0 -97
- package/dist/jeanKit-Do8vx5Kp.js +0 -56
- package/dist/kachinaKit-DWLNDpgO.js +0 -4
- package/dist/kaeyaKit-DU8Df4RE.js +0 -14
- package/dist/kavehKit-BWoAaKs4.js +0 -9
- package/dist/kazuhaKit-C5gn8iGg.js +0 -55
- package/dist/keqingKit-uGsb_p7t.js +0 -12
- package/dist/kinichKit-Dp3lNUJt.js +0 -22
- package/dist/kiraraKit-CCAGXouk.js +0 -43
- package/dist/kleeKit-BzcJLC2i.js +0 -48
- package/dist/kokomiKit-DBdTlTDr.js +0 -42
- package/dist/kujouSaraKit-DDE-24jd.js +0 -56
- package/dist/kukiKit-DcARldP9.js +0 -59
- package/dist/lanYanKit-B3lwZ7OW.js +0 -18
- package/dist/laumaKit-DkG-i0rL.js +0 -59
- package/dist/laylaKit-DYtz0tSZ.js +0 -41
- package/dist/linneaKit-DlVhnbGM.js +0 -4
- package/dist/lisaKit-CWUiiam1.js +0 -22
- package/dist/lohenKit-D-uagI_g.js +0 -4
- package/dist/lynetteKit-BnNW81Pm.js +0 -20
- package/dist/lyneyKit-D6yTnfFv.js +0 -19
- package/dist/mavuikaKit-CUC1kHRJ.js +0 -4
- package/dist/mikaKit-C9xDhjJg.js +0 -17
- package/dist/mizukiKit-DY-gHM8N.js +0 -4
- package/dist/monaKit-B748iTEy.js +0 -26
- package/dist/mualaniKit-B-Km_dcQ.js +0 -4
- package/dist/nahidaKit-BGRc-swN.js +0 -4
- package/dist/naviaKit-CHh2VdX3.js +0 -64
- package/dist/neferKit-BTALTTiV.js +0 -4
- package/dist/neuvilletteKit-DAfX_2tC.js +0 -4
- package/dist/nicoleKit-BVjL7LI0.js +0 -4
- package/dist/nilouKit-BgM4u-hg.js +0 -52
- package/dist/ningguangKit-N88BhNb_.js +0 -105
- package/dist/noelleKit-DDewnuJ9.js +0 -48
- package/dist/ororonKit-DiAd2dlh.js +0 -86
- package/dist/pruneKit-CHkC_OSB.js +0 -4
- package/dist/qiqiKit-DCtsriE7.js +0 -88
- package/dist/raidenKit-BBWMmPFn.js +0 -144
- package/dist/razorKit-CBgdHYic.js +0 -90
- package/dist/readCharacterAvatar-C7FufK7J.js +0 -292
- package/dist/rosariaKit-D_RDXpLp.js +0 -29
- package/dist/save-CEbj1mOx.js +0 -854
- package/dist/save.d.ts +0 -2
- package/dist/save.js +0 -1
- package/dist/sayuKit-Hnv4iA3_.js +0 -35
- package/dist/sceneExport-BZaF05K-.d.ts +0 -70
- package/dist/sceneExport-DiiIi0PM.js +0 -27
- package/dist/sceneExport.d.ts +0 -2
- package/dist/sceneExport.js +0 -1
- package/dist/sethosKit-8EK04AA4.js +0 -4
- package/dist/shenheKit-DqrG2I4S.js +0 -50
- package/dist/sigewinneKit-CYJyadTr.js +0 -10
- package/dist/skirkKit-BDjoFGAq.js +0 -10
- package/dist/style.css +0 -3612
- package/dist/sucroseKit-DF0jcI2y.js +0 -101
- package/dist/tartagliaKit-Bbtww18S.js +0 -136
- package/dist/terrainTileWorker.d.ts +0 -1
- package/dist/terrainTileWorker.js +0 -81
- package/dist/thomaKit-Zm5AJ9Fm.js +0 -64
- package/dist/tighnariKit-CSa_Yqpp.js +0 -4
- package/dist/varesaKit-CMXLbBv9.js +0 -4
- package/dist/varkaKit-C8_HlTVH.js +0 -4
- package/dist/ventiKit-BcQkbI-z.js +0 -52
- package/dist/wandererKit-CQM691sn.js +0 -9
- package/dist/wriothesleyKit-CBTnYlOy.js +0 -4
- package/dist/xianglingKit-BPQN7cxU.js +0 -108
- package/dist/xianyunKit-CVhuYBde.js +0 -4
- package/dist/xiaoKit-BDI_SODG.js +0 -90
- package/dist/xilonenKit-YAVOPRwm.js +0 -4
- package/dist/xingqiuKit-Cv8JYeYO.js +0 -106
- package/dist/xinyanKit-CffF-Er0.js +0 -120
- package/dist/yaeMikoKit-xAKYm2K6.js +0 -44
- package/dist/yanfeiKit-C6elnkmn.js +0 -86
- package/dist/yaoyaoKit-CaPIIp-i.js +0 -4
- package/dist/yelanKit-Da0oQ6yu.js +0 -33
- package/dist/yoimiyaKit-DTENWB4y.js +0 -49
- package/dist/yunjinKit-PP4yeyn1.js +0 -22
- package/dist/zhongliKit-uMdKUTP-.js +0 -100
- package/dist/zibaiKit-Dq6mFWSx.js +0 -4
|
@@ -1,295 +0,0 @@
|
|
|
1
|
-
import { Color, MathUtils, Matrix4, Quaternion, Vector2, Vector3 } from "three";
|
|
2
|
-
import { GroundLayer, computeScatterPoints, createSeededRandom, createTerrainShapeHeight, getTerrainTileColumn, getTerrainTileRow } from "genshin-engine/terrainWorker";
|
|
3
|
-
//#region src/services/windrise/constants.ts
|
|
4
|
-
const WINDRISE_SEED = 0;
|
|
5
|
-
const WINDRISE_SCENE_EXPORT_COMPONENT = "windrise";
|
|
6
|
-
const WATER_SHALLOW_COLOR = 6280136;
|
|
7
|
-
const WATER_DEEP_COLOR = 1925032;
|
|
8
|
-
const WATER_DEEP_DEPTH = 6;
|
|
9
|
-
const WATER_FOAM_DEPTH = .6;
|
|
10
|
-
const WATER_CAUSTIC_STRENGTH = .35;
|
|
11
|
-
const UNDERWATER_FOG_COLOR = 2062982;
|
|
12
|
-
const UNDERWATER_FOG_DENSITY = .08;
|
|
13
|
-
const SUN_DISTANCE = 120;
|
|
14
|
-
const RIM_STRENGTH = .55;
|
|
15
|
-
const WINDRISE_START_POINT = {
|
|
16
|
-
x: 36,
|
|
17
|
-
z: 12
|
|
18
|
-
};
|
|
19
|
-
const OAK_BARK_PART = "Stages_Unique_CyTree01_Bark_Lod1";
|
|
20
|
-
const OAK_LEAF_PART = "Stages_Unique_CyTree01_Leaf_Lod1";
|
|
21
|
-
const PLANT_DOME_SCALE = [
|
|
22
|
-
.4,
|
|
23
|
-
.3,
|
|
24
|
-
.4
|
|
25
|
-
];
|
|
26
|
-
const TREE_PREFAB_NAME_PART = "Tree";
|
|
27
|
-
const WINDRISE_RAMP_OPTIONS = {
|
|
28
|
-
resolution: 64,
|
|
29
|
-
shade: 0,
|
|
30
|
-
softness: .08,
|
|
31
|
-
terminator: .52
|
|
32
|
-
};
|
|
33
|
-
const FOG_DENSITY = .0024;
|
|
34
|
-
const FOG_HEIGHT_FALLOFF = .02;
|
|
35
|
-
const FOG_START_DISTANCE = 60;
|
|
36
|
-
const SHADOW_MAX_FAR = 320;
|
|
37
|
-
const WINDRISE_GRADE_OPTIONS = {
|
|
38
|
-
contrast: 1.06,
|
|
39
|
-
highlightTint: [
|
|
40
|
-
.03,
|
|
41
|
-
.015,
|
|
42
|
-
-.015
|
|
43
|
-
],
|
|
44
|
-
saturation: 1.12,
|
|
45
|
-
shadowTint: [
|
|
46
|
-
-.01,
|
|
47
|
-
0,
|
|
48
|
-
.04
|
|
49
|
-
],
|
|
50
|
-
size: 32
|
|
51
|
-
};
|
|
52
|
-
const WINDRISE_START_MINUTES = 900;
|
|
53
|
-
const SUN_TILT = .45;
|
|
54
|
-
const CLOUD_COVERAGE = .42;
|
|
55
|
-
const WIND_DIRECTION = new Vector2(.94, .34).normalize();
|
|
56
|
-
const WIND_STRENGTH = .3;
|
|
57
|
-
const WIND_GUST_STRENGTH = .45;
|
|
58
|
-
const WIND_GUST_WIDTH = 30;
|
|
59
|
-
const WIND_GUST_SPEED = 7;
|
|
60
|
-
const GRASS_BLADE_HEIGHT = .5;
|
|
61
|
-
const GRASS_BLADE_WIDTH = .08;
|
|
62
|
-
const NEAR_GRASS_RING = {
|
|
63
|
-
cellsPerSide: 256,
|
|
64
|
-
fadeEnd: 38,
|
|
65
|
-
fadeStart: 28,
|
|
66
|
-
innerRadius: 0,
|
|
67
|
-
scale: 1,
|
|
68
|
-
spacing: .3
|
|
69
|
-
};
|
|
70
|
-
const MIDDLE_GRASS_RING = {
|
|
71
|
-
cellsPerSide: 192,
|
|
72
|
-
fadeEnd: 76,
|
|
73
|
-
fadeStart: 56,
|
|
74
|
-
innerRadius: 30,
|
|
75
|
-
scale: 1.7,
|
|
76
|
-
spacing: .8
|
|
77
|
-
};
|
|
78
|
-
const FLOWER_SPACING = 2.5;
|
|
79
|
-
const FLOWER_CANDIDATE_COUNT = 48;
|
|
80
|
-
const FLOWER_MIN_GRASS = .9;
|
|
81
|
-
const FLOWER_MIN_SIZE = .12;
|
|
82
|
-
const FLOWER_MAX_SIZE = .2;
|
|
83
|
-
const FLOWER_COLORS = [
|
|
84
|
-
16052710,
|
|
85
|
-
15914571,
|
|
86
|
-
12101352
|
|
87
|
-
];
|
|
88
|
-
const WINDRISE_SKY_KEYFRAMES = [
|
|
89
|
-
{
|
|
90
|
-
cloudLitColor: new Color(3953288),
|
|
91
|
-
cloudShadeColor: new Color(1911372),
|
|
92
|
-
hemisphereGroundColor: new Color(1714730),
|
|
93
|
-
hemisphereIntensity: .7,
|
|
94
|
-
hemisphereSkyColor: new Color(2901112),
|
|
95
|
-
horizonColor: new Color(2046056),
|
|
96
|
-
lightColor: new Color(9414911),
|
|
97
|
-
lightIntensity: .45,
|
|
98
|
-
minutes: 0,
|
|
99
|
-
starIntensity: 1,
|
|
100
|
-
zenithColor: new Color(727610)
|
|
101
|
-
},
|
|
102
|
-
{
|
|
103
|
-
cloudLitColor: new Color(6974104),
|
|
104
|
-
cloudShadeColor: new Color(3028064),
|
|
105
|
-
hemisphereGroundColor: new Color(2240554),
|
|
106
|
-
hemisphereIntensity: .65,
|
|
107
|
-
hemisphereSkyColor: new Color(3690114),
|
|
108
|
-
horizonColor: new Color(5921418),
|
|
109
|
-
lightColor: new Color(9414911),
|
|
110
|
-
lightIntensity: .3,
|
|
111
|
-
minutes: 300,
|
|
112
|
-
starIntensity: .6,
|
|
113
|
-
zenithColor: new Color(1912158)
|
|
114
|
-
},
|
|
115
|
-
{
|
|
116
|
-
cloudLitColor: new Color(16763048),
|
|
117
|
-
cloudShadeColor: new Color(9075360),
|
|
118
|
-
hemisphereGroundColor: new Color(4872762),
|
|
119
|
-
hemisphereIntensity: .8,
|
|
120
|
-
hemisphereSkyColor: new Color(8031420),
|
|
121
|
-
horizonColor: new Color(15903114),
|
|
122
|
-
lightColor: new Color(16756864),
|
|
123
|
-
lightIntensity: .05,
|
|
124
|
-
minutes: 360,
|
|
125
|
-
starIntensity: .1,
|
|
126
|
-
zenithColor: new Color(4876968)
|
|
127
|
-
},
|
|
128
|
-
{
|
|
129
|
-
cloudLitColor: new Color(16770252),
|
|
130
|
-
cloudShadeColor: new Color(11049144),
|
|
131
|
-
hemisphereGroundColor: new Color(6978116),
|
|
132
|
-
hemisphereIntensity: 1,
|
|
133
|
-
hemisphereSkyColor: new Color(10139872),
|
|
134
|
-
horizonColor: new Color(16764832),
|
|
135
|
-
lightColor: new Color(16763024),
|
|
136
|
-
lightIntensity: 1.4,
|
|
137
|
-
minutes: 420,
|
|
138
|
-
starIntensity: 0,
|
|
139
|
-
zenithColor: new Color(6987480)
|
|
140
|
-
},
|
|
141
|
-
{
|
|
142
|
-
cloudLitColor: new Color(16777215),
|
|
143
|
-
cloudShadeColor: new Color(12110050),
|
|
144
|
-
hemisphereGroundColor: new Color(6127418),
|
|
145
|
-
hemisphereIntensity: 1.3,
|
|
146
|
-
hemisphereSkyColor: new Color(9357567),
|
|
147
|
-
horizonColor: new Color(13625599),
|
|
148
|
-
lightColor: new Color(16774888),
|
|
149
|
-
lightIntensity: 2.8,
|
|
150
|
-
minutes: 720,
|
|
151
|
-
starIntensity: 0,
|
|
152
|
-
zenithColor: new Color(4165606)
|
|
153
|
-
},
|
|
154
|
-
{
|
|
155
|
-
cloudLitColor: new Color(16777215),
|
|
156
|
-
cloudShadeColor: new Color(12372706),
|
|
157
|
-
hemisphereGroundColor: new Color(6127418),
|
|
158
|
-
hemisphereIntensity: 1.3,
|
|
159
|
-
hemisphereSkyColor: new Color(9357567),
|
|
160
|
-
horizonColor: new Color(13625599),
|
|
161
|
-
lightColor: new Color(16774368),
|
|
162
|
-
lightIntensity: 2.6,
|
|
163
|
-
minutes: 900,
|
|
164
|
-
starIntensity: 0,
|
|
165
|
-
zenithColor: new Color(5019884)
|
|
166
|
-
},
|
|
167
|
-
{
|
|
168
|
-
cloudLitColor: new Color(16765096),
|
|
169
|
-
cloudShadeColor: new Color(9074856),
|
|
170
|
-
hemisphereGroundColor: new Color(5922872),
|
|
171
|
-
hemisphereIntensity: 1.05,
|
|
172
|
-
hemisphereSkyColor: new Color(10130632),
|
|
173
|
-
horizonColor: new Color(16759416),
|
|
174
|
-
lightColor: new Color(16756326),
|
|
175
|
-
lightIntensity: 1.5,
|
|
176
|
-
minutes: 1020,
|
|
177
|
-
starIntensity: 0,
|
|
178
|
-
zenithColor: new Color(5929152)
|
|
179
|
-
},
|
|
180
|
-
{
|
|
181
|
-
cloudLitColor: new Color(15243944),
|
|
182
|
-
cloudShadeColor: new Color(5917320),
|
|
183
|
-
hemisphereGroundColor: new Color(3817522),
|
|
184
|
-
hemisphereIntensity: .8,
|
|
185
|
-
hemisphereSkyColor: new Color(6972584),
|
|
186
|
-
horizonColor: new Color(14256800),
|
|
187
|
-
lightColor: new Color(16747120),
|
|
188
|
-
lightIntensity: .05,
|
|
189
|
-
minutes: 1080,
|
|
190
|
-
starIntensity: .2,
|
|
191
|
-
zenithColor: new Color(3816582)
|
|
192
|
-
},
|
|
193
|
-
{
|
|
194
|
-
cloudLitColor: new Color(4872336),
|
|
195
|
-
cloudShadeColor: new Color(2239570),
|
|
196
|
-
hemisphereGroundColor: new Color(1977388),
|
|
197
|
-
hemisphereIntensity: .7,
|
|
198
|
-
hemisphereSkyColor: new Color(3425914),
|
|
199
|
-
horizonColor: new Color(3817336),
|
|
200
|
-
lightColor: new Color(9414911),
|
|
201
|
-
lightIntensity: .35,
|
|
202
|
-
minutes: 1140,
|
|
203
|
-
starIntensity: .8,
|
|
204
|
-
zenithColor: new Color(1450572)
|
|
205
|
-
}
|
|
206
|
-
];
|
|
207
|
-
//#endregion
|
|
208
|
-
//#region src/models/world/TerrainWorkerMessageKind.ts
|
|
209
|
-
let TerrainWorkerMessageKind = /* @__PURE__ */ function(TerrainWorkerMessageKind) {
|
|
210
|
-
TerrainWorkerMessageKind["Failed"] = "failed";
|
|
211
|
-
TerrainWorkerMessageKind["Load"] = "load";
|
|
212
|
-
TerrainWorkerMessageKind["RegionGrounds"] = "regionGrounds";
|
|
213
|
-
TerrainWorkerMessageKind["Tile"] = "tile";
|
|
214
|
-
return TerrainWorkerMessageKind;
|
|
215
|
-
}({});
|
|
216
|
-
//#endregion
|
|
217
|
-
//#region src/services/world/createWorldHeight.ts
|
|
218
|
-
const createWorldHeight = (baseGround, regionGrounds) => createTerrainShapeHeight(baseGround, ...regionGrounds);
|
|
219
|
-
//#endregion
|
|
220
|
-
//#region src/services/windrise/computeWindrisePlants.ts
|
|
221
|
-
const SLOPE_REACH = .5;
|
|
222
|
-
const flowerColors = FLOWER_COLORS.map((flowerColor) => new Color(flowerColor));
|
|
223
|
-
const UP = new Vector3(0, 1, 0);
|
|
224
|
-
const matrix = new Matrix4();
|
|
225
|
-
const rotation = new Quaternion();
|
|
226
|
-
const scale = new Vector3();
|
|
227
|
-
const translation = new Vector3();
|
|
228
|
-
const getSlope = (getHeight, x, z) => {
|
|
229
|
-
const acrossX = getHeight(x - SLOPE_REACH, z) - getHeight(x + SLOPE_REACH, z);
|
|
230
|
-
const acrossZ = getHeight(x, z - SLOPE_REACH) - getHeight(x, z + SLOPE_REACH);
|
|
231
|
-
const up = SLOPE_REACH * 2;
|
|
232
|
-
return 1 - up / Math.hypot(acrossX, up, acrossZ);
|
|
233
|
-
};
|
|
234
|
-
const computeWindrisePlants = (key, size, { getHeight, getWeights, waterLevel }) => {
|
|
235
|
-
const left = getTerrainTileColumn(key) * size;
|
|
236
|
-
const back = getTerrainTileRow(key) * size;
|
|
237
|
-
const points = computeScatterPoints({
|
|
238
|
-
candidateCount: 48,
|
|
239
|
-
checkIsAccepted: (x, z) => {
|
|
240
|
-
const worldX = left + x;
|
|
241
|
-
const worldZ = back + z;
|
|
242
|
-
const height = getHeight(worldX, worldZ);
|
|
243
|
-
if (height < waterLevel) return false;
|
|
244
|
-
return getWeights(height, getSlope(getHeight, worldX, worldZ), worldX, worldZ)[GroundLayer.Grass] >= FLOWER_MIN_GRASS;
|
|
245
|
-
},
|
|
246
|
-
seed: key,
|
|
247
|
-
size,
|
|
248
|
-
spacing: FLOWER_SPACING
|
|
249
|
-
});
|
|
250
|
-
const plantCount = points.length / 2;
|
|
251
|
-
const plantMatrices = new Float32Array(plantCount * 16);
|
|
252
|
-
const plantColors = new Float32Array(plantCount * 3);
|
|
253
|
-
const random = createSeededRandom(key + 1);
|
|
254
|
-
for (let plantIndex = 0; plantIndex < plantCount; plantIndex++) {
|
|
255
|
-
const x = points[plantIndex * 2] ?? 0;
|
|
256
|
-
const z = points[plantIndex * 2 + 1] ?? 0;
|
|
257
|
-
translation.set(x, getHeight(left + x, back + z), z);
|
|
258
|
-
rotation.setFromAxisAngle(UP, random() * Math.PI * 2);
|
|
259
|
-
scale.setScalar(MathUtils.lerp(FLOWER_MIN_SIZE, FLOWER_MAX_SIZE, random()));
|
|
260
|
-
matrix.compose(translation, rotation, scale).toArray(plantMatrices, plantIndex * 16);
|
|
261
|
-
flowerColors[Math.floor(random() * flowerColors.length)]?.toArray(plantColors, plantIndex * 3);
|
|
262
|
-
}
|
|
263
|
-
return {
|
|
264
|
-
plantColors,
|
|
265
|
-
plantMatrices
|
|
266
|
-
};
|
|
267
|
-
};
|
|
268
|
-
//#endregion
|
|
269
|
-
//#region src/services/windrise/createWindriseGroundPaint.ts
|
|
270
|
-
const createWindriseGroundPaint = (groundLayers, surfaces) => {
|
|
271
|
-
const { color: groundColor, layers } = surfaces.Ground;
|
|
272
|
-
const getGroundLayerColors = (layer) => {
|
|
273
|
-
const color = new Color(layers[layer] ?? groundColor).getHex();
|
|
274
|
-
return {
|
|
275
|
-
color,
|
|
276
|
-
patchColor: color
|
|
277
|
-
};
|
|
278
|
-
};
|
|
279
|
-
return {
|
|
280
|
-
layerColors: {
|
|
281
|
-
[GroundLayer.Earth]: getGroundLayerColors(GroundLayer.Earth),
|
|
282
|
-
[GroundLayer.Grass]: getGroundLayerColors(GroundLayer.Grass),
|
|
283
|
-
[GroundLayer.Path]: getGroundLayerColors(GroundLayer.Path),
|
|
284
|
-
[GroundLayer.Rock]: getGroundLayerColors(GroundLayer.Rock),
|
|
285
|
-
[GroundLayer.Sand]: getGroundLayerColors(GroundLayer.Sand),
|
|
286
|
-
[GroundLayer.Snow]: getGroundLayerColors(GroundLayer.Snow)
|
|
287
|
-
},
|
|
288
|
-
layerField: groundLayers,
|
|
289
|
-
patchScale: 18,
|
|
290
|
-
pathFalloff: .6,
|
|
291
|
-
paths: []
|
|
292
|
-
};
|
|
293
|
-
};
|
|
294
|
-
//#endregion
|
|
295
|
-
export { WATER_DEEP_COLOR as A, WINDRISE_START_POINT as B, SHADOW_MAX_FAR as C, UNDERWATER_FOG_COLOR as D, TREE_PREFAB_NAME_PART as E, WINDRISE_RAMP_OPTIONS as F, WIND_STRENGTH as G, WIND_GUST_SPEED as H, WINDRISE_SCENE_EXPORT_COMPONENT as I, WINDRISE_SEED as L, WATER_FOAM_DEPTH as M, WATER_SHALLOW_COLOR as N, UNDERWATER_FOG_DENSITY as O, WINDRISE_GRADE_OPTIONS as P, WINDRISE_SKY_KEYFRAMES as R, RIM_STRENGTH as S, SUN_TILT as T, WIND_GUST_STRENGTH as U, WIND_DIRECTION as V, WIND_GUST_WIDTH as W, MIDDLE_GRASS_RING as _, CLOUD_COVERAGE as a, OAK_LEAF_PART as b, FLOWER_MAX_SIZE as c, FLOWER_SPACING as d, FOG_DENSITY as f, GRASS_BLADE_WIDTH as g, GRASS_BLADE_HEIGHT as h, TerrainWorkerMessageKind as i, WATER_DEEP_DEPTH as j, WATER_CAUSTIC_STRENGTH as k, FLOWER_MIN_GRASS as l, FOG_START_DISTANCE as m, computeWindrisePlants as n, FLOWER_CANDIDATE_COUNT as o, FOG_HEIGHT_FALLOFF as p, createWorldHeight as r, FLOWER_COLORS as s, createWindriseGroundPaint as t, FLOWER_MIN_SIZE as u, NEAR_GRASS_RING as v, SUN_DISTANCE as w, PLANT_DOME_SCALE as x, OAK_BARK_PART as y, WINDRISE_START_MINUTES as z };
|
package/dist/cynoKit-DpfT5dmS.js
DELETED
|
@@ -1,179 +0,0 @@
|
|
|
1
|
-
import "./characterPack-zycIUHje.js";
|
|
2
|
-
import { t as ReactionType } from "./ReactionType-BBSdxyO3.js";
|
|
3
|
-
import { a as ELECTRO_REACTION_TYPES } from "./constants-BqrUOf2M.js";
|
|
4
|
-
import { addKitStatus, buffKitMember, castKitField, castKitSummon, checkHasKitStatus, enterKitStance, findKitStance, findKitStatus, gainPartyMemberEnergy, getDeployedCharacterIds, startKitCooldown } from "./index.js";
|
|
5
|
-
//#region src/services/kit/characters/cynoKit.ts
|
|
6
|
-
const BURST_EXTENSIONS_MAX = 2;
|
|
7
|
-
const BURST_EXTENSIONS_STATUS_ID = "cyno-burst-extensions";
|
|
8
|
-
const BURST_BUFF_SOURCE = "cyno-burst";
|
|
9
|
-
const ELEMENTAL_MASTERY_SHARE_ASCENSION_4_NORMAL_ATTACK = 1.5;
|
|
10
|
-
const ELEMENTAL_MASTERY_SHARE_ASCENSION_4_BOLT = 2.5;
|
|
11
|
-
const ASCENSION_1 = 1;
|
|
12
|
-
const ASCENSION_4 = 4;
|
|
13
|
-
const JUDICATION_FIELD_ID = "cyno-judication";
|
|
14
|
-
const ENDSEER_STATUS_ID = "cyno-endseer";
|
|
15
|
-
const CONSTELLATION_2 = 2;
|
|
16
|
-
const CONSTELLATION_4 = 4;
|
|
17
|
-
const CONSTELLATION_6 = 6;
|
|
18
|
-
const C2_STATUS_ID = "cyno-c2";
|
|
19
|
-
const C2_ICD_STATUS_ID = "cyno-c2-icd";
|
|
20
|
-
const C2_SECONDS = 4;
|
|
21
|
-
const C2_ICD_SECONDS = .1;
|
|
22
|
-
const C2_STACKS_MAX = 5;
|
|
23
|
-
const C2_ELECTRO_DAMAGE_BONUS_PER_STACK = .1;
|
|
24
|
-
const C4_STATUS_ID = "cyno-c4";
|
|
25
|
-
const C4_STACKS_MAX = 5;
|
|
26
|
-
const C4_ENERGY = 3;
|
|
27
|
-
const C6_STATUS_ID = "cyno-c6";
|
|
28
|
-
const C6_ICD_STATUS_ID = "cyno-c6-icd";
|
|
29
|
-
const C6_SECONDS = 8;
|
|
30
|
-
const C6_ICD_SECONDS = .4;
|
|
31
|
-
const C6_STACKS_PER_TRIGGER = 4;
|
|
32
|
-
const C6_STACKS_MAX = 8;
|
|
33
|
-
const createElementalMasteryShareBonus = (share) => (combatant) => combatant.ascension >= ASCENSION_4 ? combatant.attributes.attributeTotalMap["FIGHT_PROP_ELEMENT_MASTERY"] * share : 0;
|
|
34
|
-
const getPactswornNormalAttackBonus = createElementalMasteryShareBonus(ELEMENTAL_MASTERY_SHARE_ASCENSION_4_NORMAL_ATTACK);
|
|
35
|
-
const getDuststalkerBoltBonus = createElementalMasteryShareBonus(ELEMENTAL_MASTERY_SHARE_ASCENSION_4_BOLT);
|
|
36
|
-
const addDayOfTheJackal = (kitEffectState, characterId, stacks) => addKitStatus(kitEffectState, characterId, {
|
|
37
|
-
id: C6_STATUS_ID,
|
|
38
|
-
secondsRemaining: C6_SECONDS,
|
|
39
|
-
stacks
|
|
40
|
-
});
|
|
41
|
-
const findJudicationField = (effects, characterId) => effects.find((effect) => effect.kind === "field" && effect.characterId === characterId && effect.id === JUDICATION_FIELD_ID);
|
|
42
|
-
const checkIsC4Reaction = ({ element, reactionType }) => ELECTRO_REACTION_TYPES.has(reactionType) || reactionType === ReactionType.Swirl && element === "Electric";
|
|
43
|
-
const createCynoKitBehaviour = ({ kit, readHit, readHits, readParameter, readSeconds, readStance }) => {
|
|
44
|
-
const extensionSeconds = readParameter("extensionSeconds");
|
|
45
|
-
const burstSeconds = readParameter("burstSeconds") + readSeconds("burstDurationCast");
|
|
46
|
-
const burstElementalMastery = readParameter("pactswornPathclearerElementalMastery");
|
|
47
|
-
const mortuaryRiteCooldownMultiplier = readParameter("mortuaryRiteCooldownSeconds") / kit.skillCooldownSeconds;
|
|
48
|
-
const judicationFirstSeconds = readSeconds("judicationFirst");
|
|
49
|
-
const judicationIntervalSeconds = readSeconds("judicationInterval");
|
|
50
|
-
const endseerSeconds = readSeconds("endseer");
|
|
51
|
-
const duststalkerBoltBehaviour = { additiveBaseDamageBonus: getDuststalkerBoltBonus };
|
|
52
|
-
const duststalkerBolt = readHit("duststalkerBolt", duststalkerBoltBehaviour);
|
|
53
|
-
const mortuaryRiteDuststalkerBolts = readHits("mortuaryRiteDuststalkerBolts", duststalkerBoltBehaviour);
|
|
54
|
-
const onNormalAttackStrike = ({ kitEffectState }, { body, combatant }) => {
|
|
55
|
-
const { characterId, constellationCount } = combatant;
|
|
56
|
-
if (constellationCount >= CONSTELLATION_2 && startKitCooldown(kitEffectState, characterId, C2_ICD_STATUS_ID, C2_ICD_SECONDS)) {
|
|
57
|
-
const stacks = Math.min(C2_STACKS_MAX, (findKitStatus(kitEffectState.effects, characterId, C2_STATUS_ID)?.stacks ?? 0) + 1);
|
|
58
|
-
addKitStatus(kitEffectState, characterId, {
|
|
59
|
-
id: C2_STATUS_ID,
|
|
60
|
-
secondsRemaining: C2_SECONDS,
|
|
61
|
-
stacks
|
|
62
|
-
});
|
|
63
|
-
buffKitMember(kitEffectState, characterId, {
|
|
64
|
-
amount: C2_ELECTRO_DAMAGE_BONUS_PER_STACK * stacks,
|
|
65
|
-
attribute: "FIGHT_PROP_ELEC_ADD_HURT",
|
|
66
|
-
secondsRemaining: C2_SECONDS,
|
|
67
|
-
source: C2_STATUS_ID
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
if (constellationCount >= CONSTELLATION_6 && findKitStance(kitEffectState.effects, characterId)) {
|
|
71
|
-
const day = findKitStatus(kitEffectState.effects, characterId, C6_STATUS_ID);
|
|
72
|
-
if (day && (day.stacks ?? 0) > 0 && startKitCooldown(kitEffectState, characterId, C6_ICD_STATUS_ID, C6_ICD_SECONDS)) {
|
|
73
|
-
day.stacks = (day.stacks ?? 0) - 1;
|
|
74
|
-
castKitSummon(kitEffectState, body, combatant, [duststalkerBolt]);
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
};
|
|
78
|
-
const invokerStrikeHit = { onStrike: onNormalAttackStrike };
|
|
79
|
-
const pactswornStrikeHit = {
|
|
80
|
-
additiveBaseDamageBonus: getPactswornNormalAttackBonus,
|
|
81
|
-
onStrike: onNormalAttackStrike
|
|
82
|
-
};
|
|
83
|
-
const castJudication = (kitEffectState, { position }, characterId) => {
|
|
84
|
-
castKitField(kitEffectState, characterId, position, {
|
|
85
|
-
id: JUDICATION_FIELD_ID,
|
|
86
|
-
nextTickSeconds: judicationFirstSeconds,
|
|
87
|
-
onTick: ({ kitEffectState: tickKitEffectState }) => {
|
|
88
|
-
if (!findKitStance(tickKitEffectState.effects, characterId)) return;
|
|
89
|
-
addKitStatus(tickKitEffectState, characterId, {
|
|
90
|
-
id: ENDSEER_STATUS_ID,
|
|
91
|
-
secondsRemaining: endseerSeconds
|
|
92
|
-
});
|
|
93
|
-
},
|
|
94
|
-
secondsRemaining: burstSeconds,
|
|
95
|
-
tickIntervalSeconds: judicationIntervalSeconds
|
|
96
|
-
});
|
|
97
|
-
};
|
|
98
|
-
const pactswornPathclearer = readStance("pactswornPathclearer", {
|
|
99
|
-
normalAttacks: [
|
|
100
|
-
{ hits: [pactswornStrikeHit] },
|
|
101
|
-
{ hits: [pactswornStrikeHit] },
|
|
102
|
-
{ hits: [pactswornStrikeHit] },
|
|
103
|
-
{ hits: [pactswornStrikeHit, pactswornStrikeHit] },
|
|
104
|
-
{ hits: [pactswornStrikeHit] }
|
|
105
|
-
],
|
|
106
|
-
skill: { onStart: ({ activeCombatant: combatant, body, kitEffectState }) => {
|
|
107
|
-
const { characterId } = combatant;
|
|
108
|
-
const stance = findKitStance(kitEffectState.effects, characterId);
|
|
109
|
-
if (!stance) return;
|
|
110
|
-
const extensions = findKitStatus(kitEffectState.effects, characterId, BURST_EXTENSIONS_STATUS_ID)?.stacks ?? 0;
|
|
111
|
-
if (extensions < BURST_EXTENSIONS_MAX) {
|
|
112
|
-
stance.secondsRemaining += extensionSeconds;
|
|
113
|
-
const judication = findJudicationField(kitEffectState.effects, characterId);
|
|
114
|
-
if (judication) judication.secondsRemaining += extensionSeconds;
|
|
115
|
-
addKitStatus(kitEffectState, characterId, {
|
|
116
|
-
id: BURST_EXTENSIONS_STATUS_ID,
|
|
117
|
-
secondsRemaining: stance.secondsRemaining,
|
|
118
|
-
stacks: extensions + 1
|
|
119
|
-
});
|
|
120
|
-
}
|
|
121
|
-
if (!checkHasKitStatus(kitEffectState.effects, characterId, ENDSEER_STATUS_ID)) return;
|
|
122
|
-
if (combatant.constellationCount >= CONSTELLATION_6) addDayOfTheJackal(kitEffectState, characterId, Math.min(C6_STACKS_MAX, (findKitStatus(kitEffectState.effects, characterId, C6_STATUS_ID)?.stacks ?? 0) + C6_STACKS_PER_TRIGGER));
|
|
123
|
-
castKitSummon(kitEffectState, body, combatant, mortuaryRiteDuststalkerBolts);
|
|
124
|
-
} }
|
|
125
|
-
});
|
|
126
|
-
return {
|
|
127
|
-
burst: { onStart: ({ activeCombatant: combatant, body, kitEffectState }) => {
|
|
128
|
-
const { ascension, characterId, constellationCount } = combatant;
|
|
129
|
-
enterKitStance(kitEffectState, combatant, pactswornPathclearer, burstSeconds, { isEndedOnSwap: true });
|
|
130
|
-
buffKitMember(kitEffectState, characterId, {
|
|
131
|
-
amount: burstElementalMastery,
|
|
132
|
-
attribute: "FIGHT_PROP_ELEMENT_MASTERY",
|
|
133
|
-
secondsRemaining: burstSeconds,
|
|
134
|
-
source: BURST_BUFF_SOURCE
|
|
135
|
-
});
|
|
136
|
-
addKitStatus(kitEffectState, characterId, {
|
|
137
|
-
id: BURST_EXTENSIONS_STATUS_ID,
|
|
138
|
-
secondsRemaining: burstSeconds,
|
|
139
|
-
stacks: 0
|
|
140
|
-
});
|
|
141
|
-
if (constellationCount >= CONSTELLATION_4) addKitStatus(kitEffectState, characterId, {
|
|
142
|
-
id: C4_STATUS_ID,
|
|
143
|
-
secondsRemaining: burstSeconds,
|
|
144
|
-
stacks: 0
|
|
145
|
-
});
|
|
146
|
-
if (constellationCount >= CONSTELLATION_6) addDayOfTheJackal(kitEffectState, characterId, C6_STACKS_PER_TRIGGER);
|
|
147
|
-
if (ascension >= ASCENSION_1) castJudication(kitEffectState, body, characterId);
|
|
148
|
-
} },
|
|
149
|
-
getSkillCooldownMultiplier: ({ activeCombatant: combatant, kitEffectState }) => findKitStance(kitEffectState.effects, combatant.characterId) ? mortuaryRiteCooldownMultiplier : 1,
|
|
150
|
-
normalAttacks: [
|
|
151
|
-
{ hits: [invokerStrikeHit] },
|
|
152
|
-
{ hits: [invokerStrikeHit] },
|
|
153
|
-
{ hits: [invokerStrikeHit, invokerStrikeHit] },
|
|
154
|
-
{ hits: [invokerStrikeHit] }
|
|
155
|
-
],
|
|
156
|
-
onKitEvent: (event, { characterIdCombatantMap, kitEffectState, party }, combatant) => {
|
|
157
|
-
const { characterId } = combatant;
|
|
158
|
-
if (event.kind === "CharacterSwapped") {
|
|
159
|
-
if (event.previousCharacterId !== characterId) return;
|
|
160
|
-
const buff = kitEffectState.effects.find((effect) => effect.kind === "buff" && effect.characterId === characterId && effect.source === BURST_BUFF_SOURCE);
|
|
161
|
-
if (buff?.kind === "buff") buff.secondsRemaining = 0;
|
|
162
|
-
const judication = findJudicationField(kitEffectState.effects, characterId);
|
|
163
|
-
if (judication) judication.secondsRemaining = 0;
|
|
164
|
-
return;
|
|
165
|
-
}
|
|
166
|
-
if (event.kind !== "ReactionTriggered") return;
|
|
167
|
-
const counter = findKitStatus(kitEffectState.effects, characterId, C4_STATUS_ID);
|
|
168
|
-
if (combatant.constellationCount < CONSTELLATION_4 || event.striker.characterId !== characterId || !counter || (counter.stacks ?? 0) >= C4_STACKS_MAX || !findKitStance(kitEffectState.effects, characterId) || !event.reactions.some(checkIsC4Reaction)) return;
|
|
169
|
-
counter.stacks = (counter.stacks ?? 0) + 1;
|
|
170
|
-
for (const memberId of getDeployedCharacterIds(party)) {
|
|
171
|
-
if (memberId === characterId) continue;
|
|
172
|
-
const member = characterIdCombatantMap.get(memberId);
|
|
173
|
-
if (member) gainPartyMemberEnergy(party, member, C4_ENERGY);
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
};
|
|
177
|
-
};
|
|
178
|
-
//#endregion
|
|
179
|
-
export { createCynoKitBehaviour };
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import "./characterPack-zycIUHje.js";
|
|
2
|
-
import { castKitShield, scheduleKitTask } from "./index.js";
|
|
3
|
-
//#region src/services/kit/characters/dahliaKit.ts
|
|
4
|
-
const createDahliaKitBehaviour = ({ readParameter, readSeconds }) => {
|
|
5
|
-
const shieldSeconds = readSeconds("radiantPsalterShield");
|
|
6
|
-
const burstShieldFlat = readParameter("radiantPsalterShieldFlatHealth");
|
|
7
|
-
const burstShieldShare = readParameter("radiantPsalterShieldMaxHealthShare");
|
|
8
|
-
const favonianFavorSeconds = readParameter("favonianFavorSeconds");
|
|
9
|
-
return { burst: { onStart: ({ activeCombatant: combatant, kitEffectState }) => scheduleKitTask(kitEffectState, combatant.characterId, shieldSeconds, ({ kitEffectState: tickState }) => castKitShield(tickState, combatant.characterId, {
|
|
10
|
-
element: "Water",
|
|
11
|
-
health: burstShieldShare * combatant.attributes.maxHealth + burstShieldFlat,
|
|
12
|
-
secondsRemaining: favonianFavorSeconds
|
|
13
|
-
})) } };
|
|
14
|
-
};
|
|
15
|
-
//#endregion
|
|
16
|
-
export { createDahliaKitBehaviour };
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import "./characterPack-zycIUHje.js";
|
|
2
|
-
import { t as addKitEffect } from "./addKitEffect-DBqTfm_3.js";
|
|
3
|
-
import { buffKitMember, castKitSummon } from "./index.js";
|
|
4
|
-
import { takeOne } from "@esposter/shared";
|
|
5
|
-
//#region src/services/kit/characters/dilucKit.ts
|
|
6
|
-
const DILUC_INFUSION_SECONDS = 8;
|
|
7
|
-
const DILUC_A4_EXTRA_INFUSION_SECONDS = 4;
|
|
8
|
-
const DILUC_A4_PYRO_DAMAGE_BONUS = .2;
|
|
9
|
-
const DAWN_SPAWN_METRES = 1;
|
|
10
|
-
const DAWN_METRES_PER_SECOND = 14;
|
|
11
|
-
const DAWN_TICK_COUNT = 8;
|
|
12
|
-
const DAWN_EXPLOSION_SECONDS = 1.7;
|
|
13
|
-
const createDilucKitBehaviour = ({ kit, readArea, readHitFields, readParameter, readSeconds }) => {
|
|
14
|
-
const launchSeconds = takeOne(kit.elementalBurst.hits).hitmarkSeconds;
|
|
15
|
-
const dawnPhoenixFields = readHitFields("dawnPhoenixHit", [
|
|
16
|
-
"hitArea",
|
|
17
|
-
"hitmarkSeconds",
|
|
18
|
-
"talentMultiplier"
|
|
19
|
-
]);
|
|
20
|
-
const dawnTickArea = readArea("dawnTick");
|
|
21
|
-
const dawnTickIntervalSeconds = readSeconds("dawnTickInterval");
|
|
22
|
-
const dawnTickMultiplier = readParameter("dawnTickMultiplier");
|
|
23
|
-
const dawnPhoenixTicks = Array.from({ length: DAWN_TICK_COUNT }, (_value, index) => ({
|
|
24
|
-
...dawnPhoenixFields,
|
|
25
|
-
hitArea: dawnTickArea,
|
|
26
|
-
hitmarkSeconds: launchSeconds + dawnTickIntervalSeconds * (index + 1),
|
|
27
|
-
talentMultiplier: dawnTickMultiplier
|
|
28
|
-
}));
|
|
29
|
-
const dawnPhoenixExplosion = {
|
|
30
|
-
...dawnPhoenixFields,
|
|
31
|
-
hitArea: readArea("dawnExplosion"),
|
|
32
|
-
hitmarkSeconds: launchSeconds + DAWN_EXPLOSION_SECONDS,
|
|
33
|
-
talentMultiplier: readParameter("dawnExplosionMultiplier")
|
|
34
|
-
};
|
|
35
|
-
return { burst: { onStart: ({ activeCombatant: combatant, body: { facing, height, position }, kitEffectState }) => {
|
|
36
|
-
const hasA4 = combatant.ascension >= 4;
|
|
37
|
-
const secondsRemaining = DILUC_INFUSION_SECONDS + (hasA4 ? DILUC_A4_EXTRA_INFUSION_SECONDS : 0);
|
|
38
|
-
addKitEffect(kitEffectState, {
|
|
39
|
-
characterId: combatant.characterId,
|
|
40
|
-
element: "Fire",
|
|
41
|
-
kind: "infusion",
|
|
42
|
-
secondsRemaining
|
|
43
|
-
});
|
|
44
|
-
if (hasA4) buffKitMember(kitEffectState, combatant.characterId, {
|
|
45
|
-
amount: DILUC_A4_PYRO_DAMAGE_BONUS,
|
|
46
|
-
attribute: "FIGHT_PROP_FIRE_ADD_HURT",
|
|
47
|
-
secondsRemaining
|
|
48
|
-
});
|
|
49
|
-
castKitSummon(kitEffectState, {
|
|
50
|
-
facing,
|
|
51
|
-
height,
|
|
52
|
-
position: {
|
|
53
|
-
x: position.x - Math.sin(facing) * DAWN_SPAWN_METRES,
|
|
54
|
-
z: position.z - Math.cos(facing) * DAWN_SPAWN_METRES
|
|
55
|
-
}
|
|
56
|
-
}, combatant, [...dawnPhoenixTicks, dawnPhoenixExplosion], { travel: {
|
|
57
|
-
metresPerSecond: DAWN_METRES_PER_SECOND,
|
|
58
|
-
startSeconds: launchSeconds
|
|
59
|
-
} });
|
|
60
|
-
} } };
|
|
61
|
-
};
|
|
62
|
-
//#endregion
|
|
63
|
-
export { createDilucKitBehaviour };
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import "./characterPack-zycIUHje.js";
|
|
2
|
-
import { castKitField, castKitShield, castKitSummon, changeKitMemberHealth, gainPartyMemberEnergy } from "./index.js";
|
|
3
|
-
import { takeOne } from "@esposter/shared";
|
|
4
|
-
//#region src/services/kit/characters/dionaKit.ts
|
|
5
|
-
const SIGNATURE_MIX_FIELD_RADIUS = 7;
|
|
6
|
-
const SIGNATURE_MIX_TICK_SECONDS = 2;
|
|
7
|
-
const SIGNATURE_MIX_FIELD_MARGIN_SECONDS = .5;
|
|
8
|
-
const SIGNATURE_MIX_FIELD_ID = "diona-signature-mix-field";
|
|
9
|
-
const SHIELD_CONSTELLATION = 2;
|
|
10
|
-
const SHIELD_CONSTELLATION_MULTIPLIER = 1.15;
|
|
11
|
-
const SIGNATURE_MIX_CONSTELLATION = 1;
|
|
12
|
-
const SIGNATURE_MIX_CONSTELLATION_ENERGY = 15;
|
|
13
|
-
const createDionaKitBehaviour = ({ kit, readHits, readParameter }) => {
|
|
14
|
-
const shieldMaxHealthShare = readParameter("shieldMaxHealthShare");
|
|
15
|
-
const shieldFlatHealth = readParameter("shieldFlatHealth");
|
|
16
|
-
const shieldSeconds = readParameter("shieldSeconds");
|
|
17
|
-
const holdShieldMultiplier = readParameter("holdShieldMultiplier");
|
|
18
|
-
const signatureMixHealMaxHealthShare = readParameter("signatureMixHealMaxHealthShare");
|
|
19
|
-
const signatureMixHealFlatHealth = readParameter("signatureMixHealFlatHealth");
|
|
20
|
-
const signatureMixSeconds = readParameter("signatureMixSeconds") + SIGNATURE_MIX_FIELD_MARGIN_SECONDS;
|
|
21
|
-
const signatureMixTicks = readHits("signatureMixTicks");
|
|
22
|
-
const signatureMixHitmarkSeconds = takeOne(kit.elementalBurst.hits).hitmarkSeconds;
|
|
23
|
-
const castShield = (kitEffectState, combatant, strengthMultiplier) => castKitShield(kitEffectState, combatant.characterId, {
|
|
24
|
-
element: "Ice",
|
|
25
|
-
health: (shieldMaxHealthShare * combatant.attributes.maxHealth + shieldFlatHealth) * strengthMultiplier * (combatant.constellationCount >= SHIELD_CONSTELLATION ? SHIELD_CONSTELLATION_MULTIPLIER : 1),
|
|
26
|
-
secondsRemaining: shieldSeconds
|
|
27
|
-
});
|
|
28
|
-
return {
|
|
29
|
-
burst: { onStart: ({ activeCombatant: combatant, body, kitEffectState }) => {
|
|
30
|
-
castKitField(kitEffectState, combatant.characterId, body.position, {
|
|
31
|
-
id: SIGNATURE_MIX_FIELD_ID,
|
|
32
|
-
nextTickSeconds: signatureMixHitmarkSeconds + SIGNATURE_MIX_TICK_SECONDS,
|
|
33
|
-
onTick: (tick) => changeKitMemberHealth(tick, combatant, tick.activeCombatant.characterId, signatureMixHealMaxHealthShare * combatant.attributes.maxHealth + signatureMixHealFlatHealth),
|
|
34
|
-
radius: SIGNATURE_MIX_FIELD_RADIUS,
|
|
35
|
-
secondsRemaining: signatureMixSeconds,
|
|
36
|
-
tickIntervalSeconds: SIGNATURE_MIX_TICK_SECONDS
|
|
37
|
-
});
|
|
38
|
-
castKitSummon(kitEffectState, body, combatant, signatureMixTicks, { secondsRemaining: signatureMixSeconds });
|
|
39
|
-
} },
|
|
40
|
-
onKitEvent: (event, { party }, combatant) => {
|
|
41
|
-
if (event.kind === "EffectExpired" && event.effect.kind === "field" && event.effect.id === SIGNATURE_MIX_FIELD_ID && event.effect.characterId === combatant.characterId && combatant.constellationCount >= SIGNATURE_MIX_CONSTELLATION) gainPartyMemberEnergy(party, combatant, SIGNATURE_MIX_CONSTELLATION_ENERGY);
|
|
42
|
-
},
|
|
43
|
-
skill: { onStart: ({ activeCombatant: combatant, kitEffectState }) => castShield(kitEffectState, combatant, 1) },
|
|
44
|
-
skillHolds: [{ onStart: ({ activeCombatant: combatant, kitEffectState }) => castShield(kitEffectState, combatant, holdShieldMultiplier) }]
|
|
45
|
-
};
|
|
46
|
-
};
|
|
47
|
-
//#endregion
|
|
48
|
-
export { createDionaKitBehaviour };
|
package/dist/doriKit-G9XTwwCP.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { castKitField, castKitSummon, createAheadBody } from "./index.js";
|
|
2
|
-
//#region src/services/kit/characters/doriKit.ts
|
|
3
|
-
const CONNECTOR_FIELD_RADIUS = 10;
|
|
4
|
-
const CONNECTOR_AHEAD_METRES = 5;
|
|
5
|
-
const createDoriKitBehaviour = ({ readHit, readSeconds }) => {
|
|
6
|
-
const connector = readHit("connector");
|
|
7
|
-
const connectorFirstTickSeconds = readSeconds("connectorFirstTick");
|
|
8
|
-
const connectorTickIntervalSeconds = readSeconds("connectorTickInterval");
|
|
9
|
-
const connectorSeconds = readSeconds("connector");
|
|
10
|
-
return { burst: { onStart: ({ activeCombatant: combatant, body, kitEffectState }) => {
|
|
11
|
-
const spot = createAheadBody(body, CONNECTOR_AHEAD_METRES);
|
|
12
|
-
castKitField(kitEffectState, combatant.characterId, spot.position, {
|
|
13
|
-
nextTickSeconds: connectorFirstTickSeconds,
|
|
14
|
-
onTick: ({ kitEffectState: tickEffectState }) => {
|
|
15
|
-
castKitSummon(tickEffectState, spot, combatant, [connector]);
|
|
16
|
-
},
|
|
17
|
-
radius: CONNECTOR_FIELD_RADIUS,
|
|
18
|
-
secondsRemaining: connectorSeconds,
|
|
19
|
-
tickIntervalSeconds: connectorTickIntervalSeconds
|
|
20
|
-
});
|
|
21
|
-
} } };
|
|
22
|
-
};
|
|
23
|
-
//#endregion
|
|
24
|
-
export { createDoriKitBehaviour };
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { addKitStatus, castKitSummon, checkHasKitStatus, enterKitStance, gainPartyMemberEnergy, startKitCooldown } from "./index.js";
|
|
2
|
-
//#region src/services/kit/characters/durinKit.ts
|
|
3
|
-
const BLACK_STATUS_SECONDS = 30;
|
|
4
|
-
const BLACK_STATUS_ID = "denial-of-darkness";
|
|
5
|
-
const SKILL_ENERGY_ICD_SECONDS = 6;
|
|
6
|
-
const SKILL_ENERGY_ICD_STATUS_ID = "durin-skill-energy-icd";
|
|
7
|
-
const DRAGON_SUMMON_ID = "durin-dragon";
|
|
8
|
-
const createDragonOnStart = (hits) => ({ activeCombatant: combatant, body, kitEffectState }, target) => {
|
|
9
|
-
for (const effect of kitEffectState.effects) if (effect.kind === "summon" && effect.id === DRAGON_SUMMON_ID && effect.combatant.characterId === combatant.characterId) effect.secondsRemaining = 0;
|
|
10
|
-
castKitSummon(kitEffectState, target ? {
|
|
11
|
-
facing: 0,
|
|
12
|
-
height: 0,
|
|
13
|
-
position: target.position
|
|
14
|
-
} : body, combatant, hits, { id: DRAGON_SUMMON_ID });
|
|
15
|
-
};
|
|
16
|
-
const endWindow = ({ activeCombatant: combatant, kitEffectState }) => {
|
|
17
|
-
for (const effect of kitEffectState.effects) if (effect.kind === "stance" && effect.characterId === combatant.characterId) effect.secondsRemaining = 0;
|
|
18
|
-
};
|
|
19
|
-
const createDurinKitBehaviour = ({ kit, readHits, readParameter, readStance }) => {
|
|
20
|
-
const windowSeconds = kit.elementalSkillChain?.windowSeconds ?? 0;
|
|
21
|
-
const recastEnergy = readParameter("recastEnergy");
|
|
22
|
-
const gainRecastEnergy = ({ activeCombatant: combatant, kitEffectState, party }) => {
|
|
23
|
-
if (!startKitCooldown(kitEffectState, combatant.characterId, SKILL_ENERGY_ICD_STATUS_ID, SKILL_ENERGY_ICD_SECONDS)) return;
|
|
24
|
-
gainPartyMemberEnergy(party, combatant, recastEnergy);
|
|
25
|
-
};
|
|
26
|
-
const recastWindow = readStance("recastWindow", { normalAttacks: [{ onStart: (start) => {
|
|
27
|
-
endWindow(start);
|
|
28
|
-
gainRecastEnergy(start);
|
|
29
|
-
addKitStatus(start.kitEffectState, start.activeCombatant.characterId, {
|
|
30
|
-
id: BLACK_STATUS_ID,
|
|
31
|
-
secondsRemaining: BLACK_STATUS_SECONDS
|
|
32
|
-
});
|
|
33
|
-
} }] });
|
|
34
|
-
return {
|
|
35
|
-
burst: { onStart: createDragonOnStart(readHits("whiteDragonTicks")) },
|
|
36
|
-
burstVariant: {
|
|
37
|
-
checkIsActive: ({ activeCombatant: combatant, kitEffectState }) => checkHasKitStatus(kitEffectState.effects, combatant.characterId, BLACK_STATUS_ID),
|
|
38
|
-
onStart: createDragonOnStart(readHits("blackDragonTicks"))
|
|
39
|
-
},
|
|
40
|
-
skill: { onStart: ({ activeCombatant: combatant, kitEffectState }) => enterKitStance(kitEffectState, combatant, recastWindow, windowSeconds) },
|
|
41
|
-
skillChain: [{ onStart: (start) => {
|
|
42
|
-
endWindow(start);
|
|
43
|
-
gainRecastEnergy(start);
|
|
44
|
-
for (const effect of start.kitEffectState.effects) if (effect.kind === "status" && effect.id === BLACK_STATUS_ID && effect.characterId === start.activeCombatant.characterId) effect.secondsRemaining = 0;
|
|
45
|
-
} }]
|
|
46
|
-
};
|
|
47
|
-
};
|
|
48
|
-
//#endregion
|
|
49
|
-
export { createDurinKitBehaviour };
|