xray16 1.0.5 → 1.0.8

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.
Files changed (65) hide show
  1. package/README.md +4 -1
  2. package/package.json +4 -3
  3. package/types/index.d.ts +46 -22
  4. package/types/{xr_object → xr_ai}/xr_action.d.ts +163 -135
  5. package/types/xr_ai/xr_alife.d.ts +552 -0
  6. package/types/xr_ai/xr_enemy_evaluation.d.ts +41 -0
  7. package/types/xr_ai/xr_goap.d.ts +668 -0
  8. package/types/xr_ai/xr_graph.d.ts +47 -0
  9. package/types/xr_ai/xr_memory.d.ts +148 -0
  10. package/types/xr_lib/xr_animation.d.ts +81 -0
  11. package/types/xr_lib/xr_bitwise.d.ts +21 -0
  12. package/types/xr_lib/xr_color.d.ts +40 -0
  13. package/types/xr_lib/xr_debug.d.ts +100 -0
  14. package/types/{xr_object → xr_lib}/xr_dialog.d.ts +7 -1
  15. package/types/xr_lib/xr_flags.d.ts +148 -0
  16. package/types/xr_lib/xr_fs.d.ts +37 -229
  17. package/types/xr_lib/xr_game.d.ts +159 -0
  18. package/types/xr_lib/xr_hit.d.ts +41 -0
  19. package/types/xr_lib/xr_ini.d.ts +176 -0
  20. package/types/xr_lib/xr_level.d.ts +225 -0
  21. package/types/xr_lib/xr_luabind.d.ts +59 -0
  22. package/types/{xr_map → xr_lib}/xr_map.d.ts +19 -0
  23. package/types/xr_lib/xr_math.d.ts +65 -0
  24. package/types/{xr_online → xr_lib}/xr_multiplayer.d.ts +52 -0
  25. package/types/xr_lib/xr_properties.d.ts +166 -0
  26. package/types/xr_lib/xr_relation.d.ts +84 -0
  27. package/types/xr_lib/xr_render.d.ts +70 -0
  28. package/types/xr_lib/xr_save.d.ts +223 -0
  29. package/types/{xr_sound → xr_lib}/xr_sound.d.ts +10 -12
  30. package/types/xr_lib/xr_stats.ts +20 -0
  31. package/types/{xr_object/xr_quest.d.ts → xr_lib/xr_task.d.ts} +54 -2
  32. package/types/xr_lib/xr_time.d.ts +61 -0
  33. package/types/{xr_type → xr_lib}/xr_type.d.ts +13 -13
  34. package/types/xr_object/client/xr_client_object.d.ts +76 -0
  35. package/types/xr_object/{xr_level.d.ts → client/xr_level.d.ts} +69 -0
  36. package/types/xr_object/{xr_physic.d.ts → client/xr_physic.d.ts} +58 -0
  37. package/types/xr_object/client/xr_zone.d.ts +40 -0
  38. package/types/xr_object/script/xr_script_interface.d.ts +429 -0
  39. package/types/xr_object/{xr_client_object.d.ts → script/xr_script_object.d.ts} +449 -522
  40. package/types/xr_object/script/xr_script_trade.d.ts +26 -0
  41. package/types/xr_object/{xr_server_object.d.ts → server/xr_server_object.d.ts} +152 -73
  42. package/types/xr_ui/xr_ui_asset.d.ts +123 -0
  43. package/types/xr_ui/xr_ui_core.d.ts +33 -123
  44. package/types/xr_ui/xr_ui_event.d.ts +382 -0
  45. package/types/xr_ui/xr_ui_interface.d.ts +213 -0
  46. package/types/xr_ui/xr_ui_menu.d.ts +142 -0
  47. package/types/xr_constant.d.ts +0 -976
  48. package/types/xr_core.d.ts +0 -347
  49. package/types/xr_global.d.ts +0 -648
  50. package/types/xr_lib/xr_utils.d.ts +0 -407
  51. package/types/xr_luabind.d.ts +0 -34
  52. package/types/xr_object/xr_alife.d.ts +0 -206
  53. package/types/xr_type/xr_enums.d.ts +0 -17
  54. package/types/xr_ui/README.md +0 -277
  55. package/types/xr_ui/demo/CServerList.png +0 -0
  56. package/types/xr_ui/demo/CUI3tButton.png +0 -0
  57. package/types/xr_ui/demo/CUICheckButton.png +0 -0
  58. package/types/xr_ui/demo/CUIComboBox.png +0 -0
  59. package/types/xr_ui/demo/CUICustomEdit.png +0 -0
  60. package/types/xr_ui/demo/CUIStatic.png +0 -0
  61. package/types/xr_ui/demo/CUITrackBar.png +0 -0
  62. /package/types/xr_object/{xr_anomaly.d.ts → client/xr_anomaly.d.ts} +0 -0
  63. /package/types/xr_object/{xr_artefact.d.ts → client/xr_artefact.d.ts} +0 -0
  64. /package/types/xr_object/{xr_creature.d.ts → client/xr_creature.d.ts} +0 -0
  65. /package/types/xr_object/{xr_item.d.ts → client/xr_item.d.ts} +0 -0
