@ts-defold/types 1.2.26 → 1.2.28

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 (2) hide show
  1. package/index.d.ts +97 -55
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  /// <reference types="lua-types/5.1" />
3
3
  /// <reference types="@typescript-to-lua/language-extensions" />
4
4
 
5
- // DEFOLD. stable version 1.5.0 (00352cc02f24c12e6081245c0d5fb2e0b263d05e)
5
+ // DEFOLD. stable version 1.6.0 (d9e9c49ab946c058f29a8b688c862d70f30e9c43)
6
6
  // =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= //
7
7
 
8
8
 
@@ -124,7 +124,7 @@ declare namespace socket {
124
124
  * @return tcp_client a new IPv6 TCP client object, or `nil` in case of error.
125
125
  * @return error the error message, or `nil` if no error occurred.
126
126
  */
127
- export function connect(address: string, port: number, locaddr?: string, locport?: number, family?: string): LuaMultiReturn<[any, string]>
127
+ export function connect(address: string, port: number, locaddr?: string, locport?: number, family?: string): LuaMultiReturn<[any, any, string, any]>
128
128
 
129
129
  /**
130
130
  * Returns the time in seconds, relative to the system epoch (Unix epoch time since January 1, 1970 (UTC) or Windows file time since January 1, 1601 (UTC)).
@@ -165,7 +165,7 @@ declare namespace socket {
165
165
  * @return sockets_w a list with the sockets ready for writing.
166
166
  * @return error an error message. "timeout" if a timeout condition was met, otherwise `nil`.
167
167
  */
168
- export function select(recvt: any, sendt: any, timeout?: number): LuaMultiReturn<[any, any, string]>
168
+ export function select(recvt: any, sendt: any, timeout?: number): LuaMultiReturn<[any, any, string, any]>
169
169
 
170
170
  /**
171
171
  * This function drops a number of arguments and returns the remaining.
@@ -180,7 +180,8 @@ declare namespace socket {
180
180
  * @return retD_2 argument D+2.
181
181
  * @return retN argument N.
182
182
  */
183
- export function skip(d: number, ret1?: any, ret2?: any, retN?: any): LuaMultiReturn<[any, any, any]> | undefined
183
+ export function skip(d: number, ret1?: any, ret2?: any, retN?: any): any
184
+ export function skip(d: number, ret1?: any, ret2?: any, retN?: any): any
184
185
 
185
186
  /**
186
187
  * Freezes the program execution during a given amount of time.
@@ -193,7 +194,7 @@ declare namespace socket {
193
194
  * @return tcp_master a new IPv4 TCP master object, or `nil` in case of error.
194
195
  * @return error the error message, or `nil` if no error occurred.
195
196
  */
196
- export function tcp(): LuaMultiReturn<[any, string]>
197
+ export function tcp(): LuaMultiReturn<[any, any, string, any]>
197
198
 
198
199
  /**
199
200
  * Creates and returns an IPv6 TCP master object. A master object can be transformed into a server object with the method `listen` (after a call to `bind`) or into a client object with the method connect. The only other method supported by a master object is the close method.
@@ -201,14 +202,14 @@ declare namespace socket {
201
202
  * @return tcp_master a new IPv6 TCP master object, or `nil` in case of error.
202
203
  * @return error the error message, or `nil` if no error occurred.
203
204
  */
204
- export function tcp6(): LuaMultiReturn<[any, string]>
205
+ export function tcp6(): LuaMultiReturn<[any, any, string, any]>
205
206
 
206
207
  /**
207
208
  * Creates and returns an unconnected IPv4 UDP object. Unconnected objects support the `sendto`, `receive`, `receivefrom`, `getoption`, `getsockname`, `setoption`, `settimeout`, `setpeername`, `setsockname`, and `close` methods. The `setpeername` method is used to connect the object.
208
209
  * @return udp_unconnected a new unconnected IPv4 UDP object, or `nil` in case of error.
209
210
  * @return error the error message, or `nil` if no error occurred.
210
211
  */
211
- export function udp(): LuaMultiReturn<[any, string]>
212
+ export function udp(): LuaMultiReturn<[any, any, string, any]>
212
213
 
213
214
  /**
214
215
  * Creates and returns an unconnected IPv6 UDP object. Unconnected objects support the `sendto`, `receive`, `receivefrom`, `getoption`, `getsockname`, `setoption`, `settimeout`, `setpeername`, `setsockname`, and `close` methods. The `setpeername` method is used to connect the object.
@@ -216,7 +217,7 @@ declare namespace socket {
216
217
  * @return udp_unconnected a new unconnected IPv6 UDP object, or `nil` in case of error.
217
218
  * @return error the error message, or `nil` if no error occurred.
218
219
  */
219
- export function udp6(): LuaMultiReturn<[any, string]>
220
+ export function udp6(): LuaMultiReturn<[any, any, string, any]>
220
221
 
221
222
  }
