xray16 1.0.3 → 1.0.4

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xray16",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "author": "Neloreck",
5
5
  "repository": "https://github.com/stalker-xrts/xray-16-types",
6
6
  "private": false,
@@ -386,8 +386,8 @@ declare module "xray16" {
386
386
  * @group xr_global
387
387
  */
388
388
  export interface IXR_level {
389
- add_call(this: void, cb1: () => boolean, cb2: () => boolean): void;
390
- add_call(this: void, object: object, cb1: () => boolean, cb2: () => boolean): void;
389
+ add_call(this: void, cb1: (this: void) => boolean, cb2: (this: void) => boolean): void;
390
+ add_call(this: void, object: object, cb1: (this: void) => boolean, cb2: (this: void) => boolean): void;
391
391
  add_call(this: void, object: object, str1: string, str2: string): void;
392
392
  add_cam_effector(this: void, effect: string, id: i32, is_cyclic: boolean, callback: string): void;
393
393
  add_cam_effector2(this: void, effect: string, id: i32, is_cyclic: boolean, callback: string, camera_fov: f32): void;
@@ -449,9 +449,9 @@ declare module "xray16" {
449
449
  hide_indicators_safe(this: void): void;
450
450
  high_cover_in_direction(this: void, num: u32, vector: vector): f32;
451
451
  is_wfx_playing(this: void): boolean;
452
- iterate_online_objects(this: void, cb: (object: game_object) => void | boolean): void;
453
- iterate_sounds(this: void, str: string, num: u32, cb: () => void): void;
454
- iterate_sounds(this: void, str: string, num: u32, object: object, cb: () => void): void;
452
+ iterate_online_objects(this: void, cb: (this: void, object: game_object) => void | boolean): void;
453
+ iterate_sounds(this: void, str: string, num: u32, cb: (this: void) => void): void;
454
+ iterate_sounds(this: void, str: string, num: u32, object: object, cb: (this: void) => void): void;
455
455
  low_cover_in_direction(this: void, num: u32, vector: vector): f32;
456
456
  main_input_receiver(this: void): CUIDialogWnd;
457
457
  map_add_object_spot(this: void, id: u16, selector: string, hint: string): void;
@@ -474,8 +474,8 @@ declare module "xray16" {
474
474
  * @returns intensity of rain, 0 if no rain active
475
475
  */
476
476
  rain_factor(this: void): f32;
477
- remove_call(this: void, cb1: () => boolean, cb2: () => void): void;
478
- remove_call(this: void, object: object, cb1: () => boolean, cb2: () => void): void;
477
+ remove_call(this: void, cb1: (this: void) => boolean, cb2: (this: void) => void): void;
478
+ remove_call(this: void, object: object, cb1: (this: void) => boolean, cb2: (this: void) => void): void;
479
479
  remove_call(this: void, object: object, str1: string, str2: string): void;
480
480
  remove_calls_for_object(this: void, object: object): void;
481
481
  remove_cam_effector(this: void, id: i32): void;
@@ -18,7 +18,7 @@ declare module "xray16" {
18
18
  ): cse_abstract;
19
19
  public dont_has_info(object_id: u16, info_id: string): boolean;
20
20
  public has_info(object_id: u16, info_id: string): boolean;
21
- public iterate_objects(cb: (object: cse_alife_object) => boolean | void): void;
21
+ public iterate_objects(cb: (this: void, object: cse_alife_object) => boolean | void): void;
22
22
  public level_id(): u32;
23
23
  public level_name<T extends string = string>(value: i32): T;
24
24
  public release(cse_abstract: cse_alife_object | null, flag: boolean): void;
@@ -200,7 +200,7 @@ declare module "xray16" {
200
200
  */
201
201
  export class client_spawn_manager {
202
202
  public remove(number1: u16, number2: u16): void;
203
- public add(number1: u16, number2: u16, cb: () => void): void;
204
- public add(number1: u16, number2: u16, cb: () => void, object: XR_object): void;
203
+ public add(number1: u16, number2: u16, cb: (this: void) => void): void;
204
+ public add(number1: u16, number2: u16, cb: (this: void) => void, object: XR_object): void;
205
205
  }
206
206
  }
@@ -758,11 +758,14 @@ declare module "xray16" {
758
758
  public idle_max_time(): f32;
759
759
  public idle_max_time(time: f32): void;
760
760
  public in_current_loophole_fov(vector: vector): boolean;
761
- public inventory_for_each(cb: () => void): void;
761
+ public inventory_for_each(cb: (this: void) => void): void;
762
762
  public is_door_blocked_by_npc(): boolean;
763
763
  public is_talk_enabled(): boolean;
764
764
  public is_weapon_going_to_be_strapped(weapon: game_object | null): boolean;
765
- public iterate_inventory_box(cb: (box: game_object, item: game_object) => void, object: game_object): void;
765
+ public iterate_inventory_box(
766
+ cb: (this: void, box: game_object, item: game_object) => void,
767
+ object: game_object
768
+ ): void;
766
769
  public lookout_max_time(): f32;
767
770
  public lookout_max_time(value: f32): void;
768
771
  public max_ignore_monster_distance(): f32;
@@ -151,7 +151,7 @@ declare module "xray16" {
151
151
 
152
152
  public OnKeyboard(key: TXR_DIK_key, event: TXR_ui_event): boolean;
153
153
  public Update(): void;
154
- public AddCallback(name: string, event: number, cb: () => void, source?: CUIWindow): void;
154
+ public AddCallback(name: string, event: number, cb: (this: void) => void, source?: CUIWindow): void;
155
155
  public Dispatch(command: number, parameter: number): boolean;
156
156
  public Register(window: CUIWindow, name: string): void;
157
157
  public Load(value: string): boolean;