@@ -0,0 +1,76 @@
1
+ declare module "xray16" {
2
+ /**
3
+ * @source C++ class DLL_Pure
4
+ * @customConstructor DLL_Pure
5
+ * @group xr_core
6
+ */
7
+ export class DLL_Pure extends EngineBinding {
8
+ protected constructor();
9
+ }
10
+
11
+ /**
12
+ * @source C++ class IRender_Visual
13
+ * @group xr_client_object
14
+ */
15
+ export interface IXR_IRender_Visual {
16
+ dcast_PKinematicsAnimated(): IKinematicsAnimated;
17
+ }
18
+
19
+ /**
20
+ * @source C++ class CGameObject : DLL_Pure, ISheduled, ICollidable, IRenderable
21
+ * @customConstructor CGameObject
22
+ * @group xr_client_object
23
+ */
24
+ export class CGameObject extends DLL_Pure {
25
+ public Visual(): IXR_IRender_Visual;
26
+
27
+ public getEnabled(): boolean;
28
+
29
+ public _construct(): DLL_Pure;
30
+
31
+ public net_Import(net_packet: net_packet): void;
32
+
33
+ public getVisible(): boolean;
34
+
35
+ public net_Export(net_packet: net_packet): void;
36
+
37
+ public net_Spawn(cse_abstract: cse_abstract): boolean;
38
+
39
+ public use(object: CGameObject): boolean;
40
+ }
41
+
42
+ /**
43
+ * Class to link client side object with script object entity.
44
+ *
45
+ * @source C++ class object_binder
46
+ * @customConstructor object_binder
47
+ * @group xr_client_object
48
+ */
49
+ export class object_binder<T = game_object> extends EngineBinding {
50
+ public readonly object: T;
51
+
52
+ public constructor(object: T);
53
+
54
+ public save(packet: net_packet): void;
55
+
56
+ public load(reader: reader): void;
57
+
58
+ public update(delta: u32): void;
59
+
60
+ public reload(section: string): void;
61
+
62
+ public reinit(): void;
63
+
64
+ public net_export(net_packet: net_packet): void;
65
+
66
+ public net_save_relevant(): boolean;
67
+
68
+ public net_destroy(): void;
69
+
70
+ public net_Relcase(object: T): void;
71
+
72
+ public net_spawn(object: cse_alife_object): boolean;
73
+
74
+ public net_import(net_packet: net_packet): void;
75
+ }
76
+ }
@@ -8,7 +8,9 @@ declare module "xray16" {
8
8
  public constructor();
9
9
 
10
10
  public is_on(): boolean;
11
+
11
12
  public turn_on(): void;
13
+
12
14
  public turn_off(): void;
13
15
  }
14
16
 