222
223
  // =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= //
@@ -324,9 +325,9 @@ declare namespace crash {
324
325
  * reads a system field from a loaded crash dump
325
326
  * @param handle crash dump handle
326
327
  * @param index system field enum. Must be less than crash.SYSFIELD_MAX
327
- * @return value value recorded in the crash dump, or nil if it didn't exist
328
+ * @return value value recorded in the crash dump, or `nil` if it didn't exist
328
329
  */
329
- export function get_sys_field(handle: number, index: number): string
330
+ export function get_sys_field(handle: number, index: number): LuaMultiReturn<[string, any]>
330
331
 
331
332
  /**
332
333
  * reads user field from a loaded crash dump
@@ -339,9 +340,9 @@ declare namespace crash {
339
340
  /**
340
341
  * The crash dump will be removed from disk upon a successful
341
342
  * load, so loading is one-shot.
342
- * @return handle handle to the loaded dump, or nil if no dump was found
343
+ * @return handle handle to the loaded dump, or `nil` if no dump was found
343
344
  */
344
- export function load_previous(): number
345
+ export function load_previous(): LuaMultiReturn<[number, any]>
345
346
 
346
347
  /**
347
348
  * releases a previously loaded crash dump
@@ -773,9 +774,9 @@ name of internal property
773
774
  /**
774
775
  * Get the parent for a game object instance.
775
776
  * @param id optional id of the game object instance to get parent for, defaults to the instance containing the calling script
776
- * @return parent_id parent instance or nil
777
+ * @return parent_id parent instance or `nil`
777
778
  */
778
- export function get_parent(id?: string | hash | url): hash
779
+ export function get_parent(id?: string | hash | url): LuaMultiReturn<[hash, any]>
779
780
 
780
781
  /**
781
782
  * The position is relative the parent (if any). Use go.get_world_position to retrieve the global world position.
@@ -1636,7 +1637,7 @@ with a custom curve. See the animation guide for more information.
1636
1637
  * @param node node to get the cursor for (node)
1637
1638
  * @return cursor cursor value
1638
1639
  */
1639
- export function get_flipbook_cursor(node: node): any
1640
+ export function get_flipbook_cursor(node: node): number
1640
1641
 
1641
1642
  /**
1642
1643
  * This is only useful nodes with flipbook animations. Gets the playback rate of the flipbook animation on a node.
@@ -1760,14 +1761,14 @@ with a custom curve. See the animation guide for more information.
1760
1761
  * Returns the parent node of the specified node.
1761
1762
  * If the supplied node does not have a parent, `nil` is returned.
1762
1763
  * @param node the node from which to retrieve its parent
1763
- * @return parent parent instance or nil
1764
+ * @return parent parent instance or `nil`
1764
1765
  */
1765
- export function get_parent(node: node): node
1766
+ export function get_parent(node: node): LuaMultiReturn<[node, any]>
1766
1767
 
1767
1768
  /**
1768
1769
  * Get the paricle fx for a gui node
1769
1770
  * @param node node to get particle fx for
1770
- * @return particle fx id
1771
+ * @return particlefx particle fx id
1771
1772
  */
1772
1773
  export function get_particlefx(node: node): hash
1773
1774
 
@@ -1953,18 +1954,18 @@ with a custom curve. See the animation guide for more information.
1953
1954
  * above the second.
1954
1955
  * If the second argument is `nil` the first node is moved to the top.
1955
1956
  * @param node to move
1956
- * @param node reference node above which the first node should be moved
1957
+ * @param reference reference node above which the first node should be moved
1957
1958
  */
1958
- export function move_above(node: node, node1: any): void
1959
+ export function move_above(node: node, reference: any): void
1959
1960
 
1960
1961
  /**
1961
1962
  * Alters the ordering of the two supplied nodes by moving the first node
1962
1963
  * below the second.
1963
1964
  * If the second argument is `nil` the first node is moved to the bottom.
1964
1965
  * @param node to move
1965
- * @param node reference node below which the first node should be moved
1966
+ * @param reference reference node below which the first node should be moved
1966
1967
  */
1967
- export function move_below(node: node, node1: any): void
1968
+ export function move_below(node: node, reference: any): void
1968
1969
 
1969
1970
  /**
1970
1971
  * Dynamically create a new box node.
@@ -2081,6 +2082,12 @@ the new state of the emitter:
2081
2082
  */
2082
2083
  export function reset_keyboard(): void
2083
2084
 
2085
+ /**
2086
+ * Resets the node material to the material assigned in the gui scene.
2087
+ * @param node node to reset the material for
2088
+ */
2089
+ export function reset_material(node: node): void
2090
+
2084
2091
  /**
2085
2092
  * Resets all nodes in the current GUI scene to their initial state.
2086
2093
  * The reset only applies to static node loaded from the scene.
@@ -2286,12 +2293,6 @@ the new state of the emitter:
2286
2293
  */
2287
2294
  export function set_material(node: node, material: string | hash): void
2288
2295
 
2289
- /**
2290
- * Resets the node material to the material assigned in the gui scene.
2291
- * @param node node to reset the material for
2292
- */
2293
- export function set_material(node: node): void
2294
-
2295
2296
  /**
2296
2297
  * Sets the outer bounds mode for a pie node.
2297
2298
  * @param node node for which to set the outer bounds mode
@@ -2675,14 +2676,14 @@ See each joint type for possible properties field. The one field that is accepte
2675
2676
  * Get the gravity in runtime. The gravity returned is not global, it will return
2676
2677
  * the gravity for the collection that the function is called from.
2677
2678
  * Note: For 2D physics the z component will always be zero.
2678
- * @return gravity vector of collection
2679
+ * @return gravity gravity vector of collection
2679
2680
  */
2680
2681
  export function get_gravity(): vmath.vector3
2681
2682
 
2682
2683
  /**
2683
2684
  * Returns the group name of a collision object as a hash.
2684
2685
  * @param url the collision object to return the group of.
2685
- * @return hash value of the group.
2686
+ * @return group hash value of the group.
2686
2687
  `local function check_is_enemy()
2687
2688
  local group = physics.get_group(&quot;#collisionobject&quot;)
2688
2689
  return group == hash(&quot;enemy&quot;)
@@ -2697,7 +2698,7 @@ end
2697
2698
  * Note: Currently only supported in 2D physics.
2698
2699
  * @param collisionobject collision object where the joint exist
2699
2700
  * @param joint_id id of the joint
2700
- * @return properties table. See the joint types for what fields are available, the only field available for all types is:
2701
+ * @return properties properties table. See the joint types for what fields are available, the only field available for all types is:
2701
2702
 
2702
2703
  `collide_connected`: Set this flag to true if the attached bodies should collide.
2703
2704
 
@@ -2729,7 +2730,7 @@ end
2729
2730
  * object, false otherwise.
2730
2731
  * @param url the collision object to check the mask of.
2731
2732
  * @param group the name of the group to check for.
2732
- * @return boolean value of the maskbit. 'true' if present, 'false' otherwise.
2733
+ * @return maskbit boolean value of the maskbit. 'true' if present, 'false' otherwise.
2733
2734
  `local function is_invincible()
2734
2735
  -- check if the collisionobject would collide with the &quot;bullet&quot; group
2735
2736
  local invincible = physics.get_maskbit(&quot;#collisionobject&quot;, &quot;bullet&quot;)
@@ -2753,9 +2754,9 @@ end
2753
2754
  `all`
2754
2755
  Set to `true` to return all ray cast hits. If `false`, it will only return the closest hit.
2755
2756
 
2756
- * @return result It returns a list. If missed it returns nil. See `ray_cast_response` for details on the returned values.
2757
+ * @return result It returns a list. If missed it returns `nil`. See `ray_cast_response` for details on the returned values.
2757
2758
  */
2758
- export function raycast(from: vmath.vector3, to: vmath.vector3, groups: any, options: any): any
2759
+ export function raycast(from: vmath.vector3, to: vmath.vector3, groups: any, options: any): LuaMultiReturn<[any, any]>
2759
2760
 
2760
2761
  /**
2761
2762
  * Ray casts are used to test for intersections against collision objects in the physics world.
@@ -3292,6 +3293,16 @@ declare namespace render {
3292
3293
  */
3293
3294
  export let FORMAT_STENCIL: any
3294
3295
 
3296
+ /**
3297
+ *
3298
+ */
3299
+ export let FRUSTUM_PLANES_ALL: any
3300
+
3301
+ /**
3302
+ *
3303
+ */
3304
+ export let FRUSTUM_PLANES_SIDES: any
3305
+
3295
3306
  /**
3296
3307
  *
3297
3308
  */
@@ -3443,7 +3454,15 @@ declare namespace render {
3443
3454
  * @param options optional table with properties:
3444
3455
 
3445
3456
  `frustum`
3446
- A frustum matrix used to cull renderable items. (E.g. `local frustum = proj * view`). May be nil.
3457
+ A frustum matrix used to cull renderable items. (E.g. `local frustum = proj * view`). default=nil
3458
+ `frustum_planes`
3459
+ Determines which sides of the frustum will be used. Default is render.FRUSTUM_PLANES_SIDES.
3460
+
3461
+
3462
+ - render.FRUSTUM_PLANES_SIDES : The left, right, top and bottom sides of the frustum.
3463
+ - render.FRUSTUM_PLANES_ALL : All 6 sides of the frustum.
3464
+
3465
+
3447
3466
  `constants`
3448
3467
  optional constants to use while rendering
3449
3468
 
@@ -3456,6 +3475,12 @@ optional constants to use while rendering
3456
3475
 
3457
3476
  `frustum`
3458
3477
  A frustum matrix used to cull renderable items. (E.g. `local frustum = proj * view`). May be nil.
3478
+ `frustum_planes`
3479
+ Determines which sides of the frustum will be used. Default is render.FRUSTUM_PLANES_SIDES.
3480
+
3481
+
3482
+ - render.FRUSTUM_PLANES_SIDES : The left, right, top and bottom sides of the frustum.
3483
+ - render.FRUSTUM_PLANES_ALL : All sides of the frustum.
3459
3484
 
3460
3485
  */
3461
3486
  export function draw_debug3d(options?: any): void
@@ -3489,9 +3514,12 @@ A frustum matrix used to cull renderable items. (E.g. `local frustum = proj * vi
3489
3514
  * A material shader can then use the texture to sample from.
3490
3515
  * @param unit texture unit to enable texture for
3491
3516
  * @param render_target render target or texture from which to enable the specified texture unit
3492
- * @param buffer_type optional buffer type from which to enable the texture. Note that this argument only applies to render targets. Defaults to render.BUFFER_COLOR_BIT
3517
+ * @param buffer_type optional buffer type from which to enable the texture. Note that this argument only applies to render targets. Defaults to `render.BUFFER_COLOR_BIT`. These values are supported:
3493
3518
 
3494
3519
  - `render.BUFFER_COLOR_BIT`
3520
+
3521
+ If The render target has been created as depth and/or stencil textures, these buffer types can be used:
3522
+
3495
3523
  - `render.BUFFER_DEPTH_BIT`
3496
3524
  - `render.BUFFER_STENCIL_BIT`
3497
3525
 
@@ -3533,6 +3561,7 @@ to enable those textures as well. Currently 4 color attachments are supported:
3533
3561
  * @param buffer_type which type of buffer to retrieve the width from
3534
3562
 
3535
3563
  - `render.BUFFER_COLOR_BIT`
3564
+ - `render.BUFFER_COLOR[x]_BIT` (x: [0..3], if supported!)
3536
3565
  - `render.BUFFER_DEPTH_BIT`
3537
3566
  - `render.BUFFER_STENCIL_BIT`
3538
3567
 
@@ -3602,22 +3631,26 @@ to enable those textures as well. Currently 4 color attachments are supported:
3602
3631
  * number
3603
3632
  *
3604
3633
  *
3605
- * `min_filter`
3634
+ * `min_filter` (optional)
3606
3635
  * `render.FILTER_LINEAR``render.FILTER_NEAREST`
3607
3636
  *
3608
3637
  *
3609
- * `mag_filter`
3638
+ * `mag_filter` (optional)
3610
3639
  * `render.FILTER_LINEAR``render.FILTER_NEAREST`
3611
3640
  *
3612
3641
  *
3613
- * `u_wrap`
3642
+ * `u_wrap` (optional)
3614
3643
  * `render.WRAP_CLAMP_TO_BORDER``render.WRAP_CLAMP_TO_EDGE``render.WRAP_MIRRORED_REPEAT``render.WRAP_REPEAT`
3615
3644
  *
3616
3645
  *
3617
- * `v_wrap`
3646
+ * `v_wrap` (optional)
3618
3647
  * `render.WRAP_CLAMP_TO_BORDER``render.WRAP_CLAMP_TO_EDGE``render.WRAP_MIRRORED_REPEAT``render.WRAP_REPEAT`
3619
3648
  *
3620
3649
  *
3650
+ * `flags` (optional)
3651
+ * `render.TEXTURE_BIT` (only applicable to depth and stencil buffers)
3652
+ *
3653
+ *
3621
3654
  *
3622
3655
  * The render target can be created to support multiple color attachments. Each attachment can have different format settings and texture filters,
3623
3656
  * but attachments must be added in sequence, meaning you cannot create a render target at slot 0 and 3.
@@ -4760,6 +4793,14 @@ declare namespace sys {
4760
4793
  */
4761
4794
  export function deserialize(buffer: string): any
4762
4795
 
4796
+ /**
4797
+ * Check if a path exists
4798
+ * Good for checking if a file exists before loading a large file
4799
+ * @param path path to check
4800
+ * @return result `true` if the path exists, `false` otherwise
4801
+ */
4802
+ export function exists(path: string): any
4803
+
4763
4804
  /**
4764
4805
  * Terminates the game application and reports the specified `code` to the OS.
4765
4806
  * @param code exit code to report to the OS, 0 means clean exit
@@ -4914,7 +4955,7 @@ The HTTP user agent, i.e. "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) Apple
4914
4955
  /**
4915
4956
  * Loads a custom resource. Specify the full filename of the resource that you want
4916
4957
  * to load. When loaded, the file data is returned as a string.
4917
- * If loading fails, the function returns nil plus the error message.
4958
+ * If loading fails, the function returns `nil` plus the error message.
4918
4959
  * In order for the engine to include custom resources in the build process, you need
4919
4960
  * to specify them in the "custom_resources" key in your "game.project" settings file.
4920
4961
  * You can specify single resource files or directories. If a directory is included
@@ -4925,7 +4966,8 @@ The HTTP user agent, i.e. "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) Apple
4925
4966
  * @return data loaded data, or `nil` if the resource could not be loaded
4926
4967
  * @return error the error message, or `nil` if no error occurred
4927
4968
  */
4928
- export function load_resource(filename: string): LuaMultiReturn<[string, string]>
4969
+ export function load_resource(filename: string): string
4970
+ export function load_resource(filename: string): any
4929
4971
 
4930
4972
  /**
4931
4973
  * Open URL in default application, typically a browser
@@ -5134,7 +5176,7 @@ declare namespace window {
5134
5176
 
5135
5177
  /**
5136
5178
  * Sets a window event listener.
5137
- * @param callback A callback which receives info about window events. Pass an empty function or nil if you no longer wish to receive callbacks.
5179
+ * @param callback A callback which receives info about window events. Pass an empty function or `nil` if you no longer wish to receive callbacks.
5138
5180
 
5139
5181
  `self`
5140
5182
  The calling script
@@ -5271,10 +5313,10 @@ declare namespace buffer {
5271
5313
  * Get a named metadata entry from a buffer along with its type.
5272
5314
  * @param buf the buffer to get the metadata from
5273
5315
  * @param metadata_name name of the metadata entry
5274
- * @return values table of metadata values or nil if the entry does not exist
5275
- * @return value_type numeric type of values or nil
5316
+ * @return values table of metadata values or `nil` if the entry does not exist
5317
+ * @return value_type numeric type of values or `nil`
5276
5318
  */
5277
- export function get_metadata(buf: buffer, metadata_name: hash | string): LuaMultiReturn<[any, any]>
5319
+ export function get_metadata(buf: buffer, metadata_name: hash | string): LuaMultiReturn<[any, any, any, any]>
5278
5320
 
5279
5321
  /**
5280
5322
  * Get a specified stream from a buffer.
@@ -5314,7 +5356,7 @@ declare namespace html5 {
5314
5356
  * invoked when a user interacts with the web page by clicking, touching or typing.
5315
5357
  * The callback can then call DOM restricted actions like requesting a pointer lock,
5316
5358
  * or start playing sounds the first time the callback is invoked.
5317
- * @param callback The interaction callback. Pass an empty function or nil if you no longer wish to receive callbacks.
5359
+ * @param callback The interaction callback. Pass an empty function or `nil` if you no longer wish to receive callbacks.
5318
5360
 
5319
5361
  `self`
5320
5362
  The calling script
@@ -5399,7 +5441,7 @@ declare namespace image {
5399
5441
  `buffer`: the raw image data
5400
5442
 
5401
5443
  */
5402
- export function load(buffer: string, premult?: boolean): any
5444
+ export function load(buffer: string, premult?: boolean): LuaMultiReturn<[any, any]>
5403
5445
 
5404
5446
  }
5405
5447
  // =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= =^..^= //
@@ -5505,7 +5547,7 @@ declare namespace timer {
5505
5547
  export function cancel(handle: hash): boolean
5506
5548
 
5507
5549
  /**
5508
- * Adds a timer and returns a unique handle
5550
+ * Adds a timer and returns a unique handle.
5509
5551
  * You may create more timers from inside a timer callback.
5510
5552
  * Using a delay of 0 will result in a timer that triggers at the next frame just before
5511
5553
  * script update functions.
@@ -5529,7 +5571,7 @@ The elapsed time - on first trigger it is time since timer.delay call, otherwise
5529
5571
  /**
5530
5572
  * Get information about timer.
5531
5573
  * @param handle the timer handle returned by timer.delay()
5532
- * @return data or nil if timer is cancelled/completed. table with data in the following fields:
5574
+ * @return data table or `nil` if timer is cancelled/completed. table with data in the following fields:
5533
5575
 
5534
5576
  `time_remaining`
5535
5577
  Time remaining until the next time a timer.delay() fires.
@@ -5539,7 +5581,7 @@ Time interval.
5539
5581
  true = repeat timer until cancel, false = one-shot timer.
5540
5582
 
5541
5583
  */
5542
- export function get_info(handle: hash): any
5584
+ export function get_info(handle: hash): LuaMultiReturn<[any, any]>
5543
5585
 
5544
5586
  /**
5545
5587
  * Manual triggering a callback for a timer.
@@ -6190,7 +6232,7 @@ True if resource were loaded successfully
6190
6232
  * Changes the prototype for the collection factory.
6191
6233
  * Setting the prototype to "nil" will revert back to the original prototype.
6192
6234
  * @param url the collection factory component
6193
- * @param prototype the path to the new prototype, or nil
6235
+ * @param prototype the path to the new prototype, or `nil`
6194
6236
  */
6195
6237
  export function set_prototype(url?: string | hash | url, prototype?: any): void
6196
6238
 
@@ -6369,7 +6411,7 @@ True if resources were loaded successfully
6369
6411
  /**
6370
6412
  * Changes the prototype for the factory.
6371
6413
  * @param url the factory component
6372
- * @param prototype the path to the new prototype, or nil
6414
+ * @param prototype the path to the new prototype, or `nil`
6373
6415
  */
6374
6416
  export function set_prototype(url?: string | hash | url, prototype?: any): void
6375
6417
 
@@ -6973,7 +7015,7 @@ declare namespace sprite {
6973
7015
  * the animation has completed playing. If no function is provided,
6974
7016
  * a animation_done message is sent to the script that started the animation.
6975
7017
  * @param url the sprite that should play the animation
6976
- * @param id hash name hash of the animation to play
7018
+ * @param id hashed id of the animation to play
6977
7019
  * @param complete_function function to call when the animation has completed.
6978
7020
 
6979
7021
  `self`
@@ -6999,7 +7041,7 @@ the normalized initial value of the animation cursor when the animation starts p
6999
7041
  the rate with which the animation will be played. Must be positive.
7000
7042
 
7001
7043
  */
7002
- export function play_flipbook(url: string | hash | url, id: any, complete_function?: any, play_properties?: any): void
7044
+ export function play_flipbook(url: string | hash | url, id: string | hash, complete_function?: any, play_properties?: any): void
7003
7045
 
7004
7046
  /**
7005
7047
  * Sets horizontal flipping of the provided sprite's animations.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ts-defold/types",
3
- "version": "1.2.26",
3
+ "version": "1.2.28",
4
4
  "description": "TypeScript definitions for Defold",
5
5
  "repository": "github:ts-defold/types",
6
6
  "keywords": [