|
469 | 469 | Returns the [RID] of the shape with the given index in the body's array of shapes.
|
470 | 470 | </description>
|
471 | 471 | </method>
|
| 472 | + <method name="body_get_shape_bounce_override" qualifiers="const"> |
| 473 | + <return type="float" /> |
| 474 | + <param index="0" name="body" type="RID" /> |
| 475 | + <param index="1" name="shape_idx" type="int" /> |
| 476 | + <description> |
| 477 | + Returns the bounciness override for the shape or [constant @GDScript.NAN] if no override is set. |
| 478 | + </description> |
| 479 | + </method> |
472 | 480 | <method name="body_get_shape_count" qualifiers="const">
|
473 | 481 | <return type="int" />
|
474 | 482 | <param index="0" name="body" type="RID" />
|
475 | 483 | <description>
|
476 | 484 | Returns the number of shapes added to the body.
|
477 | 485 | </description>
|
478 | 486 | </method>
|
| 487 | + <method name="body_get_shape_friction_override" qualifiers="const"> |
| 488 | + <return type="float" /> |
| 489 | + <param index="0" name="body" type="RID" /> |
| 490 | + <param index="1" name="shape_idx" type="int" /> |
| 491 | + <description> |
| 492 | + Returns the friction override for the shape or [constant @GDScript.NAN] if no override is set. |
| 493 | + </description> |
| 494 | + </method> |
479 | 495 | <method name="body_get_shape_transform" qualifiers="const">
|
480 | 496 | <return type="Transform2D" />
|
481 | 497 | <param index="0" name="body" type="RID" />
|
|
655 | 671 | Sets the one-way collision properties of the body's shape with the given index. If [param enable] is [code]true[/code], the one-way collision direction given by the shape's local upward axis [code]body_get_shape_transform(body, shape_idx).y[/code] will be used to ignore collisions with the shape in the opposite direction, and to ensure depenetration of kinematic bodies happens in this direction.
|
656 | 672 | </description>
|
657 | 673 | </method>
|
| 674 | + <method name="body_set_shape_bounce_override"> |
| 675 | + <return type="void" /> |
| 676 | + <param index="0" name="body" type="RID" /> |
| 677 | + <param index="1" name="shape_idx" type="int" /> |
| 678 | + <param index="2" name="enable" type="bool" /> |
| 679 | + <param index="3" name="bounce" type="float" default="0.0" /> |
| 680 | + <description> |
| 681 | + Sets the bounce for the shape if [param enable] is [code]true[/code], resets to the body's value if [code]false[/code]. A negative value of [param bounce] is equivalent to enabling [member PhysicsMaterial.absorbent]. |
| 682 | + </description> |
| 683 | + </method> |
658 | 684 | <method name="body_set_shape_disabled">
|
659 | 685 | <return type="void" />
|
660 | 686 | <param index="0" name="body" type="RID" />
|
|
664 | 690 | Sets the disabled property of the body's shape with the given index. If [param disabled] is [code]true[/code], then the shape will be ignored in all collision detection.
|
665 | 691 | </description>
|
666 | 692 | </method>
|
| 693 | + <method name="body_set_shape_friction_override"> |
| 694 | + <return type="void" /> |
| 695 | + <param index="0" name="body" type="RID" /> |
| 696 | + <param index="1" name="shape_idx" type="int" /> |
| 697 | + <param index="2" name="enable" type="bool" /> |
| 698 | + <param index="3" name="friction" type="float" default="0.0" /> |
| 699 | + <description> |
| 700 | + Sets the friction for the shape if [param enable] is [code]true[/code], resets to the body's value if [code]false[/code]. A negative value of [param friction] is equivalent to enabling [member PhysicsMaterial.rough]. |
| 701 | + </description> |
| 702 | + </method> |
667 | 703 | <method name="body_set_shape_transform">
|
668 | 704 | <return type="void" />
|
669 | 705 | <param index="0" name="body" type="RID" />
|
|
0 commit comments