@defold-typescript/types 0.48.0 → 0.50.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.
Files changed (78) hide show
  1. package/api-availability.json +696 -624
  2. package/api-signatures.json +6799 -160
  3. package/api-targets.json +393 -2
  4. package/examples/translations.json +12 -0
  5. package/generated/b2d.d.ts +15 -0
  6. package/generated/bullet3d.d.ts +16 -0
  7. package/generated/font.d.ts +7 -3
  8. package/generated/graphics.d.ts +7 -0
  9. package/generated/gui.d.ts +5 -4
  10. package/generated/label.d.ts +3 -3
  11. package/generated/render.d.ts +16 -1
  12. package/generated/versions/defold-1.13.2/b2d.d.ts +709 -0
  13. package/generated/versions/defold-1.13.2/b2d_body.d.ts +593 -0
  14. package/generated/versions/defold-1.13.2/b2d_chain.d.ts +105 -0
  15. package/generated/versions/defold-1.13.2/b2d_fixture.d.ts +175 -0
  16. package/generated/versions/defold-1.13.2/b2d_joint.d.ts +1301 -0
  17. package/generated/versions/defold-1.13.2/b2d_shape.d.ts +423 -0
  18. package/generated/versions/defold-1.13.2/b2d_world.d.ts +308 -0
  19. package/generated/versions/defold-1.13.2/buffer.d.ts +192 -0
  20. package/generated/versions/defold-1.13.2/bullet3d.d.ts +91 -0
  21. package/generated/versions/defold-1.13.2/bullet3d_collision_object.d.ts +433 -0
  22. package/generated/versions/defold-1.13.2/bullet3d_constraint.d.ts +818 -0
  23. package/generated/versions/defold-1.13.2/bullet3d_rigid_body.d.ts +429 -0
  24. package/generated/versions/defold-1.13.2/bullet3d_shape.d.ts +123 -0
  25. package/generated/versions/defold-1.13.2/bullet3d_world.d.ts +492 -0
  26. package/generated/versions/defold-1.13.2/camera.d.ts +300 -0
  27. package/generated/versions/defold-1.13.2/collectionfactory.d.ts +148 -0
  28. package/generated/versions/defold-1.13.2/collectionproxy.d.ts +109 -0
  29. package/generated/versions/defold-1.13.2/compute.d.ts +107 -0
  30. package/generated/versions/defold-1.13.2/crash.d.ts +157 -0
  31. package/generated/versions/defold-1.13.2/editor-vm/http.d.ts +139 -0
  32. package/generated/versions/defold-1.13.2/editor-vm/image.d.ts +48 -0
  33. package/generated/versions/defold-1.13.2/editor-vm/json.d.ts +21 -0
  34. package/generated/versions/defold-1.13.2/editor-vm/localization.d.ts +42 -0
  35. package/generated/versions/defold-1.13.2/editor-vm/tilemap_tiles.d.ts +126 -0
  36. package/generated/versions/defold-1.13.2/editor-vm/zip.d.ts +38 -0
  37. package/generated/versions/defold-1.13.2/editor-vm/zlib.d.ts +24 -0
  38. package/generated/versions/defold-1.13.2/editor.d.ts +2177 -0
  39. package/generated/versions/defold-1.13.2/factory.d.ts +121 -0
  40. package/generated/versions/defold-1.13.2/font.d.ts +123 -0
  41. package/generated/versions/defold-1.13.2/go.d.ts +1166 -0
  42. package/generated/versions/defold-1.13.2/graphics.d.ts +613 -0
  43. package/generated/versions/defold-1.13.2/gui.d.ts +2212 -0
  44. package/generated/versions/defold-1.13.2/html5.d.ts +55 -0
  45. package/generated/versions/defold-1.13.2/http.d.ts +83 -0
  46. package/generated/versions/defold-1.13.2/image.d.ts +181 -0
  47. package/generated/versions/defold-1.13.2/index.d.ts +63 -0
  48. package/generated/versions/defold-1.13.2/json.d.ts +94 -0
  49. package/generated/versions/defold-1.13.2/kinds/editor-script.d.ts +14 -0
  50. package/generated/versions/defold-1.13.2/label.d.ts +164 -0
  51. package/generated/versions/defold-1.13.2/liveupdate.d.ts +143 -0
  52. package/generated/versions/defold-1.13.2/material.d.ts +490 -0
  53. package/generated/versions/defold-1.13.2/model.d.ts +287 -0
  54. package/generated/versions/defold-1.13.2/msg.d.ts +10 -0
  55. package/generated/versions/defold-1.13.2/particlefx.d.ts +155 -0
  56. package/generated/versions/defold-1.13.2/physics.d.ts +789 -0
  57. package/generated/versions/defold-1.13.2/profiler.d.ts +228 -0
  58. package/generated/versions/defold-1.13.2/render.d.ts +1153 -0
  59. package/generated/versions/defold-1.13.2/resource.d.ts +1628 -0
  60. package/generated/versions/defold-1.13.2/socket.d.ts +797 -0
  61. package/generated/versions/defold-1.13.2/sound.d.ts +323 -0
  62. package/generated/versions/defold-1.13.2/sprite.d.ts +179 -0
  63. package/generated/versions/defold-1.13.2/sys.d.ts +754 -0
  64. package/generated/versions/defold-1.13.2/tilemap.d.ts +206 -0
  65. package/generated/versions/defold-1.13.2/timer.d.ts +136 -0
  66. package/generated/versions/defold-1.13.2/types.d.ts +61 -0
  67. package/generated/versions/defold-1.13.2/vmath.d.ts +775 -0
  68. package/generated/versions/defold-1.13.2/window.d.ts +196 -0
  69. package/generated/versions/defold-1.13.2/zlib.d.ts +41 -0
  70. package/hsm/debug.d.ts +6 -3
  71. package/hsm/index.d.ts +309 -77
  72. package/identity-vocabulary.json +1 -0
  73. package/package.json +2 -2
  74. package/scripts/import-defold-release.ts +3 -31
  75. package/scripts/materialize-version.ts +13 -7
  76. package/scripts/regen.ts +63 -29
  77. package/scripts/sync-api-docs.ts +31 -2
  78. package/src/emit-dts.ts +25 -3