@@ -19,13 +21,21 @@ declare module "xray16" {
19
21
  */
20
22
  export class CPhysicObject extends CGameObject {
21
23
  public set_door_ignore_dynamics(): void;
24
+
22
25
  public play_bones_sound(): void;
26
+
23
27
  public run_anim_back(): void;
28
+
24
29
  public unset_door_ignore_dynamics(): void;
30
+
25
31
  public run_anim_forward(): void;
32
+
26
33
  public stop_anim(): boolean;
34
+
27
35
  public anim_time_get(): f32;
36
+
28
37
  public anim_time_set(value: f32): void;
38
+
29
39
  public stop_bones_sound(): void;
30
40
  }
31
41
 
@@ -38,6 +48,7 @@ declare module "xray16" {
38
48
  public constructor();
39
49
 
40
50
  public turn_on(): void;
51
+
41
52
  public turn_off(): void;
42
53
  }
43
54
 
@@ -57,32 +68,57 @@ declare module "xray16" {
57
68
  public constructor();
58
69
 
59
70
  public CanHit(): boolean;
71
+
60
72
  public CarExplode(): void;
73
+
61
74
  public ChangefFuel(fule: f32): void;
75
+
62
76
  public ChangefHealth(value: f32): void;
77
+
63
78
  public CurrentVel(): vector;
79
+
64
80
  public ExplodeTime(): u32;
81
+
65
82
  public FireDirDiff(): f32;
83
+
66
84
  public GetfFuel(): f32;
85
+
67
86
  public GetfFuelConsumption(): f32;
87
+
68
88
  public GetfFuelTank(): f32;
89
+
69
90
  public GetfHealth(): f32;
91
+
70
92
  public HasWeapon(): boolean;
93
+
71
94
  public IsActiveEngine(): boolean;
95
+
72
96
  public IsObjectVisible(game_object: game_object): boolean;
97
+
73
98
  public PlayDamageParticles(): void;
99
+
74
100
  public SetExplodeTime(time: u32): void;
101
+
75
102
  public SetfFuel(fuel: f32): void;
103
+
76
104
  public SetfFuelConsumption(consumption: f32): void;
105
+
77
106
  public SetfFuelTank(fuel: f32): void;
107
+
78
108
  public SetfHealth(health: f32): void;
109
+
79
110
  public StartEngine(): void;
111
+
80
112
  public StopDamageParticles(): void;
113
+
81
114
  public StopEngine(): void;
82
115
 
83
116
  public engaged(): boolean;
117
+
84
118
  public Action(value1: u16, value2: u32): void;
119
+
85
120
  public SetParam(value: i32, vector: vector): void;
121
+
86
122
  public SetParam(value: TXR_CCar_weapon_param, vector: vector): void;
87
123
  }
88
124
 
@@ -127,40 +163,73 @@ declare module "xray16" {
127
163
  public constructor();
128
164
 
129
165
  public isVisible(game_object: game_object): boolean;
166
+
130
167
  public GetSafeAltitude(): f32;
168
+
131
169
  public GetRealAltitude(): f32;
170
+
132
171
  public GetCurrVelocity(): f32;
172
+
133
173
  public GetSpeedInDestPoint(value: f32): f32;
174
+
134
175
  public GetOnPointRangeDist(): f32;
176
+
135
177
  public GetMaxVelocity(): f32;
178
+
136
179
  public GetfHealth(): f32;
180
+
137
181
  public GetMovementState(): i32; /* enum ? */
182
+
138
183
  public GetBodyState(): i32; /* enum ? */
184
+
139
185
  public GetCurrVelocityVec(): vector;
186
+
140
187
  public GetState(): i32;
188
+
141
189
  public GetDistanceToDestPosition(): f32;
190
+
142
191
  public GetHuntState(): i32; /* enum ? */
192
+
143
193
  public SetSpeedInDestPoint(value: f32): unknown;
194
+
144
195
  public SetLinearAcc(value1: f32, value2: f32): void;
196
+
145
197
  public SetfHealth(health: f32): f32;
198
+
146
199
  public SetMaxVelocity(value: f32): void;
200
+
147
201
  public SetEnemy(game_object: game_object | null): void;
202
+
148
203
  public SetEnemy(vector: vector): void;
204
+
149
205
  public SetFireTrailLength(value: f32): void;
206
+
150
207
  public SetBarrelDirTolerance(value: f32): void;
208
+
151
209
  public SetDestPosition(vector: vector): void;
210
+
152
211
  public SetOnPointRangeDist(value: f32): void;
153
212
 
154
213
  public LookAtPoint(vector: vector, value: boolean): void;
214
+
155
215
  public GoPatrolByPatrolPath(value1: string, value2: i32): void;
216
+
156
217
  public Explode(): void;
218
+
157
219
  public TurnLighting(value: boolean): void;
220
+
158
221
  public UseFireTrail(): boolean;
222
+
159
223
  public UseFireTrail(value: boolean): void;
224
+
160
225
  public GoPatrolByRoundPath(vector: vector, value1: f32, value2: boolean): void;
226
+
161
227
  public Die(): void;
228
+
162
229
  public StartFlame(): void;
230
+
163
231
  public TurnEngineSound(enabled: boolean): void;
232
+
164
233
  public ClearEnemy(): void;
165
234
  }
166
235
  }
@@ -6,15 +6,25 @@ declare module "xray16" {
6
6
  */
7
7
  export class physics_element {
8
8
  public apply_force(a: f32, b: f32, c: f32): void;
9
+
9
10
  public fix(): void;
11
+
10
12
  public get_angular_vel(vector: vector): void;
13
+
11
14
  public get_density(): f32;
15
+
12
16
  public get_linear_vel(vector: vector): void;
17
+
13
18
  public get_mass(): f32;
19
+
14
20
  public get_volume(): f32;
21
+
15
22
  public global_transform(): matrix;
23
+
16
24
  public is_breakable(): boolean;
25
+
17
26
  public is_fixed(): boolean;
27
+
18
28
  public release_fixed(): void;
19
29
  }
20
30
 
@@ -27,19 +37,33 @@ declare module "xray16" {
27
37
  public constructor(value: string);
28
38
 
29
39
  public pause_path(value: boolean): void;
40
+
30
41
  public play_at_pos(vector: vector): void;
42
+
31
43
  public move_to(vector1: vector, vector2: vector): void;
44
+
32
45
  public looped(): boolean;
46
+
33
47
  public load_path(path: string): void;
48
+
34
49
  public start_path(value: boolean): void;
50
+
35
51
  public stop(): void;
52
+
36
53
  public stop_path(): void;
54
+
37
55
  public stop_deffered(): void;
56
+
38
57
  public play(): void;
58
+
39
59
  public playing(): boolean;
60
+
40
61
  public last_position(): vector;
62
+
41
63
  public set_direction(direction: vector): void;
64
+
42
65
  public set_orientation(a: f32, b: f32, c: f32): void;
66
+
43
67
  public stop_deferred(): void;
44
68
  }
45
69
 
@@ -50,25 +74,43 @@ declare module "xray16" {
50
74
  */
51
75
  export class physics_joint {
52
76
  public get_anchor(vector: vector): void;
77
+
53
78
  public get_axes_number(): u16;
79
+
54
80
  public get_axis_angle(value: i32): f32;
81
+
55
82
  public get_axis_dir(value: i32, vector: vector): void;
83
+
56
84
  public get_bone_id(): u16;
85
+
57
86
  public get_first_element(): physics_element;
87
+
58
88
  public get_limits(value1: f32, value2: f32, value3: i32): LuaMultiReturn<[number, number]>;
89
+
59
90
  public get_max_force_and_velocity(value1: f32, value2: f32, value3: i32): void;
91
+
60
92
  public get_stcond_element(): physics_element;
93
+
61
94
  public is_breakable(): boolean;
62
95
 
63
96
  public set_anchor_global(value1: f32, value2: f32, value3: f32): void;
97
+
64
98
  public set_anchor_vs_first_element(value1: f32, value2: f32, value3: f32): void;
99
+
65
100
  public set_anchor_vs_second_element(value1: f32, value2: f32, value3: f32): void;
101
+
66
102
  public set_axis_dir_global(value1: f32, value2: f32, value3: f32, value4: i32): void;
103
+
67
104
  public set_axis_dir_vs_first_element(value1: f32, value2: f32, value3: f32, value4: i32): void;
105
+
68
106
  public set_axis_dir_vs_second_element(value1: f32, value2: f32, value3: f32, value4: f32): void;
107
+
69
108
  public set_axis_spring_dumping_factors(value1: f32, value2: f32, value3: i32): void;
109
+
70
110
  public set_joint_spring_dumping_factors(value1: f32, value2: f32): void;
111
+
71
112
  public set_limits(value1: f32, value2: f32, value3: i32): void;
113
+
72
114
  public set_max_force_and_velocity(value1: f32, value2: f32, value3: i32): void;
73
115
  }
74
116
 
@@ -81,19 +123,33 @@ declare module "xray16" {
81
123
  private constructor();
82
124
 
83
125
  public apply_force(a: f32, b: f32, c: f32): void;
126
+
84
127
  public block_breaking(): void;
128
+
85
129
  public get_angular_vel(vector: vector): void;
130
+
86
131
  public get_element_by_bone_id(id: u16): physics_element;
132
+
87
133
  public get_element_by_bone_name(bone_name: string): physics_element;
134
+
88
135
  public get_element_by_order(order: u16): physics_element;
136
+
89
137
  public get_elements_number(): u16;
138
+
90
139
  public get_joint_by_bone_id(id: u16): physics_joint;
140
+
91
141
  public get_joint_by_bone_name(name: string): physics_joint;
142
+
92
143
  public get_joint_by_order(order: u16): physics_joint;
144
+
93
145
  public get_joints_number(): u16;
146
+
94
147
  public get_linear_vel(vector: vector): void;
148
+
95
149
  public is_breakable(): boolean;
150
+
96
151
  public is_breaking_blocked(): boolean;
152
+
97
153
  public unblock_breaking(): void;
98
154
  }
99
155
 
@@ -104,7 +160,9 @@ declare module "xray16" {
104
160
  */
105
161
  export class physics_world {
106
162
  public set_gravity(value: f32): void;
163
+
107
164
  public gravity(): f32;
165
+
108
166
  public add_call(/* class CPHCondition*, class CPHAction */): void;
109
167
  }
110
168
 
@@ -0,0 +1,40 @@
1
+ declare module "xray16" {
2
+ /**
3
+ * @source C++ class CSpaceRestrictor : CGameObject
4
+ * @customConstructor CSpaceRestrictor
5
+ * @group xr_zone
6
+ */
7
+ export class CSpaceRestrictor extends CGameObject {}
8
+
9
+ /**
10
+ * @source C++ class CLevelChanger : CGameObject
11
+ * @customConstructor CLevelChanger
12
+ * @group xr_zone
13
+ */
14
+ export class CLevelChanger extends CGameObject {}
15
+
16
+ /**
17
+ * @source C++ class smart_cover_object : CGameObject
18
+ * @customConstructor smart_cover_object
19
+ * @group xr_zone
20
+ */
21
+ export class smart_cover_object extends CGameObject {}
22
+
23
+ /**
24
+ * @source C++ class ce_script_zone : DLL_Pure
25
+ * @customConstructor ce_script_zone
26
+ * @group xr_zone
27
+ */
28
+ export class ce_script_zone extends DLL_Pure {
29
+ protected constructor();
30
+ }
31
+
32
+ /**
33
+ * @source C++ class ce_smart_zone : DLL_Pure
34
+ * @customConstructor ce_smart_zone
35
+ * @group xr_zone
36
+ */
37
+ export class ce_smart_zone extends DLL_Pure {
38
+ protected constructor();
39
+ }
40
+ }