CLASS v1.8.0

physics.WeldJoint

pykraken.physics.WeldJoint

A joint that rigidly connects two bodies at an anchor point.

More about physics.WeldJoint

The weld joint attempts to keep the bodies at a fixed relative position and angle. Optionally supports linear and angular springs to allow some flex. Useful for breakable structures or soft connections between bodies.

Inherits Joint

Reference

PYTHON API
physics.WeldJoint(/, *args, **kwargs)

Initialize self. See help(type(self)) for accurate signature.

angular_damping_ratio: float

The angular spring damping ratio.

angular_hz

property
angular_hz: float

The angular spring frequency in Hertz.

body_a

property
body_a: physics.Body

The first body attached to the joint.

body_b

property
body_b: physics.Body

The second body attached to the joint.

collide_connected: bool

Whether the connected bodies should collide with each other.

is_valid

property
is_valid: bool

Indicates whether the joint is not destroyed.

linear_damping_ratio: float

The linear spring damping ratio.

linear_hz

property
linear_hz: float

The linear spring frequency in Hertz.

local_anchor_a: Vec2

The local anchor point relative to body A's origin.

local_anchor_b: Vec2

The local anchor point relative to body B's origin.

destroy

method
destroy(self) -> None

Destroy the joint manually.

Find your next step

Start typing to search the manual.