@@ -0,0 +1,1301 @@
1
+ /** @noSelfInFile */
2
+ import type { Opaque, Vector3 } from "../../../src/core-types";
3
+
4
+ declare global {
5
+ /**
6
+ * Functions for interacting with native Box2D joints.
7
+ */
8
+ namespace b2d.joint {
9
+ type b2Joint = Opaque<"b2Joint">;
10
+ /**
11
+ * Box2D distance-joint definition
12
+ */
13
+ interface distance_definition {
14
+ /**
15
+ * Local anchor on the first body.
16
+ */
17
+ local_anchor_a?: Vector3;
18
+ /**
19
+ * Local anchor on the second body.
20
+ */
21
+ local_anchor_b?: Vector3;
22
+ /**
23
+ * Rest length.
24
+ */
25
+ length?: number;
26
+ /**
27
+ * Minimum length.
28
+ */
29
+ min_length?: number;
30
+ /**
31
+ * Maximum length.
32
+ */
33
+ max_length?: number;
34
+ /**
35
+ * Whether the spring is enabled.
36
+ */
37
+ enable_spring?: boolean;
38
+ /**
39
+ * Spring frequency in hertz.
40
+ */
41
+ hertz?: number;
42
+ /**
43
+ * Legacy spring frequency alias.
44
+ */
45
+ frequency?: number;
46
+ /**
47
+ * Spring damping ratio.
48
+ */
49
+ damping_ratio?: number;
50
+ /**
51
+ * Legacy spring damping-ratio alias.
52
+ */
53
+ damping?: number;
54
+ /**
55
+ * Whether length limits are enabled.
56
+ */
57
+ enable_limit?: boolean;
58
+ /**
59
+ * Whether the motor is enabled.
60
+ */
61
+ enable_motor?: boolean;
62
+ /**
63
+ * Maximum motor force.
64
+ */
65
+ max_motor_force?: number;
66
+ /**
67
+ * Motor speed.
68
+ */
69
+ motor_speed?: number;
70
+ /**
71
+ * Whether connected bodies collide.
72
+ */
73
+ collide_connected?: boolean;
74
+ }
75
+ type filter_definition = {};
76
+ /**
77
+ * Box2D friction-joint definition
78
+ */
79
+ interface friction_definition {
80
+ /**
81
+ * Local anchor on the first body.
82
+ */
83
+ local_anchor_a?: Vector3;
84
+ /**
85
+ * Local anchor on the second body.
86
+ */
87
+ local_anchor_b?: Vector3;
88
+ /**
89
+ * Maximum friction force.
90
+ */
91
+ max_force?: number;
92
+ /**
93
+ * Maximum friction torque.
94
+ */
95
+ max_torque?: number;
96
+ /**
97
+ * Whether connected bodies collide.
98
+ */
99
+ collide_connected?: boolean;
100
+ }
101
+ /**
102
+ * Box2D gear-joint definition
103
+ */
104
+ interface gear_definition {
105
+ /**
106
+ * Gear ratio.
107
+ */
108
+ ratio?: number;
109
+ /**
110
+ * Whether connected bodies collide.
111
+ */
112
+ collide_connected?: boolean;
113
+ }
114
+ /**
115
+ * Box2D motor-joint definition
116
+ */
117
+ interface motor_definition {
118
+ /**
119
+ * Linear target offset.
120
+ */
121
+ linear_offset?: Vector3;
122
+ /**
123
+ * Angular target offset.
124
+ */
125
+ angular_offset?: number;
126
+ /**
127
+ * Maximum motor force.
128
+ */
129
+ max_force?: number;
130
+ /**
131
+ * Maximum motor torque.
132
+ */
133
+ max_torque?: number;
134
+ /**
135
+ * Position correction factor.
136
+ */
137
+ correction_factor?: number;
138
+ /**
139
+ * Whether connected bodies collide.
140
+ */
141
+ collide_connected?: boolean;
142
+ }
143
+ /**
144
+ * Box2D mouse-joint definition
145
+ */
146
+ interface mouse_definition {
147
+ /**
148
+ * Target position.
149
+ */
150
+ target?: Vector3;
151
+ /**
152
+ * Maximum force.
153
+ */
154
+ max_force?: number;
155
+ /**
156
+ * Spring frequency in hertz.
157
+ */
158
+ hertz?: number;
159
+ /**
160
+ * Legacy spring frequency alias.
161
+ */
162
+ frequency?: number;
163
+ /**
164
+ * Spring damping ratio.
165
+ */
166
+ damping_ratio?: number;
167
+ /**
168
+ * Legacy spring damping-ratio alias.
169
+ */
170
+ damping?: number;
171
+ /**
172
+ * Whether connected bodies collide.
173
+ */
174
+ collide_connected?: boolean;
175
+ }
176
+ /**
177
+ * Box2D prismatic-joint definition
178
+ */
179
+ interface prismatic_definition {
180
+ /**
181
+ * Local anchor on the first body.
182
+ */
183
+ local_anchor_a?: Vector3;
184
+ /**
185
+ * Local anchor on the second body.
186
+ */
187
+ local_anchor_b?: Vector3;
188
+ /**
189
+ * Local translation axis on the first body.
190
+ */
191
+ local_axis_a?: Vector3;
192
+ /**
193
+ * Reference angle.
194
+ */
195
+ reference_angle?: number;
196
+ /**
197
+ * Whether the spring is enabled.
198
+ */
199
+ enable_spring?: boolean;
200
+ /**
201
+ * Spring frequency in hertz.
202
+ */
203
+ hertz?: number;
204
+ /**
205
+ * Legacy spring frequency alias.
206
+ */
207
+ frequency?: number;
208
+ /**
209
+ * Spring damping ratio.
210
+ */
211
+ damping_ratio?: number;
212
+ /**
213
+ * Legacy spring damping-ratio alias.
214
+ */
215
+ damping?: number;
216
+ /**
217
+ * Whether translation limits are enabled.
218
+ */
219
+ enable_limit?: boolean;
220
+ /**
221
+ * Lower translation limit.
222
+ */
223
+ lower_translation?: number;
224
+ /**
225
+ * Upper translation limit.
226
+ */
227
+ upper_translation?: number;
228
+ /**
229
+ * Whether the motor is enabled.
230
+ */
231
+ enable_motor?: boolean;
232
+ /**
233
+ * Maximum motor force.
234
+ */
235
+ max_motor_force?: number;
236
+ /**
237
+ * Motor speed.
238
+ */
239
+ motor_speed?: number;
240
+ /**
241
+ * Whether connected bodies collide.
242
+ */
243
+ collide_connected?: boolean;
244
+ }
245
+ /**
246
+ * Box2D pulley-joint definition
247
+ */
248
+ interface pulley_definition {
249
+ /**
250
+ * First ground anchor.
251
+ */
252
+ ground_anchor_a?: Vector3;
253
+ /**
254
+ * Second ground anchor.
255
+ */
256
+ ground_anchor_b?: Vector3;
257
+ /**
258
+ * Local anchor on the first body.
259
+ */
260
+ local_anchor_a?: Vector3;
261
+ /**
262
+ * Local anchor on the second body.
263
+ */
264
+ local_anchor_b?: Vector3;
265
+ /**
266
+ * First segment length.
267
+ */
268
+ length_a?: number;
269
+ /**
270
+ * Second segment length.
271
+ */
272
+ length_b?: number;
273
+ /**
274
+ * Pulley ratio.
275
+ */
276
+ ratio?: number;
277
+ /**
278
+ * Whether connected bodies collide.
279
+ */
280
+ collide_connected?: boolean;
281
+ }
282
+ /**
283
+ * Box2D revolute-joint definition
284
+ */
285
+ interface revolute_definition {
286
+ /**
287
+ * Local anchor on the first body.
288
+ */
289
+ local_anchor_a?: Vector3;
290
+ /**
291
+ * Local anchor on the second body.
292
+ */
293
+ local_anchor_b?: Vector3;
294
+ /**
295
+ * Reference angle.
296
+ */
297
+ reference_angle?: number;
298
+ /**
299
+ * Whether the spring is enabled.
300
+ */
301
+ enable_spring?: boolean;
302
+ /**
303
+ * Spring frequency in hertz.
304
+ */
305
+ hertz?: number;
306
+ /**
307
+ * Legacy spring frequency alias.
308
+ */
309
+ frequency?: number;
310
+ /**
311
+ * Spring damping ratio.
312
+ */
313
+ damping_ratio?: number;
314
+ /**
315
+ * Legacy spring damping-ratio alias.
316
+ */
317
+ damping?: number;
318
+ /**
319
+ * Whether angular limits are enabled.
320
+ */
321
+ enable_limit?: boolean;
322
+ /**
323
+ * Lower angular limit.
324
+ */
325
+ lower_angle?: number;
326
+ /**
327
+ * Upper angular limit.
328
+ */
329
+ upper_angle?: number;
330
+ /**
331
+ * Whether the motor is enabled.
332
+ */
333
+ enable_motor?: boolean;
334
+ /**
335
+ * Maximum motor torque.
336
+ */
337
+ max_motor_torque?: number;
338
+ /**
339
+ * Motor speed.
340
+ */
341
+ motor_speed?: number;
342
+ /**
343
+ * Whether connected bodies collide.
344
+ */
345
+ collide_connected?: boolean;
346
+ }
347
+ /**
348
+ * Box2D rope-joint definition
349
+ */
350
+ interface rope_definition {
351
+ /**
352
+ * Local anchor on the first body.
353
+ */
354
+ local_anchor_a?: Vector3;
355
+ /**
356
+ * Local anchor on the second body.
357
+ */
358
+ local_anchor_b?: Vector3;
359
+ /**
360
+ * Maximum rope length.
361
+ */
362
+ max_length?: number;
363
+ /**
364
+ * Whether connected bodies collide.
365
+ */
366
+ collide_connected?: boolean;
367
+ }
368
+ /**
369
+ * Box2D weld-joint definition
370
+ */
371
+ interface weld_definition {
372
+ /**
373
+ * Local anchor on the first body.
374
+ */
375
+ local_anchor_a?: Vector3;
376
+ /**
377
+ * Local anchor on the second body.
378
+ */
379
+ local_anchor_b?: Vector3;
380
+ /**
381
+ * Reference angle.
382
+ */
383
+ reference_angle?: number;
384
+ /**
385
+ * Legacy spring frequency in hertz.
386
+ */
387
+ hertz?: number;
388
+ /**
389
+ * Legacy spring frequency.
390
+ */
391
+ frequency?: number;
392
+ /**
393
+ * Legacy spring damping ratio.
394
+ */
395
+ damping_ratio?: number;
396
+ /**
397
+ * Legacy spring damping-ratio alias.
398
+ */
399
+ damping?: number;
400
+ /**
401
+ * Linear spring frequency in hertz.
402
+ */
403
+ linear_hertz?: number;
404
+ /**
405
+ * Angular spring frequency in hertz.
406
+ */
407
+ angular_hertz?: number;
408
+ /**
409
+ * Linear damping ratio.
410
+ */
411
+ linear_damping_ratio?: number;
412
+ /**
413
+ * Angular damping ratio.
414
+ */
415
+ angular_damping_ratio?: number;
416
+ /**
417
+ * Whether connected bodies collide.
418
+ */
419
+ collide_connected?: boolean;
420
+ }
421
+ /**
422
+ * Box2D wheel-joint definition
423
+ */
424
+ interface wheel_definition {
425
+ /**
426
+ * Local anchor on the first body.
427
+ */
428
+ local_anchor_a?: Vector3;
429
+ /**
430
+ * Local anchor on the second body.
431
+ */
432
+ local_anchor_b?: Vector3;
433
+ /**
434
+ * Local suspension axis on the first body.
435
+ */
436
+ local_axis_a?: Vector3;
437
+ /**
438
+ * Whether the spring is enabled.
439
+ */
440
+ enable_spring?: boolean;
441
+ /**
442
+ * Spring frequency in hertz.
443
+ */
444
+ hertz?: number;
445
+ /**
446
+ * Legacy spring frequency alias.
447
+ */
448
+ frequency?: number;
449
+ /**
450
+ * Spring damping ratio.
451
+ */
452
+ damping_ratio?: number;
453
+ /**
454
+ * Legacy spring damping-ratio alias.
455
+ */
456
+ damping?: number;
457
+ /**
458
+ * Whether translation limits are enabled.
459
+ */
460
+ enable_limit?: boolean;
461
+ /**
462
+ * Lower translation limit.
463
+ */
464
+ lower_translation?: number;
465
+ /**
466
+ * Upper translation limit.
467
+ */
468
+ upper_translation?: number;
469
+ /**
470
+ * Whether the motor is enabled.
471
+ */
472
+ enable_motor?: boolean;
473
+ /**
474
+ * Maximum motor torque.
475
+ */
476
+ max_motor_torque?: number;
477
+ /**
478
+ * Motor speed.
479
+ */
480
+ motor_speed?: number;
481
+ /**
482
+ * Whether connected bodies collide.
483
+ */
484
+ collide_connected?: boolean;
485
+ }
486
+ type JOINT_TYPE = typeof b2d.joint.JOINT_TYPE_DISTANCE | typeof b2d.joint.JOINT_TYPE_FILTER | typeof b2d.joint.JOINT_TYPE_FRICTION | typeof b2d.joint.JOINT_TYPE_GEAR | typeof b2d.joint.JOINT_TYPE_MOTOR | typeof b2d.joint.JOINT_TYPE_MOUSE | typeof b2d.joint.JOINT_TYPE_PRISMATIC | typeof b2d.joint.JOINT_TYPE_PULLEY | typeof b2d.joint.JOINT_TYPE_REVOLUTE | typeof b2d.joint.JOINT_TYPE_ROPE | typeof b2d.joint.JOINT_TYPE_UNKNOWN | typeof b2d.joint.JOINT_TYPE_WELD | typeof b2d.joint.JOINT_TYPE_WHEEL;
487
+ type LIMIT_STATE = typeof b2d.joint.LIMIT_STATE_AT_LOWER | typeof b2d.joint.LIMIT_STATE_AT_UPPER | typeof b2d.joint.LIMIT_STATE_EQUAL | typeof b2d.joint.LIMIT_STATE_INACTIVE;
488
+ /**
489
+ * Distance joint type.
490
+ */
491
+ const JOINT_TYPE_DISTANCE: number & { readonly __brand: "b2d.joint.JOINT_TYPE_DISTANCE" };
492
+ /**
493
+ * Filter joint type.
494
+ */
495
+ const JOINT_TYPE_FILTER: number & { readonly __brand: "b2d.joint.JOINT_TYPE_FILTER" };
496
+ /**
497
+ * Friction joint type.
498
+ */
499
+ const JOINT_TYPE_FRICTION: number & { readonly __brand: "b2d.joint.JOINT_TYPE_FRICTION" };
500
+ /**
501
+ * Gear joint type.
502
+ */
503
+ const JOINT_TYPE_GEAR: number & { readonly __brand: "b2d.joint.JOINT_TYPE_GEAR" };
504
+ /**
505
+ * Motor joint type.
506
+ */
507
+ const JOINT_TYPE_MOTOR: number & { readonly __brand: "b2d.joint.JOINT_TYPE_MOTOR" };
508
+ /**
509
+ * Mouse joint type.
510
+ */
511
+ const JOINT_TYPE_MOUSE: number & { readonly __brand: "b2d.joint.JOINT_TYPE_MOUSE" };
512
+ /**
513
+ * Prismatic joint type.
514
+ */
515
+ const JOINT_TYPE_PRISMATIC: number & { readonly __brand: "b2d.joint.JOINT_TYPE_PRISMATIC" };
516
+ /**
517
+ * Pulley joint type.
518
+ */
519
+ const JOINT_TYPE_PULLEY: number & { readonly __brand: "b2d.joint.JOINT_TYPE_PULLEY" };
520
+ /**
521
+ * Revolute joint type.
522
+ */
523
+ const JOINT_TYPE_REVOLUTE: number & { readonly __brand: "b2d.joint.JOINT_TYPE_REVOLUTE" };
524
+ /**
525
+ * Rope joint type.
526
+ */
527
+ const JOINT_TYPE_ROPE: number & { readonly __brand: "b2d.joint.JOINT_TYPE_ROPE" };
528
+ /**
529
+ * Unknown joint type.
530
+ */
531
+ const JOINT_TYPE_UNKNOWN: number & { readonly __brand: "b2d.joint.JOINT_TYPE_UNKNOWN" };
532
+ /**
533
+ * Weld joint type.
534
+ */
535
+ const JOINT_TYPE_WELD: number & { readonly __brand: "b2d.joint.JOINT_TYPE_WELD" };
536
+ /**
537
+ * Wheel joint type.
538
+ */
539
+ const JOINT_TYPE_WHEEL: number & { readonly __brand: "b2d.joint.JOINT_TYPE_WHEEL" };
540
+ /**
541
+ * At lower limit state.
542
+ */
543
+ const LIMIT_STATE_AT_LOWER: number & { readonly __brand: "b2d.joint.LIMIT_STATE_AT_LOWER" };
544
+ /**
545
+ * At upper limit state.
546
+ */
547
+ const LIMIT_STATE_AT_UPPER: number & { readonly __brand: "b2d.joint.LIMIT_STATE_AT_UPPER" };
548
+ /**
549
+ * Equal limits state.
550
+ */
551
+ const LIMIT_STATE_EQUAL: number & { readonly __brand: "b2d.joint.LIMIT_STATE_EQUAL" };
552
+ /**
553
+ * Inactive limit state.
554
+ */
555
+ const LIMIT_STATE_INACTIVE: number & { readonly __brand: "b2d.joint.LIMIT_STATE_INACTIVE" };
556
+ /**
557
+ * Create a distance joint.
558
+ *
559
+ * @param body_a - first body
560
+ * @param body_b - second body
561
+ * @param definition - optional joint definition
562
+ * @returns created joint
563
+ */
564
+ function create_distance(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.distance_definition): Opaque<"b2Joint">;
565
+ /**
566
+ * Create a filter joint.
567
+ *
568
+ * @param body_a - first body
569
+ * @param body_b - second body
570
+ * @param definition - optional definition table
571
+ * @returns created joint
572
+ */
573
+ function create_filter(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.filter_definition): Opaque<"b2Joint">;
574
+ /**
575
+ * Create a friction joint.
576
+ *
577
+ * @param body_a - first body
578
+ * @param body_b - second body
579
+ * @param definition - optional joint definition
580
+ * @returns created joint
581
+ */
582
+ function create_friction(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.friction_definition): Opaque<"b2Joint">;
583
+ /**
584
+ * Create a gear joint.
585
+ *
586
+ * @param joint1 - first revolute or prismatic joint
587
+ * @param joint2 - second revolute or prismatic joint
588
+ * @param definition - optional joint definition
589
+ * @returns created joint
590
+ */
591
+ function create_gear(joint1: Opaque<"b2Joint">, joint2: Opaque<"b2Joint">, definition?: b2d.joint.gear_definition): Opaque<"b2Joint">;
592
+ /**
593
+ * Create a motor joint.
594
+ *
595
+ * @param body_a - first body
596
+ * @param body_b - second body
597
+ * @param definition - optional joint definition
598
+ * @returns created joint
599
+ */
600
+ function create_motor(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.motor_definition): Opaque<"b2Joint">;
601
+ /**
602
+ * Create a mouse joint.
603
+ *
604
+ * @param body_a - first body
605
+ * @param body_b - second body
606
+ * @param definition - optional joint definition
607
+ * @returns created joint
608
+ */
609
+ function create_mouse(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.mouse_definition): Opaque<"b2Joint">;
610
+ /**
611
+ * Create a prismatic joint.
612
+ *
613
+ * @param body_a - first body
614
+ * @param body_b - second body
615
+ * @param definition - optional joint definition
616
+ * @returns created joint
617
+ */
618
+ function create_prismatic(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.prismatic_definition): Opaque<"b2Joint">;
619
+ /**
620
+ * Create a pulley joint.
621
+ *
622
+ * @param body_a - first body
623
+ * @param body_b - second body
624
+ * @param definition - optional joint definition
625
+ * @returns created joint
626
+ */
627
+ function create_pulley(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.pulley_definition): Opaque<"b2Joint">;
628
+ /**
629
+ * Create a revolute joint.
630
+ *
631
+ * @param body_a - first body
632
+ * @param body_b - second body
633
+ * @param definition - optional joint definition
634
+ * @returns created joint
635
+ */
636
+ function create_revolute(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.revolute_definition): Opaque<"b2Joint">;
637
+ /**
638
+ * Create a rope joint.
639
+ *
640
+ * @param body_a - first body
641
+ * @param body_b - second body
642
+ * @param definition - optional joint definition
643
+ * @returns created joint
644
+ */
645
+ function create_rope(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.rope_definition): Opaque<"b2Joint">;
646
+ /**
647
+ * Create a weld joint.
648
+ *
649
+ * @param body_a - first body
650
+ * @param body_b - second body
651
+ * @param definition - optional joint definition
652
+ * @returns created joint
653
+ */
654
+ function create_weld(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.weld_definition): Opaque<"b2Joint">;
655
+ /**
656
+ * Create a wheel joint.
657
+ *
658
+ * @param body_a - first body
659
+ * @param body_b - second body
660
+ * @param definition - optional joint definition
661
+ * @returns created joint
662
+ */
663
+ function create_wheel(body_a: Opaque<"b2Body">, body_b: Opaque<"b2Body">, definition?: b2d.joint.wheel_definition): Opaque<"b2Joint">;
664
+ /**
665
+ * Destroy a joint created by `b2d.joint`.
666
+ *
667
+ * @param joint - joint
668
+ */
669
+ function destroy(joint: Opaque<"b2Joint">): void;
670
+ /**
671
+ * Enable or disable joint limits.
672
+ *
673
+ * @param joint - prismatic or revolute joint
674
+ * @param enable - true to enable limits
675
+ */
676
+ function enable_limit(joint: Opaque<"b2Joint">, enable: boolean): void;
677
+ /**
678
+ * Enable or disable the joint motor.
679
+ *
680
+ * @param joint - prismatic, revolute, or wheel joint
681
+ * @param enable - true to enable the motor
682
+ */
683
+ function enable_motor(joint: Opaque<"b2Joint">, enable: boolean): void;
684
+ /**
685
+ * Enable or disable joint spring behavior.
686
+ *
687
+ * @param joint - distance, prismatic, revolute, or wheel joint
688
+ * @param enable - true to enable the spring
689
+ */
690
+ function enable_spring(joint: Opaque<"b2Joint">, enable: boolean): void;
691
+ /**
692
+ * Get the world anchor on body A.
693
+ *
694
+ * @param joint - joint
695
+ * @returns world anchor
696
+ */
697
+ function get_anchor_a(joint: Opaque<"b2Joint">): Vector3;
698
+ /**
699
+ * Get the world anchor on body B.
700
+ *
701
+ * @param joint - joint
702
+ * @returns world anchor
703
+ */
704
+ function get_anchor_b(joint: Opaque<"b2Joint">): Vector3;
705
+ /**
706
+ * Get weld joint angular damping ratio.
707
+ *
708
+ * @param joint - weld joint
709
+ * @returns damping ratio
710
+ */
711
+ function get_angular_damping_ratio(joint: Opaque<"b2Joint">): number;
712
+ /**
713
+ * Get weld joint angular frequency.
714
+ *
715
+ * @param joint - weld joint
716
+ * @returns frequency in hertz
717
+ */
718
+ function get_angular_hertz(joint: Opaque<"b2Joint">): number;
719
+ /**
720
+ * Get motor joint angular offset.
721
+ *
722
+ * @param joint - motor joint
723
+ * @returns angular offset in radians
724
+ */
725
+ function get_angular_offset(joint: Opaque<"b2Joint">): number;
726
+ /**
727
+ * Get the first body connected to a joint.
728
+ *
729
+ * @param joint - joint
730
+ * @returns body A
731
+ */
732
+ function get_body_a(joint: Opaque<"b2Joint">): Opaque<"b2Body">;
733
+ /**
734
+ * Get the second body connected to a joint.
735
+ *
736
+ * @param joint - joint
737
+ * @returns body B
738
+ */
739
+ function get_body_b(joint: Opaque<"b2Joint">): Opaque<"b2Body">;
740
+ /**
741
+ * Get whether connected bodies can collide.
742
+ *
743
+ * @param joint - joint
744
+ * @returns true if connected bodies can collide
745
+ */
746
+ function get_collide_connected(joint: Opaque<"b2Joint">): boolean;
747
+ /**
748
+ * Get motor joint correction factor.
749
+ *
750
+ * @param joint - motor joint
751
+ * @returns correction factor
752
+ */
753
+ function get_correction_factor(joint: Opaque<"b2Joint">): number;
754
+ /**
755
+ * Get the current distance joint length.
756
+ *
757
+ * @param joint - distance joint
758
+ * @returns current length in project units
759
+ */
760
+ function get_current_length(joint: Opaque<"b2Joint">): number;
761
+ /**
762
+ * Get spring damping ratio.
763
+ *
764
+ * @param joint - distance, mouse, weld, or wheel joint
765
+ * @returns damping ratio
766
+ */
767
+ function get_damping_ratio(joint: Opaque<"b2Joint">): number;
768
+ /**
769
+ * Get spring frequency.
770
+ *
771
+ * @param joint - distance, mouse, weld, or wheel joint
772
+ * @returns frequency in hertz
773
+ */
774
+ function get_frequency(joint: Opaque<"b2Joint">): number;
775
+ /**
776
+ * Get pulley ground anchor A.
777
+ *
778
+ * @param joint - pulley joint
779
+ * @returns world anchor
780
+ */
781
+ function get_ground_anchor_a(joint: Opaque<"b2Joint">): Vector3;
782
+ /**
783
+ * Get pulley ground anchor B.
784
+ *
785
+ * @param joint - pulley joint
786
+ * @returns world anchor
787
+ */
788
+ function get_ground_anchor_b(joint: Opaque<"b2Joint">): Vector3;
789
+ /**
790
+ * Alias for `b2d.joint.get_frequency`.
791
+ *
792
+ * @param joint - distance, mouse, weld, or wheel joint
793
+ * @returns frequency in hertz
794
+ */
795
+ function get_hertz(joint: Opaque<"b2Joint">): number;
796
+ /**
797
+ * Get revolute joint angle.
798
+ *
799
+ * @param joint - revolute joint
800
+ * @returns angle in radians
801
+ */
802
+ function get_joint_angle(joint: Opaque<"b2Joint">): number;
803
+ /**
804
+ * Get joint speed.
805
+ *
806
+ * @param joint - prismatic, revolute, or wheel joint
807
+ * @returns joint speed
808
+ */
809
+ function get_joint_speed(joint: Opaque<"b2Joint">): number;
810
+ /**
811
+ * Get joint translation.
812
+ *
813
+ * @param joint - prismatic or wheel joint
814
+ * @returns translation in project units
815
+ */
816
+ function get_joint_translation(joint: Opaque<"b2Joint">): number;
817
+ /**
818
+ * Get the first joint connected to a gear joint.
819
+ *
820
+ * @param joint - gear joint
821
+ * @returns first connected joint
822
+ */
823
+ function get_joint1(joint: Opaque<"b2Joint">): Opaque<"b2Joint">;
824
+ /**
825
+ * Get the second joint connected to a gear joint.
826
+ *
827
+ * @param joint - gear joint
828
+ * @returns second connected joint
829
+ */
830
+ function get_joint2(joint: Opaque<"b2Joint">): Opaque<"b2Joint">;
831
+ /**
832
+ * Get the distance joint length.
833
+ *
834
+ * @param joint - distance joint
835
+ * @returns length in project units
836
+ */
837
+ function get_length(joint: Opaque<"b2Joint">): number;
838
+ /**
839
+ * Get pulley segment length A.
840
+ *
841
+ * @param joint - pulley joint
842
+ * @returns length in project units
843
+ */
844
+ function get_length_a(joint: Opaque<"b2Joint">): number;
845
+ /**
846
+ * Get pulley segment length B.
847
+ *
848
+ * @param joint - pulley joint
849
+ * @returns length in project units
850
+ */
851
+ function get_length_b(joint: Opaque<"b2Joint">): number;
852
+ /**
853
+ * Get rope limit state.
854
+ *
855
+ * @param joint - rope joint
856
+ * @returns one of the `LIMIT_STATE_*` constants
857
+ */
858
+ function get_limit_state(joint: Opaque<"b2Joint">): b2d.joint.LIMIT_STATE;
859
+ /**
860
+ * Get weld joint linear damping ratio.
861
+ *
862
+ * @param joint - weld joint
863
+ * @returns damping ratio
864
+ */
865
+ function get_linear_damping_ratio(joint: Opaque<"b2Joint">): number;
866
+ /**
867
+ * Get weld joint linear frequency.
868
+ *
869
+ * @param joint - weld joint
870
+ * @returns frequency in hertz
871
+ */
872
+ function get_linear_hertz(joint: Opaque<"b2Joint">): number;
873
+ /**
874
+ * Get motor joint linear offset.
875
+ *
876
+ * @param joint - motor joint
877
+ * @returns linear offset in project units
878
+ */
879
+ function get_linear_offset(joint: Opaque<"b2Joint">): Vector3;
880
+ /**
881
+ * Get the local anchor on body A.
882
+ *
883
+ * @param joint - joint
884
+ * @returns local anchor
885
+ */
886
+ function get_local_anchor_a(joint: Opaque<"b2Joint">): Vector3;
887
+ /**
888
+ * Get the local anchor on body B.
889
+ *
890
+ * @param joint - joint
891
+ * @returns local anchor
892
+ */
893
+ function get_local_anchor_b(joint: Opaque<"b2Joint">): Vector3;
894
+ /**
895
+ * Get the local axis on body A.
896
+ *
897
+ * @param joint - prismatic or wheel joint
898
+ * @returns local axis
899
+ */
900
+ function get_local_axis_a(joint: Opaque<"b2Joint">): Vector3;
901
+ /**
902
+ * Get the lower joint limit.
903
+ *
904
+ * @param joint - prismatic or revolute joint
905
+ * @returns lower limit
906
+ */
907
+ function get_lower_limit(joint: Opaque<"b2Joint">): number;
908
+ /**
909
+ * Get maximum force.
910
+ *
911
+ * @param joint - mouse or friction joint
912
+ * @returns maximum force
913
+ */
914
+ function get_max_force(joint: Opaque<"b2Joint">): number;
915
+ /**
916
+ * Get rope maximum length.
917
+ *
918
+ * @param joint - rope joint
919
+ * @returns maximum length in project units
920
+ */
921
+ function get_max_length(joint: Opaque<"b2Joint">): number;
922
+ /**
923
+ * Get maximum motor force.
924
+ *
925
+ * @param joint - prismatic joint
926
+ * @returns maximum motor force
927
+ */
928
+ function get_max_motor_force(joint: Opaque<"b2Joint">): number;
929
+ /**
930
+ * Get maximum motor torque.
931
+ *
932
+ * @param joint - revolute or wheel joint
933
+ * @returns maximum motor torque
934
+ */
935
+ function get_max_motor_torque(joint: Opaque<"b2Joint">): number;
936
+ /**
937
+ * Get maximum torque.
938
+ *
939
+ * @param joint - friction joint
940
+ * @returns maximum torque
941
+ */
942
+ function get_max_torque(joint: Opaque<"b2Joint">): number;
943
+ /**
944
+ * Get the distance joint minimum length.
945
+ *
946
+ * @param joint - distance joint
947
+ * @returns minimum length in project units
948
+ */
949
+ function get_min_length(joint: Opaque<"b2Joint">): number;
950
+ /**
951
+ * Get current motor force.
952
+ *
953
+ * @param joint - distance or prismatic joint
954
+ * @returns motor force
955
+ */
956
+ function get_motor_force(joint: Opaque<"b2Joint">): number;
957
+ /**
958
+ * Get current motor force.
959
+ *
960
+ * @param joint - prismatic joint
961
+ * @param inv_dt - inverse time step
962
+ * @returns motor force
963
+ */
964
+ function get_motor_force(joint: Opaque<"b2Joint">, inv_dt: number): number;
965
+ /**
966
+ * Get motor speed.
967
+ *
968
+ * @param joint - prismatic, revolute, or wheel joint
969
+ * @returns motor speed
970
+ */
971
+ function get_motor_speed(joint: Opaque<"b2Joint">): number;
972
+ /**
973
+ * Get current motor torque.
974
+ *
975
+ * @param joint - revolute or wheel joint
976
+ * @returns motor torque
977
+ */
978
+ function get_motor_torque(joint: Opaque<"b2Joint">): number;
979
+ /**
980
+ * Get current motor torque.
981
+ *
982
+ * @param joint - revolute or wheel joint
983
+ * @param inv_dt - inverse time step
984
+ * @returns motor torque
985
+ */
986
+ function get_motor_torque(joint: Opaque<"b2Joint">, inv_dt: number): number;
987
+ /**
988
+ * Get the target for a mouse joint.
989
+ *
990
+ * @param joint - mouse joint
991
+ * @returns world target
992
+ */
993
+ function get_mouse_target(joint: Opaque<"b2Joint">): Vector3;
994
+ /**
995
+ * Get joint ratio.
996
+ *
997
+ * @param joint - pulley or gear joint
998
+ * @returns joint ratio
999
+ */
1000
+ function get_ratio(joint: Opaque<"b2Joint">): number;
1001
+ /**
1002
+ * Get reaction force.
1003
+ *
1004
+ * @param joint - joint
1005
+ * @returns reaction force
1006
+ */
1007
+ function get_reaction_force(joint: Opaque<"b2Joint">): Vector3;
1008
+ /**
1009
+ * Get reaction force.
1010
+ *
1011
+ * @param joint - joint
1012
+ * @param inv_dt - inverse time step
1013
+ * @returns reaction force
1014
+ */
1015
+ function get_reaction_force(joint: Opaque<"b2Joint">, inv_dt: number): Vector3;
1016
+ /**
1017
+ * Get reaction torque.
1018
+ *
1019
+ * @param joint - joint
1020
+ * @returns reaction torque
1021
+ */
1022
+ function get_reaction_torque(joint: Opaque<"b2Joint">): number;
1023
+ /**
1024
+ * Get reaction torque.
1025
+ *
1026
+ * @param joint - joint
1027
+ * @param inv_dt - inverse time step
1028
+ * @returns reaction torque
1029
+ */
1030
+ function get_reaction_torque(joint: Opaque<"b2Joint">, inv_dt: number): number;
1031
+ /**
1032
+ * Get the reference angle.
1033
+ *
1034
+ * @param joint - prismatic, revolute, or weld joint
1035
+ * @returns reference angle in radians
1036
+ */
1037
+ function get_reference_angle(joint: Opaque<"b2Joint">): number;
1038
+ /**
1039
+ * Alias for `b2d.joint.get_damping_ratio`.
1040
+ *
1041
+ * @param joint - distance, mouse, weld, or wheel joint
1042
+ * @returns damping ratio
1043
+ */
1044
+ function get_spring_damping_ratio(joint: Opaque<"b2Joint">): number;
1045
+ /**
1046
+ * Get spring frequency.
1047
+ *
1048
+ * @param joint - distance, mouse, prismatic, revolute, or wheel joint
1049
+ * @returns frequency in hertz
1050
+ */
1051
+ function get_spring_hertz(joint: Opaque<"b2Joint">): number;
1052
+ /**
1053
+ * Get the joint type.
1054
+ *
1055
+ * @param joint - joint
1056
+ * @returns one of the `JOINT_TYPE_*` constants
1057
+ */
1058
+ function get_type(joint: Opaque<"b2Joint">): b2d.joint.JOINT_TYPE;
1059
+ /**
1060
+ * Get the upper joint limit.
1061
+ *
1062
+ * @param joint - prismatic or revolute joint
1063
+ * @returns upper limit
1064
+ */
1065
+ function get_upper_limit(joint: Opaque<"b2Joint">): number;
1066
+ /**
1067
+ * Get the world owning a joint.
1068
+ *
1069
+ * @param joint - joint
1070
+ * @returns owning world
1071
+ */
1072
+ function get_world(joint: Opaque<"b2Joint">): Opaque<"b2World">;
1073
+ /**
1074
+ * Get whether the joint is active.
1075
+ *
1076
+ * @param joint - joint
1077
+ * @returns true if the joint is active
1078
+ */
1079
+ function is_active(joint: Opaque<"b2Joint">): boolean;
1080
+ /**
1081
+ * Get whether joint limits are enabled.
1082
+ *
1083
+ * @param joint - prismatic or revolute joint
1084
+ * @returns true if limits are enabled
1085
+ */
1086
+ function is_limit_enabled(joint: Opaque<"b2Joint">): boolean;
1087
+ /**
1088
+ * Get whether the joint motor is enabled.
1089
+ *
1090
+ * @param joint - prismatic, revolute, or wheel joint
1091
+ * @returns true if the motor is enabled
1092
+ */
1093
+ function is_motor_enabled(joint: Opaque<"b2Joint">): boolean;
1094
+ /**
1095
+ * Get whether joint spring behavior is enabled.
1096
+ *
1097
+ * @param joint - distance, prismatic, revolute, or wheel joint
1098
+ * @returns true if the spring is enabled
1099
+ */
1100
+ function is_spring_enabled(joint: Opaque<"b2Joint">): boolean;
1101
+ /**
1102
+ * Validate a joint handle.
1103
+ *
1104
+ * @param joint - joint
1105
+ * @returns true if the joint handle still refers to a live Box2D joint
1106
+ */
1107
+ function is_valid(joint: Opaque<"b2Joint">): boolean;
1108
+ /**
1109
+ * Set weld joint angular damping ratio.
1110
+ *
1111
+ * @param joint - weld joint
1112
+ * @param ratio - damping ratio
1113
+ */
1114
+ function set_angular_damping_ratio(joint: Opaque<"b2Joint">, ratio: number): void;
1115
+ /**
1116
+ * Set weld joint angular frequency.
1117
+ *
1118
+ * @param joint - weld joint
1119
+ * @param hertz - frequency in hertz
1120
+ */
1121
+ function set_angular_hertz(joint: Opaque<"b2Joint">, hertz: number): void;
1122
+ /**
1123
+ * Set motor joint angular offset.
1124
+ *
1125
+ * @param joint - motor joint
1126
+ * @param offset - angular offset in radians
1127
+ */
1128
+ function set_angular_offset(joint: Opaque<"b2Joint">, offset: number): void;
1129
+ /**
1130
+ * Set whether connected bodies can collide.
1131
+ *
1132
+ * @param joint - joint
1133
+ * @param collide - true if connected bodies can collide
1134
+ */
1135
+ function set_collide_connected(joint: Opaque<"b2Joint">, collide: boolean): void;
1136
+ /**
1137
+ * Set motor joint correction factor.
1138
+ *
1139
+ * @param joint - motor joint
1140
+ * @param factor - correction factor
1141
+ */
1142
+ function set_correction_factor(joint: Opaque<"b2Joint">, factor: number): void;
1143
+ /**
1144
+ * Set spring damping ratio.
1145
+ *
1146
+ * @param joint - distance, mouse, weld, or wheel joint
1147
+ * @param ratio - damping ratio
1148
+ */
1149
+ function set_damping_ratio(joint: Opaque<"b2Joint">, ratio: number): void;
1150
+ /**
1151
+ * Set spring frequency.
1152
+ *
1153
+ * @param joint - distance, mouse, weld, or wheel joint
1154
+ * @param frequency - frequency in hertz
1155
+ */
1156
+ function set_frequency(joint: Opaque<"b2Joint">, frequency: number): void;
1157
+ /**
1158
+ * Alias for `b2d.joint.set_frequency`.
1159
+ *
1160
+ * @param joint - distance, mouse, weld, or wheel joint
1161
+ * @param hertz - frequency in hertz
1162
+ */
1163
+ function set_hertz(joint: Opaque<"b2Joint">, hertz: number): void;
1164
+ /**
1165
+ * Set the distance joint length.
1166
+ *
1167
+ * @param joint - distance joint
1168
+ * @param length - length in project units
1169
+ */
1170
+ function set_length(joint: Opaque<"b2Joint">, length: number): void;
1171
+ /**
1172
+ * Set the distance joint length range.
1173
+ *
1174
+ * @param joint - distance joint
1175
+ * @param min_length - minimum length in project units
1176
+ * @param max_length - maximum length in project units
1177
+ */
1178
+ function set_length_range(joint: Opaque<"b2Joint">, min_length: number, max_length: number): void;
1179
+ /**
1180
+ * Set joint limits.
1181
+ *
1182
+ * @param joint - prismatic or revolute joint
1183
+ * @param lower - lower limit
1184
+ * @param upper - upper limit
1185
+ */
1186
+ function set_limits(joint: Opaque<"b2Joint">, lower: number, upper: number): void;
1187
+ /**
1188
+ * Set weld joint linear damping ratio.
1189
+ *
1190
+ * @param joint - weld joint
1191
+ * @param ratio - damping ratio
1192
+ */
1193
+ function set_linear_damping_ratio(joint: Opaque<"b2Joint">, ratio: number): void;
1194
+ /**
1195
+ * Set weld joint linear frequency.
1196
+ *
1197
+ * @param joint - weld joint
1198
+ * @param hertz - frequency in hertz
1199
+ */
1200
+ function set_linear_hertz(joint: Opaque<"b2Joint">, hertz: number): void;
1201
+ /**
1202
+ * Set motor joint linear offset.
1203
+ *
1204
+ * @param joint - motor joint
1205
+ * @param offset - linear offset in project units
1206
+ */
1207
+ function set_linear_offset(joint: Opaque<"b2Joint">, offset: Vector3): void;
1208
+ /**
1209
+ * Set maximum force.
1210
+ *
1211
+ * @param joint - mouse or friction joint
1212
+ * @param force - maximum force
1213
+ */
1214
+ function set_max_force(joint: Opaque<"b2Joint">, force: number): void;
1215
+ /**
1216
+ * Set rope maximum length.
1217
+ *
1218
+ * @param joint - rope joint
1219
+ * @param length - maximum length in project units
1220
+ */
1221
+ function set_max_length(joint: Opaque<"b2Joint">, length: number): void;
1222
+ /**
1223
+ * Set maximum motor force.
1224
+ *
1225
+ * @param joint - prismatic joint
1226
+ * @param force - maximum motor force
1227
+ */
1228
+ function set_max_motor_force(joint: Opaque<"b2Joint">, force: number): void;
1229
+ /**
1230
+ * Set maximum motor torque.
1231
+ *
1232
+ * @param joint - revolute or wheel joint
1233
+ * @param torque - maximum motor torque
1234
+ */
1235
+ function set_max_motor_torque(joint: Opaque<"b2Joint">, torque: number): void;
1236
+ /**
1237
+ * Set maximum torque.
1238
+ *
1239
+ * @param joint - friction joint
1240
+ * @param torque - maximum torque
1241
+ */
1242
+ function set_max_torque(joint: Opaque<"b2Joint">, torque: number): void;
1243
+ /**
1244
+ * Set the distance joint minimum length.
1245
+ *
1246
+ * @param joint - distance joint
1247
+ * @param length - minimum length in project units
1248
+ */
1249
+ function set_min_length(joint: Opaque<"b2Joint">, length: number): void;
1250
+ /**
1251
+ * Set motor speed.
1252
+ *
1253
+ * @param joint - prismatic, revolute, or wheel joint
1254
+ * @param speed - motor speed
1255
+ */
1256
+ function set_motor_speed(joint: Opaque<"b2Joint">, speed: number): void;
1257
+ /**
1258
+ * Set the target for a mouse joint.
1259
+ *
1260
+ * @param joint - mouse joint
1261
+ * @param target - world target
1262
+ */
1263
+ function set_mouse_target(joint: Opaque<"b2Joint">, target: Vector3): void;
1264
+ /**
1265
+ * Set gear joint ratio.
1266
+ *
1267
+ * @param joint - gear joint
1268
+ * @param ratio - gear ratio
1269
+ */
1270
+ function set_ratio(joint: Opaque<"b2Joint">, ratio: number): void;
1271
+ /**
1272
+ * Set weld joint reference angle.
1273
+ *
1274
+ * @param joint - weld joint
1275
+ * @param angle - reference angle in radians
1276
+ */
1277
+ function set_reference_angle(joint: Opaque<"b2Joint">, angle: number): void;
1278
+ /**
1279
+ * Alias for `b2d.joint.set_damping_ratio`.
1280
+ *
1281
+ * @param joint - distance, mouse, weld, or wheel joint
1282
+ * @param ratio - damping ratio
1283
+ */
1284
+ function set_spring_damping_ratio(joint: Opaque<"b2Joint">, ratio: number): void;
1285
+ /**
1286
+ * Set spring frequency.
1287
+ *
1288
+ * @param joint - distance, mouse, prismatic, revolute, or wheel joint
1289
+ * @param hertz - frequency in hertz
1290
+ */
1291
+ function set_spring_hertz(joint: Opaque<"b2Joint">, hertz: number): void;
1292
+ /**
1293
+ * Wake the bodies connected to a joint.
1294
+ *
1295
+ * @param joint - joint
1296
+ */
1297
+ function wake_bodies(joint: Opaque<"b2Joint">): void;
1298
+ }
1299
+ }
1300
+
1301
+ export {};