xray16 1.0.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/LICENSE +21 -0
- package/README.md +57 -0
- package/package.json +38 -0
- package/plugins/built_at_info.ts +18 -0
- package/plugins/from_cast_utils.ts +34 -0
- package/plugins/global_declarations_transform.ts +24 -0
- package/plugins/inject_filename.ts +22 -0
- package/plugins/strip_lua_logger.ts +73 -0
- package/plugins/transform_luabind_class/plugin.ts +51 -0
- package/plugins/transform_luabind_class/transformation/class_declaration.ts +226 -0
- package/plugins/transform_luabind_class/transformation/constants.ts +4 -0
- package/plugins/transform_luabind_class/transformation/decorators.ts +16 -0
- package/plugins/transform_luabind_class/transformation/errors.ts +31 -0
- package/plugins/transform_luabind_class/transformation/index.ts +5 -0
- package/plugins/transform_luabind_class/transformation/members/accessors.ts +48 -0
- package/plugins/transform_luabind_class/transformation/members/constructor.ts +107 -0
- package/plugins/transform_luabind_class/transformation/members/fields.ts +53 -0
- package/plugins/transform_luabind_class/transformation/members/method.ts +70 -0
- package/plugins/transform_luabind_class/transformation/new.ts +14 -0
- package/plugins/transform_luabind_class/transformation/setup.ts +128 -0
- package/plugins/transform_luabind_class/transformation/super.ts +92 -0
- package/plugins/transform_luabind_class/transformation/utils.ts +90 -0
- package/plugins/utils/diagnostics.ts +24 -0
- package/src/index.d.ts +63 -0
- package/src/xr_constant.d.ts +976 -0
- package/src/xr_core.d.ts +347 -0
- package/src/xr_global.d.ts +613 -0
- package/src/xr_lib/xr_fs.d.ts +333 -0
- package/src/xr_lib/xr_math.d.ts +165 -0
- package/src/xr_lib/xr_utils.d.ts +407 -0
- package/src/xr_luabind.d.ts +34 -0
- package/src/xr_map/xr_map.d.ts +42 -0
- package/src/xr_object/xr_action.d.ts +482 -0
- package/src/xr_object/xr_alife.d.ts +206 -0
- package/src/xr_object/xr_anomaly.d.ts +50 -0
- package/src/xr_object/xr_artefact.d.ts +98 -0
- package/src/xr_object/xr_client_object.d.ts +1255 -0
- package/src/xr_object/xr_creature.d.ts +157 -0
- package/src/xr_object/xr_dialog.d.ts +34 -0
- package/src/xr_object/xr_item.d.ts +239 -0
- package/src/xr_object/xr_level.d.ts +166 -0
- package/src/xr_object/xr_physic.d.ts +119 -0
- package/src/xr_object/xr_quest.d.ts +47 -0
- package/src/xr_object/xr_server_object.d.ts +686 -0
- package/src/xr_online/xr_multiplayer.d.ts +299 -0
- package/src/xr_sound/xr_sound.d.ts +153 -0
- package/src/xr_type/xr_enums.d.ts +17 -0
- package/src/xr_type/xr_type.d.ts +70 -0
- package/src/xr_ui/README.md +277 -0
- package/src/xr_ui/demo/CServerList.png +0 -0
- package/src/xr_ui/demo/CUI3tButton.png +0 -0
- package/src/xr_ui/demo/CUICheckButton.png +0 -0
- package/src/xr_ui/demo/CUIComboBox.png +0 -0
- package/src/xr_ui/demo/CUICustomEdit.png +0 -0
- package/src/xr_ui/demo/CUIStatic.png +0 -0
- package/src/xr_ui/demo/CUITrackBar.png +0 -0
- package/src/xr_ui/xr_ui_core.d.ts +185 -0
- package/src/xr_ui/xr_ui_interface.d.ts +666 -0
|
@@ -0,0 +1,1255 @@
|
|
|
1
|
+
declare module "xray16" {
|
|
2
|
+
/**
|
|
3
|
+
* @source C++ class IRender_Visual
|
|
4
|
+
* @group xr_client_object
|
|
5
|
+
*/
|
|
6
|
+
export interface IXR_IRender_Visual {
|
|
7
|
+
dcast_PKinematicsAnimated(): IKinematicsAnimated;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* @source C++ class global
|
|
12
|
+
* @customConstructor object_factory
|
|
13
|
+
* @group xr_client_object
|
|
14
|
+
*/
|
|
15
|
+
export class object_factory {
|
|
16
|
+
protected constructor();
|
|
17
|
+
|
|
18
|
+
public register(
|
|
19
|
+
client_object_class: string,
|
|
20
|
+
server_object_class: string,
|
|
21
|
+
clsid: string,
|
|
22
|
+
script_clsid: TXR_class_key
|
|
23
|
+
): void;
|
|
24
|
+
|
|
25
|
+
public register(client_object_class: string, clsid: string, script_clsid: TXR_class_key): void;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* @source C++ class object_binder
|
|
30
|
+
* @customConstructor object_binder
|
|
31
|
+
* @group xr_client_object
|
|
32
|
+
*/
|
|
33
|
+
export class object_binder<T = game_object> extends EngineBinding {
|
|
34
|
+
public readonly object: T;
|
|
35
|
+
|
|
36
|
+
public constructor(object: T);
|
|
37
|
+
|
|
38
|
+
public save(packet: net_packet): void;
|
|
39
|
+
public load(reader: reader): void;
|
|
40
|
+
public update(delta: u32): void;
|
|
41
|
+
public reload(section: string): void;
|
|
42
|
+
public reinit(): void;
|
|
43
|
+
public net_export(net_packet: net_packet): void;
|
|
44
|
+
public net_save_relevant(): boolean;
|
|
45
|
+
public net_destroy(): void;
|
|
46
|
+
public net_Relcase(object: T): void;
|
|
47
|
+
public net_spawn(object: cse_alife_object): boolean;
|
|
48
|
+
public net_import(net_packet: net_packet): void;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* @source C++ class particle
|
|
53
|
+
* @customConstructor particle
|
|
54
|
+
* @group xr_client_object
|
|
55
|
+
*/
|
|
56
|
+
export class particle extends EngineBinding {
|
|
57
|
+
public constructor(particle_to_run: string, particle_params?: particle_params, auto_remove?: boolean);
|
|
58
|
+
public constructor(
|
|
59
|
+
particle_to_run: string,
|
|
60
|
+
bone_name: string,
|
|
61
|
+
particle_params: particle_params,
|
|
62
|
+
auto_remove: boolean
|
|
63
|
+
);
|
|
64
|
+
|
|
65
|
+
public completed(): boolean;
|
|
66
|
+
public set_angles(vector: vector): void;
|
|
67
|
+
public set_bone(bone_id: string): void;
|
|
68
|
+
public set_particle(value1: string, value2: boolean): void;
|
|
69
|
+
public set_position(vector: vector): void;
|
|
70
|
+
public set_velocity(vector: vector): void;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* @source C++ class particle_params
|
|
75
|
+
* @customConstructor particle_params
|
|
76
|
+
* @group xr_client_object
|
|
77
|
+
*/
|
|
78
|
+
export class particle_params {
|
|
79
|
+
public constructor();
|
|
80
|
+
public constructor(first?: vector, second?: vector, third?: vector);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* @source C++ class explosive
|
|
85
|
+
* @customConstructor explosive
|
|
86
|
+
* @group xr_core
|
|
87
|
+
*/
|
|
88
|
+
export class explosive extends EngineBinding {
|
|
89
|
+
protected constructor();
|
|
90
|
+
|
|
91
|
+
public explode(): void;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* @source C++ class holder
|
|
96
|
+
* @customConstructor holder
|
|
97
|
+
* @group xr_client_object
|
|
98
|
+
*/
|
|
99
|
+
export class holder {
|
|
100
|
+
public engaged(): boolean;
|
|
101
|
+
public Action(value1: u16, value2: u32): void;
|
|
102
|
+
public SetParam(value: i32, vector: vector): void;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* @source C++ class CGameObject : DLL_Pure, ISheduled, ICollidable, IRenderable
|
|
107
|
+
* @customConstructor CGameObject
|
|
108
|
+
* @group xr_client_object
|
|
109
|
+
*/
|
|
110
|
+
export class CGameObject extends DLL_Pure {
|
|
111
|
+
public Visual(): IXR_IRender_Visual;
|
|
112
|
+
public getEnabled(): boolean;
|
|
113
|
+
public _construct(): DLL_Pure;
|
|
114
|
+
public net_Import(net_packet: net_packet): void;
|
|
115
|
+
public getVisible(): boolean;
|
|
116
|
+
public net_Export(net_packet: net_packet): void;
|
|
117
|
+
public net_Spawn(cse_abstract: cse_abstract): boolean;
|
|
118
|
+
public use(object: CGameObject): boolean;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
/**
|
|
122
|
+
* @source C++ class hit
|
|
123
|
+
* @customConstructor hit
|
|
124
|
+
* @group xr_client_object
|
|
125
|
+
*/
|
|
126
|
+
export class hit {
|
|
127
|
+
public static readonly burn = 0;
|
|
128
|
+
public static readonly chemical_burn = 2;
|
|
129
|
+
public static readonly dummy = 12;
|
|
130
|
+
public static readonly explosion = 7;
|
|
131
|
+
public static readonly fire_wound = 8;
|
|
132
|
+
public static readonly light_burn = 11;
|
|
133
|
+
public static readonly radiation = 3;
|
|
134
|
+
public static readonly shock = 1;
|
|
135
|
+
public static readonly strike = 5;
|
|
136
|
+
public static readonly telepatic = 4;
|
|
137
|
+
public static readonly wound = 6;
|
|
138
|
+
|
|
139
|
+
public direction: vector;
|
|
140
|
+
public draftsman: game_object | null;
|
|
141
|
+
public impulse: f32;
|
|
142
|
+
public power: f32;
|
|
143
|
+
public type: TXR_hit_type;
|
|
144
|
+
|
|
145
|
+
public constructor();
|
|
146
|
+
public constructor(hit: hit);
|
|
147
|
+
|
|
148
|
+
public bone(bone: string): void;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* @group xr_client_object
|
|
153
|
+
*/
|
|
154
|
+
export type TXR_hit_types = typeof hit;
|
|
155
|
+
|
|
156
|
+
/**
|
|
157
|
+
* @group xr_client_object
|
|
158
|
+
*/
|
|
159
|
+
export type TXR_hit_type = EnumeratedStaticsValues<TXR_hit_types>;
|
|
160
|
+
|
|
161
|
+
/**
|
|
162
|
+
* @source C++ class danger_object
|
|
163
|
+
* @customConstructor danger_object
|
|
164
|
+
* @group xr_client_object
|
|
165
|
+
*/
|
|
166
|
+
export class danger_object {
|
|
167
|
+
public static attack_sound: 1;
|
|
168
|
+
public static attacked: 5;
|
|
169
|
+
public static bullet_ricochet: 0;
|
|
170
|
+
public static enemy_sound: 7;
|
|
171
|
+
public static entity_attacked: 2;
|
|
172
|
+
public static entity_corpse: 4;
|
|
173
|
+
public static entity_death: 3;
|
|
174
|
+
public static grenade: 6;
|
|
175
|
+
public static hit: 2;
|
|
176
|
+
public static sound: 1;
|
|
177
|
+
public static visual: 0;
|
|
178
|
+
|
|
179
|
+
public type(): TXR_danger_object;
|
|
180
|
+
public time(): u32;
|
|
181
|
+
public position(): vector;
|
|
182
|
+
public object(): game_object;
|
|
183
|
+
public perceive_type(): number; /* CDangerObject::EDangerPerceiveType */
|
|
184
|
+
public dependent_object(): game_object;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/**
|
|
188
|
+
* @group xr_client_object
|
|
189
|
+
*/
|
|
190
|
+
export type TXR_danger_objects = typeof danger_object;
|
|
191
|
+
|
|
192
|
+
/**
|
|
193
|
+
* @group xr_client_object
|
|
194
|
+
*/
|
|
195
|
+
export type TXR_danger_object = EnumeratedStaticsValues<TXR_danger_objects>;
|
|
196
|
+
|
|
197
|
+
/**
|
|
198
|
+
* Enumeration of relations.
|
|
199
|
+
*
|
|
200
|
+
* eRelationTypeFriend - 0
|
|
201
|
+
* eRelationTypeNeutral - 1
|
|
202
|
+
* eRelationTypeEnemy - 2
|
|
203
|
+
* eRelationTypeWorstEnemy - 3
|
|
204
|
+
* eRelationTypeLast - 4
|
|
205
|
+
* eRelationTypeDummy - -1
|
|
206
|
+
*
|
|
207
|
+
* @group xr_client_object
|
|
208
|
+
*/
|
|
209
|
+
export type TXR_relation = 0 | 1 | 2 | 3;
|
|
210
|
+
|
|
211
|
+
/**
|
|
212
|
+
* @source C++ class CSpaceRestrictor : CGameObject
|
|
213
|
+
* @customConstructor CSpaceRestrictor
|
|
214
|
+
* @group xr_client_object
|
|
215
|
+
*/
|
|
216
|
+
export class CSpaceRestrictor extends CGameObject {}
|
|
217
|
+
|
|
218
|
+
/**
|
|
219
|
+
* @source C++ class CLevelChanger : CGameObject
|
|
220
|
+
* @customConstructor CLevelChanger
|
|
221
|
+
* @group xr_client_object
|
|
222
|
+
*/
|
|
223
|
+
export class CLevelChanger extends CGameObject {}
|
|
224
|
+
|
|
225
|
+
/**
|
|
226
|
+
* @source C++ class smart_cover_object : CGameObject
|
|
227
|
+
* @customConstructor smart_cover_object
|
|
228
|
+
* @group xr_client_object
|
|
229
|
+
*/
|
|
230
|
+
export class smart_cover_object extends CGameObject {}
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* Custom extension.
|
|
234
|
+
* For reference: src/xrGame/script_game_object_script.cpp
|
|
235
|
+
*
|
|
236
|
+
* @group xr_client_object
|
|
237
|
+
*/
|
|
238
|
+
class game_object_callbacks_base {
|
|
239
|
+
/**
|
|
240
|
+
* Remove callback.
|
|
241
|
+
*
|
|
242
|
+
* @param type - type of callback
|
|
243
|
+
* @param cb - null to reset
|
|
244
|
+
*/
|
|
245
|
+
public set_callback(type: TXR_callback, cb: null): void;
|
|
246
|
+
|
|
247
|
+
// 0 todo: trade start
|
|
248
|
+
|
|
249
|
+
// 1 todo: trade stop
|
|
250
|
+
|
|
251
|
+
/**
|
|
252
|
+
* 2 todo;
|
|
253
|
+
*/
|
|
254
|
+
public set_callback(
|
|
255
|
+
type: TXR_callbacks["trade_sell_buy_item"],
|
|
256
|
+
cb?: ((item: game_object, money_direction: boolean, money: number) => void) | null,
|
|
257
|
+
object?: object_binder | null
|
|
258
|
+
): void;
|
|
259
|
+
|
|
260
|
+
// 3 todo: trade_perform_operation
|
|
261
|
+
|
|
262
|
+
/**
|
|
263
|
+
* 4 todo;
|
|
264
|
+
*/
|
|
265
|
+
public set_callback(
|
|
266
|
+
type: TXR_callbacks["zone_enter"],
|
|
267
|
+
cb?: ((zone: game_object, object: game_object) => void) | null,
|
|
268
|
+
object?: object_binder | null
|
|
269
|
+
): void;
|
|
270
|
+
|
|
271
|
+
/**
|
|
272
|
+
* 4 todo;
|
|
273
|
+
*/
|
|
274
|
+
public set_callback(
|
|
275
|
+
type: TXR_callbacks["zone_exit"],
|
|
276
|
+
cb?: ((zone: game_object, object: game_object) => void) | null,
|
|
277
|
+
object?: object_binder | null
|
|
278
|
+
): void;
|
|
279
|
+
|
|
280
|
+
// 6 todo: level_border_exit
|
|
281
|
+
|
|
282
|
+
// 7 todo: level_border_enter
|
|
283
|
+
|
|
284
|
+
/**
|
|
285
|
+
* 8 todo;
|
|
286
|
+
*/
|
|
287
|
+
public set_callback(
|
|
288
|
+
type: TXR_callbacks["death"],
|
|
289
|
+
cb?: (target: game_object, killer: game_object) => void,
|
|
290
|
+
object?: object_binder
|
|
291
|
+
): void;
|
|
292
|
+
|
|
293
|
+
/**
|
|
294
|
+
* 9 todo;
|
|
295
|
+
*/
|
|
296
|
+
public set_callback(
|
|
297
|
+
type: TXR_callbacks["patrol_path_in_point"],
|
|
298
|
+
cb?: ((object: game_object, action_type: number, point_index: number) => void) | null,
|
|
299
|
+
object?: object_binder | null
|
|
300
|
+
): void;
|
|
301
|
+
|
|
302
|
+
// 10 todo: inventory_pda
|
|
303
|
+
|
|
304
|
+
/**
|
|
305
|
+
* 11 todo:
|
|
306
|
+
*/
|
|
307
|
+
public set_callback(
|
|
308
|
+
type: TXR_callbacks["inventory_info"],
|
|
309
|
+
cb?: ((npc: game_object, info_id: string) => void) | null,
|
|
310
|
+
object?: object_binder | null
|
|
311
|
+
): void;
|
|
312
|
+
|
|
313
|
+
// 12 todo: article_info
|
|
314
|
+
|
|
315
|
+
/**
|
|
316
|
+
* 13 todo;
|
|
317
|
+
*/
|
|
318
|
+
public set_callback(
|
|
319
|
+
type: TXR_callbacks["task_state"],
|
|
320
|
+
cb?: ((task: CGameTask, state: TXR_TaskState) => void) | null,
|
|
321
|
+
object?: object_binder | null
|
|
322
|
+
): void;
|
|
323
|
+
|
|
324
|
+
// 14 todo: map_location_added
|
|
325
|
+
|
|
326
|
+
/**
|
|
327
|
+
* 15 Use some object.
|
|
328
|
+
*/
|
|
329
|
+
public set_callback(
|
|
330
|
+
type: TXR_callbacks["use_object"],
|
|
331
|
+
cb?: ((object: game_object) => void) | null,
|
|
332
|
+
object?: object_binder | null
|
|
333
|
+
): void;
|
|
334
|
+
public set_callback(
|
|
335
|
+
type: TXR_callbacks["use_object"],
|
|
336
|
+
cb?: ((object: game_object, who: game_object) => void) | null,
|
|
337
|
+
object?: object_binder | null
|
|
338
|
+
): void;
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* 16 Entity got hit.
|
|
342
|
+
*/
|
|
343
|
+
public set_callback(
|
|
344
|
+
type: TXR_callbacks["hit"],
|
|
345
|
+
cb?: ((object: game_object, damage: number, direction: vector, who: game_object, bone_id: number) => void) | null,
|
|
346
|
+
object?: object_binder | null
|
|
347
|
+
): void;
|
|
348
|
+
|
|
349
|
+
/**
|
|
350
|
+
* 17 todo;
|
|
351
|
+
*/
|
|
352
|
+
public set_callback(
|
|
353
|
+
type: TXR_callbacks["sound"],
|
|
354
|
+
cb?:
|
|
355
|
+
| ((
|
|
356
|
+
this: void,
|
|
357
|
+
object: game_object,
|
|
358
|
+
source_id: number,
|
|
359
|
+
sound_type: TXR_snd_type,
|
|
360
|
+
position: vector,
|
|
361
|
+
sound_power: number
|
|
362
|
+
) => void)
|
|
363
|
+
| null,
|
|
364
|
+
object?: object_binder | null
|
|
365
|
+
): void;
|
|
366
|
+
|
|
367
|
+
// 18 todo: action_movement
|
|
368
|
+
|
|
369
|
+
// 19 todo: action_watch
|
|
370
|
+
|
|
371
|
+
// 20 todo: action_removed
|
|
372
|
+
|
|
373
|
+
// 21 todo: action_animation
|
|
374
|
+
|
|
375
|
+
// 22 todo: action_sound
|
|
376
|
+
|
|
377
|
+
// 23 todo: action_particle
|
|
378
|
+
|
|
379
|
+
// 24 todo: action_object
|
|
380
|
+
|
|
381
|
+
// 25 todo: actor_sleep
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* 26 todo;
|
|
385
|
+
*/
|
|
386
|
+
public set_callback(
|
|
387
|
+
type: TXR_callbacks["helicopter_on_point"],
|
|
388
|
+
cb?: ((distance: number, current_position: vector, vertex_id: number) => void) | null,
|
|
389
|
+
object?: object_binder | null
|
|
390
|
+
): void;
|
|
391
|
+
|
|
392
|
+
/**
|
|
393
|
+
* 27 todo;
|
|
394
|
+
*/
|
|
395
|
+
public set_callback(
|
|
396
|
+
type: TXR_callbacks["helicopter_on_hit"],
|
|
397
|
+
cb?: ((damage: number, impulse: number, hit_type: number, who_id: number) => void) | null,
|
|
398
|
+
object?: object_binder | null
|
|
399
|
+
): void;
|
|
400
|
+
|
|
401
|
+
/**
|
|
402
|
+
* 28 todo;
|
|
403
|
+
*/
|
|
404
|
+
public set_callback(
|
|
405
|
+
type: TXR_callbacks["on_item_take"],
|
|
406
|
+
cb?: ((npc: game_object, item: game_object) => void) | null,
|
|
407
|
+
object?: object_binder | null
|
|
408
|
+
): void;
|
|
409
|
+
|
|
410
|
+
/**
|
|
411
|
+
* 29 todo;
|
|
412
|
+
*/
|
|
413
|
+
public set_callback(
|
|
414
|
+
type: TXR_callbacks["on_item_drop"],
|
|
415
|
+
cb?: ((npc: game_object, item: game_object) => void) | null,
|
|
416
|
+
object?: object_binder | null
|
|
417
|
+
): void;
|
|
418
|
+
|
|
419
|
+
/**
|
|
420
|
+
* 30 todo;
|
|
421
|
+
*/
|
|
422
|
+
public set_callback(
|
|
423
|
+
type: TXR_callbacks["script_animation"],
|
|
424
|
+
cb?: ((skip_multi_anim_check?: boolean) => void) | null,
|
|
425
|
+
object?: object | null
|
|
426
|
+
): void;
|
|
427
|
+
|
|
428
|
+
// 31 todo: trader_global_anim_request
|
|
429
|
+
|
|
430
|
+
// 32 todo: trader_head_anim_request
|
|
431
|
+
|
|
432
|
+
// 33 todo: trader_sound_end
|
|
433
|
+
|
|
434
|
+
/**
|
|
435
|
+
* 34 todo;
|
|
436
|
+
*/
|
|
437
|
+
public set_callback(
|
|
438
|
+
type: TXR_callbacks["take_item_from_box"],
|
|
439
|
+
cb?: ((npc: game_object, box: game_object, item: game_object) => void) | null,
|
|
440
|
+
object?: object_binder | null
|
|
441
|
+
): void;
|
|
442
|
+
|
|
443
|
+
// 35 todo: weapon_no_ammo
|
|
444
|
+
|
|
445
|
+
// 36 todo: key_press
|
|
446
|
+
|
|
447
|
+
// 37 todo: key_release
|
|
448
|
+
|
|
449
|
+
// 38 todo: key_hold
|
|
450
|
+
|
|
451
|
+
// 39 todo: mouse_move
|
|
452
|
+
|
|
453
|
+
// 40 todo: mouse_wheel
|
|
454
|
+
|
|
455
|
+
// 41 todo: controller_press
|
|
456
|
+
|
|
457
|
+
// 42 todo: controller_release
|
|
458
|
+
|
|
459
|
+
// 43 todo: controller_hold
|
|
460
|
+
|
|
461
|
+
// 44 todo: item_to_belt
|
|
462
|
+
|
|
463
|
+
// 45 todo: item_to_slot
|
|
464
|
+
|
|
465
|
+
// 46 todo: item_to_ruck
|
|
466
|
+
|
|
467
|
+
// 47 todo: actor_before_death
|
|
468
|
+
|
|
469
|
+
// 48 todo: on_attach_vehicle
|
|
470
|
+
|
|
471
|
+
// 49 todo: on_detach_vehicle
|
|
472
|
+
|
|
473
|
+
// 50 todo: on_use_vehicle
|
|
474
|
+
|
|
475
|
+
// 51 todo: weapon_zoom_in
|
|
476
|
+
|
|
477
|
+
// 52 todo: weapon_zoom_out
|
|
478
|
+
|
|
479
|
+
// 53 todo: weapon_jammed
|
|
480
|
+
|
|
481
|
+
public clear_callbacks(): void;
|
|
482
|
+
public set_enemy_callback(cb: null): void;
|
|
483
|
+
public set_enemy_callback<T>(cb: (this: T, object: game_object, enemy: game_object) => boolean, object: T): void;
|
|
484
|
+
public set_fastcall<T>(cb: (this: T) => boolean, context: T): void;
|
|
485
|
+
public set_patrol_extrapolate_callback(cb?: ((cur_pt: number) => boolean) | null, object?: object): void;
|
|
486
|
+
public set_smart_cover_target_selector(cb?: (object: game_object) => void, object?: object): void;
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
/*
|
|
490
|
+
* CAI_Stalker* cast_Stalker();
|
|
491
|
+
* CArtefact* cast_Artefact();
|
|
492
|
+
* CCar* cast_Car();
|
|
493
|
+
* CGameObject* cast_GameObject();
|
|
494
|
+
* CHelicopter* cast_Heli();
|
|
495
|
+
* CSpaceRestrictor* cast_SpaceRestrictor();
|
|
496
|
+
* CWeapon* cast_Weapon();
|
|
497
|
+
* CWeaponAmmo* cast_Ammo();
|
|
498
|
+
* CWeaponMagazined* cast_WeaponMagazined();
|
|
499
|
+
* ce_script_zone* cast_ScriptZone();
|
|
500
|
+
* class CCustomZone* cast_CustomZone();
|
|
501
|
+
* class CEntityAlive* cast_EntityAlive();
|
|
502
|
+
* class CPhysicsShellHolder* cast_PhysicsShellHolder();
|
|
503
|
+
* explosive* cast_Explosive();
|
|
504
|
+
*
|
|
505
|
+
* CTime get_info_time(char const*);
|
|
506
|
+
* bool bone_visible(char const*);
|
|
507
|
+
* bool has_ammo_type(unsigned char)
|
|
508
|
+
|
|
509
|
+
* bool is_on_belt(game_object*);
|
|
510
|
+
* bool use(game_object*);
|
|
511
|
+
*
|
|
512
|
+
* vector<MemorySpace::CNotYetVisibleObject,xalloc<MemorySpace::CNotYetVisibleObject> > not_yet_visible_objects();
|
|
513
|
+
* vector<MemorySpace::CSoundObject,xalloc<MemorySpace::CSoundObject>> memory_sound_objects();
|
|
514
|
+
|
|
515
|
+
* enum DetailPathManager::EDetailPathType detail_path_type();
|
|
516
|
+
* enum ETaskState get_task_state(char const*);
|
|
517
|
+
* enum MonsterSpace::EBodyState body_state();
|
|
518
|
+
* enum MonsterSpace::EBodyState target_body_state();
|
|
519
|
+
* enum MonsterSpace::EMentalState mental_state();
|
|
520
|
+
* enum MonsterSpace::EMentalState target_mental_state();
|
|
521
|
+
* enum MonsterSpace::EMovementType movement_type();
|
|
522
|
+
* enum MovementManager::EPathType path_type();
|
|
523
|
+
*
|
|
524
|
+
* float get_actor_jump_speed();
|
|
525
|
+
* float get_actor_max_walk_weight();
|
|
526
|
+
* float get_actor_max_weight();
|
|
527
|
+
* float get_actor_run_coef();
|
|
528
|
+
* float get_actor_runback_coef();
|
|
529
|
+
* float get_actor_sprint_koef();
|
|
530
|
+
* float get_additional_max_walk_weight();
|
|
531
|
+
* float get_additional_max_weight();
|
|
532
|
+
* float get_anomaly_power();
|
|
533
|
+
* float get_artefact_bleeding();
|
|
534
|
+
* float get_artefact_health();
|
|
535
|
+
* float get_artefact_power();
|
|
536
|
+
* float get_artefact_radiation();
|
|
537
|
+
* float get_artefact_satiety();
|
|
538
|
+
* float get_luminocity();
|
|
539
|
+
* float get_luminocity_hemi();
|
|
540
|
+
* float get_total_weight();
|
|
541
|
+
*
|
|
542
|
+
|
|
543
|
+
* game_object* get_attached_vehicle();
|
|
544
|
+
*
|
|
545
|
+
* holder* cast_HolderCustom();
|
|
546
|
+
* int get_ammo_count_for_type(unsigned char);
|
|
547
|
+
*
|
|
548
|
+
* unsigned char get_max_uses();
|
|
549
|
+
* unsigned char get_remaining_uses();
|
|
550
|
+
* unsigned char get_restrictor_type();
|
|
551
|
+
* unsigned char get_weapon_substate();
|
|
552
|
+
*
|
|
553
|
+
* unsigned int belt_count();
|
|
554
|
+
* unsigned int get_main_weapon_type();
|
|
555
|
+
* unsigned int get_spatial_type();
|
|
556
|
+
* remove_danger();
|
|
557
|
+
* remove_memory_sound_object();
|
|
558
|
+
* remove_memory_visible_object();
|
|
559
|
+
* remove_memory_hit_object();
|
|
560
|
+
* unsigned int get_state();
|
|
561
|
+
* unsigned int get_weapon_type();
|
|
562
|
+
* unsigned int play_hud_motion(char const*,bool,unsigned int);
|
|
563
|
+
*
|
|
564
|
+
* void attach_vehicle(game_object*);
|
|
565
|
+
* void clear_game_news();
|
|
566
|
+
* void detach_vehicle();
|
|
567
|
+
* void force_set_position(vector,bool);
|
|
568
|
+
*
|
|
569
|
+
* void iterate_feel_touch(function<void>);
|
|
570
|
+
|
|
571
|
+
* void phantom_set_enemy(game_object*);
|
|
572
|
+
* void set_actor_jump_speed(float);
|
|
573
|
+
* void set_actor_max_walk_weight(float);
|
|
574
|
+
* void set_actor_max_weight(float);
|
|
575
|
+
* void set_actor_run_coef(float);
|
|
576
|
+
* void set_actor_runback_coef(float);
|
|
577
|
+
* void set_actor_sprint_koef(float);
|
|
578
|
+
* void set_additional_max_walk_weight(float);
|
|
579
|
+
* void set_additional_max_weight(float);
|
|
580
|
+
* void set_alien_control(bool);
|
|
581
|
+
* void set_ammo_type(unsigned char);
|
|
582
|
+
*
|
|
583
|
+
* void set_artefact_bleeding(float);
|
|
584
|
+
* void set_artefact_health(float);
|
|
585
|
+
* void set_artefact_power(float);
|
|
586
|
+
* void set_artefact_radiation(float);
|
|
587
|
+
* void set_artefact_satiety(float);
|
|
588
|
+
*
|
|
589
|
+
* void set_bone_visible(char const*,bool,bool);
|
|
590
|
+
* void set_character_icon(char const*);
|
|
591
|
+
* void set_health_ex(float);
|
|
592
|
+
* void set_main_weapon_type(unsigned int);
|
|
593
|
+
|
|
594
|
+
*
|
|
595
|
+
* void set_remaining_uses(unsigned char);
|
|
596
|
+
* void set_restrictor_type(unsigned char);
|
|
597
|
+
* void set_spatial_type(unsigned int);
|
|
598
|
+
* void set_weapon_type(unsigned int);
|
|
599
|
+
|
|
600
|
+
* void start_trade(game_object*);
|
|
601
|
+
* void start_upgrade(game_object*);
|
|
602
|
+
* void switch_state(unsigned int);
|
|
603
|
+
* }
|
|
604
|
+
*/
|
|
605
|
+
|
|
606
|
+
/**
|
|
607
|
+
* Visibility state of bloodsucker.
|
|
608
|
+
* Possible values are:
|
|
609
|
+
* - unset = -1,
|
|
610
|
+
* - no_visibility = 0,
|
|
611
|
+
* - partial_visibility = 1,
|
|
612
|
+
* - full_visibility = 2
|
|
613
|
+
*
|
|
614
|
+
* @source C++ enum visibility_t
|
|
615
|
+
*/
|
|
616
|
+
export type TXR_bloodsucker_visibility_state = -1 | 0 | 1 | 2;
|
|
617
|
+
|
|
618
|
+
/**
|
|
619
|
+
* @source C++ enum visibility_t
|
|
620
|
+
*/
|
|
621
|
+
export type TXR_game_object_path = 0 | 1 | 2 | 3 | number;
|
|
622
|
+
|
|
623
|
+
/**
|
|
624
|
+
* Client object base representing generic in-game entities from items to mutants and stalkers.
|
|
625
|
+
*
|
|
626
|
+
* @source C++ class game_object
|
|
627
|
+
* @customConstructor game_object
|
|
628
|
+
* @group xr_client_object
|
|
629
|
+
*/
|
|
630
|
+
export class game_object extends game_object_callbacks_base {
|
|
631
|
+
public static readonly dummy: -1;
|
|
632
|
+
|
|
633
|
+
public static readonly game_path: 0;
|
|
634
|
+
public static readonly level_path: 1;
|
|
635
|
+
public static readonly patrol_path: 2;
|
|
636
|
+
public static readonly no_path: 3;
|
|
637
|
+
|
|
638
|
+
public static readonly friend: 0;
|
|
639
|
+
public static readonly neutral: 1;
|
|
640
|
+
public static readonly enemy: 2;
|
|
641
|
+
|
|
642
|
+
public static readonly alifeMovementTypeMask: 0;
|
|
643
|
+
public static readonly alifeMovementTypeRandom: 1;
|
|
644
|
+
|
|
645
|
+
public static readonly dialog_pda_msg: 0;
|
|
646
|
+
public static readonly info_pda_msg: 1;
|
|
647
|
+
public static readonly no_pda_msg: 2;
|
|
648
|
+
|
|
649
|
+
public static readonly relation_kill: 0;
|
|
650
|
+
public static readonly relation_attack: 1;
|
|
651
|
+
public static readonly relation_fight_help_human: 2;
|
|
652
|
+
public static readonly relation_fight_help_monster: 4;
|
|
653
|
+
|
|
654
|
+
public static readonly movement: 0;
|
|
655
|
+
public static readonly watch: 1;
|
|
656
|
+
public static readonly animation: 2;
|
|
657
|
+
public static readonly sound: 3;
|
|
658
|
+
public static readonly particle: 4;
|
|
659
|
+
public static readonly object: 5;
|
|
660
|
+
public static readonly action_type_count: 6;
|
|
661
|
+
|
|
662
|
+
public satiety: f32;
|
|
663
|
+
/**
|
|
664
|
+
* Intensity of actor bleeding.
|
|
665
|
+
* 0 - no bleeding.
|
|
666
|
+
*/
|
|
667
|
+
public bleeding: f32;
|
|
668
|
+
/**
|
|
669
|
+
* Object health value
|
|
670
|
+
* From 0 to 1.
|
|
671
|
+
*/
|
|
672
|
+
public health: f32;
|
|
673
|
+
public morale: f32;
|
|
674
|
+
public power: f32;
|
|
675
|
+
public psy_health: f32;
|
|
676
|
+
public radiation: f32;
|
|
677
|
+
|
|
678
|
+
protected constructor();
|
|
679
|
+
|
|
680
|
+
/**
|
|
681
|
+
* Get engine client object ID.
|
|
682
|
+
*/
|
|
683
|
+
public id(): u16;
|
|
684
|
+
public story_id(): u32;
|
|
685
|
+
public object(value: i32 | string): game_object | null;
|
|
686
|
+
public clsid(): TXR_class_id;
|
|
687
|
+
|
|
688
|
+
public add_animation(animation: string, hand_usage: boolean, use_movement_controller: boolean): void;
|
|
689
|
+
public add_animation(
|
|
690
|
+
animation: string,
|
|
691
|
+
hand_usage: boolean,
|
|
692
|
+
position: vector,
|
|
693
|
+
rotation: vector,
|
|
694
|
+
local_animation: boolean
|
|
695
|
+
): void;
|
|
696
|
+
|
|
697
|
+
public action(): entity_action;
|
|
698
|
+
public action_count(): u32;
|
|
699
|
+
public active_detector(): game_object | null;
|
|
700
|
+
public active_item(): game_object | null;
|
|
701
|
+
/**
|
|
702
|
+
* @returns active item slot of game object
|
|
703
|
+
*/
|
|
704
|
+
public active_slot<T extends u32>(): T;
|
|
705
|
+
public active_zone_contact(value: u16): boolean;
|
|
706
|
+
public add_restrictions(out_restriction: string, in_restriction: string): void;
|
|
707
|
+
public animation_slot(): i32;
|
|
708
|
+
public base_out_restrictions(): string;
|
|
709
|
+
public best_item(): game_object | null;
|
|
710
|
+
public best_weapon(): game_object | null;
|
|
711
|
+
public bind_object(binder: object_binder): void;
|
|
712
|
+
public binded_object(): object_binder;
|
|
713
|
+
public burer_set_force_gravi_attack(value: boolean): void;
|
|
714
|
+
public buy_supplies(value1: ini_file, value2: string): void;
|
|
715
|
+
public can_select_weapon(): boolean;
|
|
716
|
+
public can_select_weapon(value: boolean): void;
|
|
717
|
+
public can_throw_grenades(): boolean;
|
|
718
|
+
public can_throw_grenades(value: boolean): void;
|
|
719
|
+
public clear_animations(): void;
|
|
720
|
+
public clear_override_animation(): void;
|
|
721
|
+
public debug_planner(action_planner: action_planner): void;
|
|
722
|
+
public disable_info_portion(value: string): boolean;
|
|
723
|
+
public disable_talk(): void;
|
|
724
|
+
public disable_trade(): void;
|
|
725
|
+
public dont_has_info(value: string): boolean;
|
|
726
|
+
/**
|
|
727
|
+
* Drop item from inventory.
|
|
728
|
+
*
|
|
729
|
+
* @param item - game object to drop
|
|
730
|
+
*/
|
|
731
|
+
public drop_item(item: game_object): void;
|
|
732
|
+
public enable_night_vision(value: boolean): void;
|
|
733
|
+
public external_sound_start(value: string): void;
|
|
734
|
+
public get_bone_id(value: string): u16;
|
|
735
|
+
public get_current_direction(): vector;
|
|
736
|
+
public get_current_outfit_protection(value: i32): f32;
|
|
737
|
+
public get_dest_smart_cover(): cover_point;
|
|
738
|
+
public get_dest_smart_cover_name(): string | null;
|
|
739
|
+
public get_monster_hit_info(): MonsterHitInfo;
|
|
740
|
+
public get_physics_object(): CPhysicObject;
|
|
741
|
+
/**
|
|
742
|
+
* @returns whether object is controlled by lua script
|
|
743
|
+
*/
|
|
744
|
+
public get_script(): boolean;
|
|
745
|
+
public get_smart_cover_description(): string;
|
|
746
|
+
public give_talk_message(value1: string, value2: string, value3: string): void;
|
|
747
|
+
public idle_max_time(): f32;
|
|
748
|
+
public idle_max_time(time: f32): void;
|
|
749
|
+
public in_current_loophole_fov(vector: vector): boolean;
|
|
750
|
+
public inventory_for_each(cb: () => void): void;
|
|
751
|
+
public is_door_blocked_by_npc(): boolean;
|
|
752
|
+
public is_talk_enabled(): boolean;
|
|
753
|
+
public is_weapon_going_to_be_strapped(weapon: game_object | null): boolean;
|
|
754
|
+
public iterate_inventory_box(cb: (box: game_object, item: game_object) => void, object: game_object): void;
|
|
755
|
+
public lookout_max_time(): f32;
|
|
756
|
+
public lookout_max_time(value: f32): void;
|
|
757
|
+
public max_ignore_monster_distance(): f32;
|
|
758
|
+
public max_ignore_monster_distance(value: f32): void;
|
|
759
|
+
public memory_hit_objects(): unknown; // :vector<MemorySpace::CHitObject, xalloc<struct MemorySpace::CHitObject>
|
|
760
|
+
public memory_time(another: game_object): u32;
|
|
761
|
+
public memory_visible_objects(): LuaIterable<visible_memory_object>;
|
|
762
|
+
public mental_state<T extends number>(): T; // todo: unknown enum
|
|
763
|
+
public not_yet_visible_objects(): unknown;
|
|
764
|
+
public object_count(): u32;
|
|
765
|
+
public path_completed(): boolean;
|
|
766
|
+
public relation(game_object: game_object): TXR_relation;
|
|
767
|
+
public release_stand_sleep_animation(): void;
|
|
768
|
+
public reset_action_queue(): void;
|
|
769
|
+
public restore_sound_threshold(): void;
|
|
770
|
+
public set_weight(weight: f32): void;
|
|
771
|
+
public set_actor_direction(value: f32): void;
|
|
772
|
+
public set_ammo_elapsed(value: i32): void;
|
|
773
|
+
public set_community_goodwill(first: string, second: i32): void;
|
|
774
|
+
public set_const_force(vector: vector, value: f32, time_interval: u32): void;
|
|
775
|
+
public set_dest_smart_cover(): void;
|
|
776
|
+
public set_dest_smart_cover(value: string): void;
|
|
777
|
+
public set_enemy(object: game_object): void;
|
|
778
|
+
public set_fov(fov: f32): void;
|
|
779
|
+
public set_item(action_id: number, game_object: game_object | null, value1?: u32, value2?: u32): void;
|
|
780
|
+
public set_mental_state(state: TXR_animation): void;
|
|
781
|
+
public set_override_animation(animation: string): void;
|
|
782
|
+
public set_path_type(type: TXR_game_object_path): void;
|
|
783
|
+
public set_previous_point(point: i32): void;
|
|
784
|
+
public set_smart_cover_target(): void;
|
|
785
|
+
public set_smart_cover_target(game_object: game_object): void;
|
|
786
|
+
public set_smart_cover_target(vector: vector): void;
|
|
787
|
+
public set_smart_cover_target_default(value: boolean): void;
|
|
788
|
+
public set_smart_cover_target_fire(): void;
|
|
789
|
+
public set_smart_cover_target_lookout(): void;
|
|
790
|
+
public set_start_point(point: i32): void;
|
|
791
|
+
public sound_voice_prefix(): string;
|
|
792
|
+
/**
|
|
793
|
+
* @returns game object squad id
|
|
794
|
+
*/
|
|
795
|
+
public squad(): i32;
|
|
796
|
+
public switch_to_talk(): void;
|
|
797
|
+
public team(): i32;
|
|
798
|
+
public use_smart_covers_only(): boolean;
|
|
799
|
+
public use_smart_covers_only(value: boolean): void;
|
|
800
|
+
public weapon_addon_attach(object: game_object): void;
|
|
801
|
+
public weapon_addon_detach(addon: string): void;
|
|
802
|
+
public weapon_is_scope(): boolean;
|
|
803
|
+
public weapon_silencer_status(): i32;
|
|
804
|
+
public weapon_strapped(): boolean;
|
|
805
|
+
public weapon_unstrapped(): boolean;
|
|
806
|
+
public who_hit_name(): string;
|
|
807
|
+
public who_hit_section_name(): string;
|
|
808
|
+
|
|
809
|
+
public activate_slot(index: u32): void;
|
|
810
|
+
public actor_look_at_point(vector: vector): void;
|
|
811
|
+
public aim_bone_id(): string;
|
|
812
|
+
public aim_bone_id(value: string): void;
|
|
813
|
+
public aim_time(game_object: game_object): u32;
|
|
814
|
+
public aim_time(game_object: game_object, value: u32): void;
|
|
815
|
+
public allow_sprint(value: boolean): void;
|
|
816
|
+
public animation_count(): i32;
|
|
817
|
+
public best_danger(): danger_object | null;
|
|
818
|
+
public body_state(): void;
|
|
819
|
+
public bone_position(value: string): vector;
|
|
820
|
+
public buy_item_condition_factor(value: f32): void;
|
|
821
|
+
/**
|
|
822
|
+
* Change object squad/faction?
|
|
823
|
+
*/
|
|
824
|
+
public change_team(community_id: u8, squad_id: u8, group_id: u8): void;
|
|
825
|
+
public character_icon<T extends string>(): T;
|
|
826
|
+
public character_name<T extends string>(): T;
|
|
827
|
+
public character_rank(): i32;
|
|
828
|
+
public condition(): f32;
|
|
829
|
+
public cost(): u32;
|
|
830
|
+
public critically_wounded(): boolean;
|
|
831
|
+
public deadbody_closed(value: boolean): void;
|
|
832
|
+
public death_sound_enabled(): boolean;
|
|
833
|
+
public death_sound_enabled(value: boolean): void;
|
|
834
|
+
public direction(): vector;
|
|
835
|
+
public disable_anomaly(): void;
|
|
836
|
+
public disable_hit_marks(): boolean;
|
|
837
|
+
public disable_hit_marks(value: boolean): void;
|
|
838
|
+
public disable_inv_upgrade(): void;
|
|
839
|
+
public drop_item_and_teleport(game_object: game_object, vector: vector): void;
|
|
840
|
+
public eat(game_object: game_object): void;
|
|
841
|
+
public enable_inv_upgrade(): void;
|
|
842
|
+
/**
|
|
843
|
+
* Switch client level changed enabled state.
|
|
844
|
+
*
|
|
845
|
+
* @param is_enabled - whether level changer should be enabled
|
|
846
|
+
*/
|
|
847
|
+
public enable_level_changer(is_enabled: boolean): void;
|
|
848
|
+
public enable_memory_object(game_object: game_object, value: boolean): void;
|
|
849
|
+
public explode(value: u32): void;
|
|
850
|
+
public extrapolate_length(): f32;
|
|
851
|
+
public extrapolate_length(value: f32): void;
|
|
852
|
+
public fake_death_stand_up(): void;
|
|
853
|
+
public fov(): f32;
|
|
854
|
+
public get_ammo_total(): u32;
|
|
855
|
+
public get_ammo_type(): u8;
|
|
856
|
+
public get_artefact(): CArtefact;
|
|
857
|
+
public get_campfire(): CZoneCampfire;
|
|
858
|
+
public get_current_outfit(): game_object | null;
|
|
859
|
+
public get_current_point_index(): u32;
|
|
860
|
+
public get_force_anti_aim(): boolean;
|
|
861
|
+
public get_hanging_lamp(): hanging_lamp;
|
|
862
|
+
public get_holder_class(): holder;
|
|
863
|
+
public get_movement_speed(): vector;
|
|
864
|
+
/**
|
|
865
|
+
* @returns name of lua script controlling monster object
|
|
866
|
+
*/
|
|
867
|
+
public get_script_name(): string;
|
|
868
|
+
public get_visual_name<T extends string>(): T;
|
|
869
|
+
public has_info(value: string): boolean;
|
|
870
|
+
public hide_weapon(): void;
|
|
871
|
+
public idle_min_time(): f32;
|
|
872
|
+
public idle_min_time(value: f32): void;
|
|
873
|
+
public in_loophole_fov(value1: string, valu2: string, value3: vector): boolean;
|
|
874
|
+
public in_restrictions(): string;
|
|
875
|
+
public in_smart_cover(): boolean;
|
|
876
|
+
/**
|
|
877
|
+
* Available only in debug mode.
|
|
878
|
+
* Sets information for game object for debug.
|
|
879
|
+
*/
|
|
880
|
+
public info_add(text: string): void;
|
|
881
|
+
public inv_box_can_take(value: boolean): boolean;
|
|
882
|
+
public invulnerable(): boolean;
|
|
883
|
+
public invulnerable(value: boolean): void;
|
|
884
|
+
public is_body_turning(): boolean;
|
|
885
|
+
public is_level_changer_enabled(): boolean;
|
|
886
|
+
public is_there_items_to_pickup(): boolean;
|
|
887
|
+
public kill(game_object: game_object): void;
|
|
888
|
+
public location_on_path(value: f32, vector: vector): u32;
|
|
889
|
+
public lock_door_for_npc(): void;
|
|
890
|
+
public lookout_min_time(): f32;
|
|
891
|
+
public lookout_min_time(time: f32): void;
|
|
892
|
+
public make_item_active(game_object: game_object): void;
|
|
893
|
+
public marked_dropped(game_object: game_object): boolean;
|
|
894
|
+
public memory_sound_objects(): unknown;
|
|
895
|
+
public money(): u32;
|
|
896
|
+
public motivation_action_manager(): action_planner;
|
|
897
|
+
public movement_type(): number; // todo: unknown enum
|
|
898
|
+
public patrol(): string | null;
|
|
899
|
+
public patrol_path_make_inactual(): void;
|
|
900
|
+
public play_cycle(value1: string, value2: boolean): void;
|
|
901
|
+
public play_cycle(value: string): void;
|
|
902
|
+
public play_sound(value1: u32, value2?: u32, value3?: u32, value4?: u32, value5?: u32, value6?: u32): void;
|
|
903
|
+
public register_door_for_npc(): void;
|
|
904
|
+
public remove_home(): void;
|
|
905
|
+
public remove_restrictions(value1: string, value2: string): void;
|
|
906
|
+
public remove_sound(value: u32): void;
|
|
907
|
+
public restore_default_start_dialog(): void;
|
|
908
|
+
public restore_max_ignore_monster_distance(): void;
|
|
909
|
+
public section<T extends string = string>(): T;
|
|
910
|
+
public see(game_object: game_object): boolean;
|
|
911
|
+
public see(value: string): boolean;
|
|
912
|
+
public sell_condition(ini_file: ini_file, value: string): void;
|
|
913
|
+
public sell_condition(value1: f32, value2: f32): void;
|
|
914
|
+
public set__force(vector: vector, value1: number, value2: number): void;
|
|
915
|
+
public set_actor_relation_flags(value: flags32): void;
|
|
916
|
+
public set_alien_control(value: boolean): void;
|
|
917
|
+
public set_body_state(state: TXR_MonsterBodyState): void;
|
|
918
|
+
public set_capture_anim(game_object: game_object, value1: string, vector: vector, value2: f32): void;
|
|
919
|
+
public set_character_community(value1: string, value2: u32, value3: i32): void;
|
|
920
|
+
public set_character_rank(value: i32): void;
|
|
921
|
+
public set_collision_off(value: boolean): void;
|
|
922
|
+
public set_default_panic_threshold(): void;
|
|
923
|
+
public set_dest_game_vertex_id(value: u16): void;
|
|
924
|
+
public set_dest_level_vertex_id(vertex_id: u32): void;
|
|
925
|
+
public set_detail_path_type(EDetailPathType: unknown /** enum DetailPathManager::EDetailPathType */): void;
|
|
926
|
+
public set_invisible(is_invisible: boolean): void;
|
|
927
|
+
public set_movement_selection_type(type: unknown /** enum ESelectionType */): void;
|
|
928
|
+
public set_patrol_path(value1: string, EPatrolStartType: number, EPatrolRouteType: number, value2: boolean): void;
|
|
929
|
+
public set_smart_cover_target_idle(): void;
|
|
930
|
+
public set_sympathy(value: f32): void;
|
|
931
|
+
public set_trader_sound(value1: string, value2: string): void;
|
|
932
|
+
public sight_params(): CSightParams;
|
|
933
|
+
public skip_transfer_enemy(value: boolean): void;
|
|
934
|
+
public sniper_update_rate(): boolean;
|
|
935
|
+
public sniper_update_rate(value: boolean): void;
|
|
936
|
+
public spawn_ini(): ini_file;
|
|
937
|
+
public special_danger_move(): boolean;
|
|
938
|
+
public special_danger_move(value: boolean): void;
|
|
939
|
+
public stop_particles(name: string, bone: string): void;
|
|
940
|
+
public switch_to_trade(): void;
|
|
941
|
+
public sympathy(): f32;
|
|
942
|
+
public take_items_enabled(): boolean;
|
|
943
|
+
public take_items_enabled(value: boolean): void;
|
|
944
|
+
public torch_enabled(): boolean;
|
|
945
|
+
public unload_magazine(): void;
|
|
946
|
+
public unlock_door_for_npc(): void;
|
|
947
|
+
public visibility_threshold(): f32;
|
|
948
|
+
public weapon_is_grenadelauncher(): boolean;
|
|
949
|
+
public set_sight(type: TXR_SightType, torso_look: boolean, path: boolean): void;
|
|
950
|
+
public set_sight(type: TXR_SightType, vector: vector | null, lookOverDelay: u32): void;
|
|
951
|
+
public set_sight(type: TXR_SightType, vector: vector, torso_look: boolean, fire_object: boolean): void;
|
|
952
|
+
public set_sight(type: TXR_SightType, vector: vector, torso_look: boolean): void;
|
|
953
|
+
public set_sight(type: TXR_SightType, vector: vector): void;
|
|
954
|
+
public set_sight(game_object: game_object, torso_look?: boolean, fire_object?: boolean, no_pitch?: boolean): void;
|
|
955
|
+
public set_task_state(state: TXR_TaskState, value: string): void;
|
|
956
|
+
public set_visual_memory_enabled(enabled: boolean): void;
|
|
957
|
+
public show_condition(ini_file: unknown, value: string): void;
|
|
958
|
+
public sound_prefix(): string;
|
|
959
|
+
public sound_prefix(value: string): void;
|
|
960
|
+
public wounded(): boolean;
|
|
961
|
+
public wounded(wounded: boolean): void;
|
|
962
|
+
public add_sound(value1: string, value2: u32, type: unknown, value3: u32, value4: u32, value5: u32): u32;
|
|
963
|
+
public add_sound(
|
|
964
|
+
value1: string,
|
|
965
|
+
value2: u32,
|
|
966
|
+
type: unknown,
|
|
967
|
+
value3: u32,
|
|
968
|
+
value4: u32,
|
|
969
|
+
value5: u32,
|
|
970
|
+
value6: string
|
|
971
|
+
): u32;
|
|
972
|
+
public active_sound_count(): i32;
|
|
973
|
+
public active_sound_count(value: boolean): void;
|
|
974
|
+
public allow_break_talk_dialog(value: boolean): void;
|
|
975
|
+
public apply_loophole_direction_distance(): f32;
|
|
976
|
+
public apply_loophole_direction_distance(value: f32): void;
|
|
977
|
+
public attachable_item_enabled(): boolean;
|
|
978
|
+
public burer_get_force_gravi_attack(): boolean;
|
|
979
|
+
public burer_get_force_anti_aim(): boolean;
|
|
980
|
+
public buy_condition(ini_file: ini_file, value: string): void;
|
|
981
|
+
public buy_condition(value1: f32, value2: f32): void;
|
|
982
|
+
public change_character_reputation(value: i32): void;
|
|
983
|
+
public change_goodwill(delta_goodwill: i32, to_object: game_object): void;
|
|
984
|
+
public character_reputation(): i32;
|
|
985
|
+
public community_goodwill(from_community: string): i32;
|
|
986
|
+
public deadbody_can_take(value: boolean): void;
|
|
987
|
+
public deadbody_can_take_status(): boolean;
|
|
988
|
+
public detail_path_type(): unknown;
|
|
989
|
+
public disable_show_hide_sounds(value: boolean): void;
|
|
990
|
+
public enable_anomaly(): void;
|
|
991
|
+
public enable_attachable_item(value: boolean): void;
|
|
992
|
+
public enable_talk(): void;
|
|
993
|
+
public enable_trade(): void;
|
|
994
|
+
public enable_vision(value: boolean): void;
|
|
995
|
+
public fake_death_fall_down(): boolean;
|
|
996
|
+
public force_set_goodwill(goodwill: i32, to_object: game_object): void;
|
|
997
|
+
/**
|
|
998
|
+
* For bloodsuckers specifically set current visibility state.
|
|
999
|
+
*/
|
|
1000
|
+
public force_visibility_state(state: TXR_bloodsucker_visibility_state): void;
|
|
1001
|
+
|
|
1002
|
+
/**
|
|
1003
|
+
* Return formula: `personal_goodwill + reputation_goodwill + rank_goodwill +
|
|
1004
|
+
* community_goodwill + community_to_community`
|
|
1005
|
+
*
|
|
1006
|
+
* @param target - target client object
|
|
1007
|
+
* @returns goodwill level from object to target
|
|
1008
|
+
*/
|
|
1009
|
+
public general_goodwill(target: game_object): i32;
|
|
1010
|
+
public get_actor_relation_flags(): flags32;
|
|
1011
|
+
public get_ammo_in_magazine(): u32;
|
|
1012
|
+
public get_anomaly_power(): unknown;
|
|
1013
|
+
public get_car(): CCar;
|
|
1014
|
+
public get_corpse(): game_object | null;
|
|
1015
|
+
public get_current_holder(): holder;
|
|
1016
|
+
public get_enemy(): game_object | null;
|
|
1017
|
+
public get_enemy_strength(): i32;
|
|
1018
|
+
public get_physics_shell(): physics_shell | null;
|
|
1019
|
+
public get_start_dialog(): void;
|
|
1020
|
+
public get_task(task_id: string, only_in_process: boolean): CGameTask | null;
|
|
1021
|
+
public get_task_state(value: string): unknown;
|
|
1022
|
+
public give_info_portion(value: string): boolean;
|
|
1023
|
+
public give_money(value: i32): void;
|
|
1024
|
+
|
|
1025
|
+
/**
|
|
1026
|
+
* Show talk dialog message with icon.
|
|
1027
|
+
*
|
|
1028
|
+
* @param title - title of the message
|
|
1029
|
+
* @param text - text of the message
|
|
1030
|
+
* @param icon_texture_name - icon to display in message image
|
|
1031
|
+
* @param selector - path in form XML to message template
|
|
1032
|
+
*/
|
|
1033
|
+
public give_talk_message2(title: string, text: string, icon_texture_name: string, selector: string): void;
|
|
1034
|
+
|
|
1035
|
+
/**
|
|
1036
|
+
* Give game task for an object, usually it is actor object.
|
|
1037
|
+
*
|
|
1038
|
+
* @param task
|
|
1039
|
+
* @param time_to_complete
|
|
1040
|
+
* @param check_existing
|
|
1041
|
+
* @param timer_ttl
|
|
1042
|
+
*/
|
|
1043
|
+
public give_task(task: CGameTask, time_to_complete: u32, check_existing: boolean, timer_ttl: u32): void;
|
|
1044
|
+
/**
|
|
1045
|
+
* Returns level of goodwill stored for an object.
|
|
1046
|
+
* No strict formulas, just get actual value.
|
|
1047
|
+
*
|
|
1048
|
+
* @param target - target client object
|
|
1049
|
+
* @returns goodwill level to target object
|
|
1050
|
+
*/
|
|
1051
|
+
public goodwill(target: game_object): i32;
|
|
1052
|
+
public group_throw_time_interval(): u32;
|
|
1053
|
+
public group_throw_time_interval(value: u32): void;
|
|
1054
|
+
public head_orientation(): vector;
|
|
1055
|
+
public ignore_monster_threshold(): f32;
|
|
1056
|
+
public ignore_monster_threshold(value: f32): void;
|
|
1057
|
+
public in_current_loophole_range(vector: vector): boolean;
|
|
1058
|
+
/**
|
|
1059
|
+
* Reset debugging information about object.
|
|
1060
|
+
* Available only for debug builds.
|
|
1061
|
+
*/
|
|
1062
|
+
public info_clear(): void;
|
|
1063
|
+
public inside(vector: vector): boolean;
|
|
1064
|
+
public inside(vector: vector, value: number /* ? */): boolean;
|
|
1065
|
+
public inv_box_can_take_status(): boolean;
|
|
1066
|
+
public inv_box_closed(value1: boolean, value2: string): boolean;
|
|
1067
|
+
public is_active_task(task: CGameTask): boolean;
|
|
1068
|
+
public is_door_locked_for_npc(): boolean;
|
|
1069
|
+
public is_inv_box_empty(): boolean;
|
|
1070
|
+
public is_inv_upgrade_enabled(): boolean;
|
|
1071
|
+
public is_talking(): boolean;
|
|
1072
|
+
public is_trade_enabled(): boolean;
|
|
1073
|
+
public item_in_slot(slot: u32): game_object | null;
|
|
1074
|
+
public item_on_belt(slot: u32): game_object | null;
|
|
1075
|
+
public jump(vector: vector, value: f32): void;
|
|
1076
|
+
public make_object_visible_somewhen(game_object: game_object): void;
|
|
1077
|
+
public mark_item_dropped(game_object: game_object): void;
|
|
1078
|
+
public mass(): f32;
|
|
1079
|
+
public max_health(): f32;
|
|
1080
|
+
public night_vision_enabled(): boolean;
|
|
1081
|
+
public on_door_is_closed(): void;
|
|
1082
|
+
public on_door_is_open(): void;
|
|
1083
|
+
public out_restrictions(): string;
|
|
1084
|
+
public path_type(): unknown;
|
|
1085
|
+
public poltergeist_get_actor_ignore(): boolean;
|
|
1086
|
+
public profile_name(): string;
|
|
1087
|
+
public range(): f32;
|
|
1088
|
+
public rank(): i32;
|
|
1089
|
+
public remove_all_restrictions(): void;
|
|
1090
|
+
public restore_ignore_monster_threshold(): void;
|
|
1091
|
+
public restore_weapon(): void;
|
|
1092
|
+
public run_talk_dialog(game_object: game_object, value: boolean): void;
|
|
1093
|
+
public set_active_task(task: CGameTask): void;
|
|
1094
|
+
public set_actor_position(vector: vector): void;
|
|
1095
|
+
public set_anomaly_power(value: f32): void;
|
|
1096
|
+
public set_custom_panic_threshold(value: f32): void;
|
|
1097
|
+
public set_dest_loophole(): void;
|
|
1098
|
+
public set_dest_loophole(value: string): void;
|
|
1099
|
+
public set_goodwill(value: i32, game_object: game_object): void;
|
|
1100
|
+
public set_home(
|
|
1101
|
+
name: string | null,
|
|
1102
|
+
min_radius: f32,
|
|
1103
|
+
max_radius?: f32,
|
|
1104
|
+
is_agressive?: boolean,
|
|
1105
|
+
mid_radius?: f32
|
|
1106
|
+
): void;
|
|
1107
|
+
public set_home(
|
|
1108
|
+
lvid: u32 | null,
|
|
1109
|
+
min_radius: f32,
|
|
1110
|
+
max_radius?: f32,
|
|
1111
|
+
is_agressive?: boolean,
|
|
1112
|
+
mid_radius?: f32
|
|
1113
|
+
): void;
|
|
1114
|
+
/**
|
|
1115
|
+
* Set level changer invitation hint text.
|
|
1116
|
+
*
|
|
1117
|
+
* @param hint - text to show when trying to change level
|
|
1118
|
+
*/
|
|
1119
|
+
public set_level_changer_invitation(hint: string): void;
|
|
1120
|
+
public set_nonscript_usable(is_usable: boolean): void;
|
|
1121
|
+
public set_queue_size(value: u32): void;
|
|
1122
|
+
public set_relation(ERelationType: number, game_object: game_object): void;
|
|
1123
|
+
public set_smart_cover_target_fire_no_lookout(): unknown;
|
|
1124
|
+
public set_sound_mask(value: u32): void;
|
|
1125
|
+
public set_start_dialog(value: string): void;
|
|
1126
|
+
public set_tip_text(text: string): void;
|
|
1127
|
+
public set_tip_text_default(): void;
|
|
1128
|
+
public set_trader_global_anim(value: string): void;
|
|
1129
|
+
public set_vis_state(value: f32): void;
|
|
1130
|
+
public sniper_fire_mode(): boolean;
|
|
1131
|
+
public sniper_fire_mode(value: boolean): void;
|
|
1132
|
+
public start_particles(value1: string, value2: string): void;
|
|
1133
|
+
public stop_talk(): void;
|
|
1134
|
+
public switch_to_upgrade(): void;
|
|
1135
|
+
public has_upgrade(upgrade_section: string): boolean;
|
|
1136
|
+
public install_upgrade(upgrade_section: string): boolean;
|
|
1137
|
+
public iterate_installed_upgrades(callback: (upgrade_section: string, object: game_object) => void): void;
|
|
1138
|
+
public target_body_state(): TXR_move;
|
|
1139
|
+
public target_movement_type(): number; /* EMovementType */
|
|
1140
|
+
public transfer_item(item: game_object, to: game_object): void;
|
|
1141
|
+
public transfer_money(value: i32, from: game_object): void;
|
|
1142
|
+
public unregister_in_combat(): void;
|
|
1143
|
+
public vertex_in_direction(value1: u32, vector: vector, value2: f32): u32;
|
|
1144
|
+
public vision_enabled(): boolean;
|
|
1145
|
+
public weapon_grenadelauncher_status(): i32;
|
|
1146
|
+
public weapon_is_silencer(): boolean;
|
|
1147
|
+
public weapon_scope_status(): i32;
|
|
1148
|
+
public weight(): f32;
|
|
1149
|
+
|
|
1150
|
+
/**
|
|
1151
|
+
* Display in-game UI notification.
|
|
1152
|
+
*
|
|
1153
|
+
* @param title - notification title
|
|
1154
|
+
* @param text - notification text
|
|
1155
|
+
* @param icon_texture - notification icon texture
|
|
1156
|
+
* @param delay - delay before show notification
|
|
1157
|
+
* @param show_time - time to show notification before hiding it
|
|
1158
|
+
* @param type - type of the notification (eNews = 0, eTalk = 1)
|
|
1159
|
+
*/
|
|
1160
|
+
public give_game_news(
|
|
1161
|
+
title: string,
|
|
1162
|
+
text: string,
|
|
1163
|
+
icon_texture: string,
|
|
1164
|
+
delay: i32,
|
|
1165
|
+
show_time: i32,
|
|
1166
|
+
type?: Maybe<i32>
|
|
1167
|
+
): void;
|
|
1168
|
+
public accessible(vector: vector | u32): boolean;
|
|
1169
|
+
public accuracy(): f32;
|
|
1170
|
+
public attachable_item_load_attach(value: string): void;
|
|
1171
|
+
public best_cover(vector1: vector, vector2: vector, value3: f32, value4: f32, value5: f32): cover_point;
|
|
1172
|
+
public best_enemy(): game_object | null;
|
|
1173
|
+
public center(): vector;
|
|
1174
|
+
public deadbody_closed_status(): boolean;
|
|
1175
|
+
public death_time(): u32;
|
|
1176
|
+
public enable_torch(value: boolean): void;
|
|
1177
|
+
public force_stand_sleep_animation(value: u32): void;
|
|
1178
|
+
public get_visibility_state(): i32;
|
|
1179
|
+
public in_loophole_range(value1: string, value2: string, vector: vector): boolean;
|
|
1180
|
+
public poltergeist_set_actor_ignore(value: boolean): void;
|
|
1181
|
+
public set_desired_position(): void;
|
|
1182
|
+
public set_desired_position(vector: vector): void;
|
|
1183
|
+
public set_force_anti_aim(value: boolean): void;
|
|
1184
|
+
public set_range(value: f32): void;
|
|
1185
|
+
public suitable_smart_cover(game_object: game_object): boolean;
|
|
1186
|
+
public add_combat_sound(
|
|
1187
|
+
value1: string,
|
|
1188
|
+
value2: number,
|
|
1189
|
+
type: i32 /** enum ESoundTypes */,
|
|
1190
|
+
value3: u32,
|
|
1191
|
+
value4: u32,
|
|
1192
|
+
value5: u32,
|
|
1193
|
+
value6: string
|
|
1194
|
+
): u32;
|
|
1195
|
+
public berserk(): void;
|
|
1196
|
+
/**
|
|
1197
|
+
* Add action for game object entity.
|
|
1198
|
+
* Depending on priority pushes it to back or front of actions list.
|
|
1199
|
+
*
|
|
1200
|
+
* @param entity_action - action to perform
|
|
1201
|
+
* @param is_high_priority - whether it is high priority action
|
|
1202
|
+
*/
|
|
1203
|
+
public command(entity_action: entity_action, is_high_priority: boolean): void;
|
|
1204
|
+
public hit(hit: hit): void;
|
|
1205
|
+
public inactualize_patrol_path(): void;
|
|
1206
|
+
public iterate_inventory(cb: (this: void, owner: game_object, item: game_object) => void, object: game_object): void;
|
|
1207
|
+
public movement_enabled(): boolean;
|
|
1208
|
+
public movement_enabled(value: boolean): void;
|
|
1209
|
+
public set_condition(condition: f32): void;
|
|
1210
|
+
/**
|
|
1211
|
+
* @returns vertex_id of accessible position
|
|
1212
|
+
*/
|
|
1213
|
+
public accessible_nearest(vector1: vector, vector2: vector): u32;
|
|
1214
|
+
public action_by_index(value: u32): entity_action | null;
|
|
1215
|
+
/**
|
|
1216
|
+
* @returns whether game object is alive
|
|
1217
|
+
*/
|
|
1218
|
+
public alive(): boolean;
|
|
1219
|
+
public base_in_restrictions(): string;
|
|
1220
|
+
public can_script_capture(): boolean;
|
|
1221
|
+
/**
|
|
1222
|
+
* @returns object community like `monolith`, `stalker` or `zombied`
|
|
1223
|
+
*/
|
|
1224
|
+
public character_community<T extends string>(): T;
|
|
1225
|
+
public external_sound_stop(): void;
|
|
1226
|
+
public find_best_cover(vector: vector): cover_point;
|
|
1227
|
+
public game_vertex_id(): u32;
|
|
1228
|
+
public get_helicopter(): CHelicopter;
|
|
1229
|
+
public get_sound_info(): SoundInfo;
|
|
1230
|
+
public group(): i32;
|
|
1231
|
+
public inv_box_closed_status(): boolean;
|
|
1232
|
+
public level_vertex_id(): u32;
|
|
1233
|
+
public memory_position(game_object: game_object): vector;
|
|
1234
|
+
public movement_target_reached(): boolean;
|
|
1235
|
+
public name(): string;
|
|
1236
|
+
public parent(): game_object;
|
|
1237
|
+
public position(): vector;
|
|
1238
|
+
public register_in_combat(): void;
|
|
1239
|
+
public safe_cover(vector: vector, value1: f32, value2: f32): cover_point;
|
|
1240
|
+
public script(script_control: boolean, script_name: string): void;
|
|
1241
|
+
public set_desired_direction(): void;
|
|
1242
|
+
public set_desired_direction(vector: vector): void;
|
|
1243
|
+
public set_manual_invisibility(value: boolean): void;
|
|
1244
|
+
public set_movement_type(EMovementType: number /** MonsterSpace::EMovementType */): void;
|
|
1245
|
+
public set_npc_position(vector: vector): void;
|
|
1246
|
+
public set_sound_threshold(value: f32): void;
|
|
1247
|
+
public set_trader_head_anim(value: string): void;
|
|
1248
|
+
public set_visual_name(name: string): void;
|
|
1249
|
+
public target_mental_state(): TXR_animation;
|
|
1250
|
+
public unregister_door_for_npc(): void;
|
|
1251
|
+
public ammo_get_count(): u16;
|
|
1252
|
+
public ammo_set_count(count: u16): void;
|
|
1253
|
+
public ammo_box_size(): u16;
|
|
1254
|
+
}
|
|
1255
|
+
}
|