logo
pub struct Velocity { /* private fields */ }
Expand description

Velocity component.

Use to move and rotate entities (without physics).

Implementations

Returns a ValueAccessor for the world-space linear velocity of the entity.

Used to set/get/animate the velocity. This only works if physics has not been enabled for the entity.

Returns a ValueAccessor for the world-space angular velocity of the entity

This is an angular velocity as a pseudovector, with its magnitude measuring the rate at which an object rotates or revolves (in radians per seconds), and its direction pointing perpendicular to the instantaneous plane of rotation or angular displacement.

Used to set/get/animate the velocity. This only works if physics has not been enabled for the entity.

Trait Implementations

The type of the component, as a ComponentType enum.

Adopt an Entity, wrap in a component struct.

Get the entity that the component belongs to.

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.