i6engine  1.0
i6e::modules::PhysicsVelocityComponent Class Reference

Handles calculation of air friction. More...

#include <D:/Projekte/i6engine/libs/i6engine-modules/include/i6engine/modules/physics/PhysicsVelocityComponent.h>

Public Member Functions

 PhysicsVelocityComponent (PhysicsNode *node, double mass, double maxSpeed, double resistanceCoefficient, double windage)
 
void accelerate (const Vec3 &acceleration, api::VelocityComponent::MaxSpeedHandling handling, const std::function< void(void)> &callback)
 
void decelerate (const Vec3 &deceleration, api::VelocityComponent::DecelerationHandling handling, const std::function< void(void)> &callback)
 
void stopAcceleration ()
 
void setMaxSpeed (double maxSpeed)
 
void setResistanceCoefficient (double resistanceCoefficient)
 
void setWindage (double windage)
 
void Tick ()
 

Detailed Description

Handles calculation of air friction.

Definition at line 41 of file PhysicsVelocityComponent.h.

Constructor & Destructor Documentation

i6e::modules::PhysicsVelocityComponent::PhysicsVelocityComponent ( PhysicsNode node,
double  mass,
double  maxSpeed,
double  resistanceCoefficient,
double  windage 
)

Member Function Documentation

void i6e::modules::PhysicsVelocityComponent::accelerate ( const Vec3 acceleration,
api::VelocityComponent::MaxSpeedHandling  handling,
const std::function< void(void)> &  callback 
)
void i6e::modules::PhysicsVelocityComponent::decelerate ( const Vec3 deceleration,
api::VelocityComponent::DecelerationHandling  handling,
const std::function< void(void)> &  callback 
)
void i6e::modules::PhysicsVelocityComponent::setMaxSpeed ( double  maxSpeed)
inline

Definition at line 51 of file PhysicsVelocityComponent.h.

void i6e::modules::PhysicsVelocityComponent::setResistanceCoefficient ( double  resistanceCoefficient)
inline

Definition at line 55 of file PhysicsVelocityComponent.h.

void i6e::modules::PhysicsVelocityComponent::setWindage ( double  windage)
inline

Definition at line 59 of file PhysicsVelocityComponent.h.

void i6e::modules::PhysicsVelocityComponent::stopAcceleration ( )
void i6e::modules::PhysicsVelocityComponent::Tick ( )

The documentation for this class was generated from the following file: