Modifier and Type | Field and Description |
---|---|
static double |
GRAVITY_EARTH
Gravity of Earth (in m/s²).
|
static double |
GRAVITY_MARS
Gravity of Mars (in m/s²).
|
static double |
GRAVITY_MOON
Gravity of the Moon (in m/s²).
|
Modifier and Type | Method and Description |
---|---|
double |
getMass()
Get body mass.
|
double |
getWeight()
Get body weight (mass * gravity).
|
void |
resetGravity()
Reset current gravity force (usually when hit the ground).
|
void |
setDesiredFps(int desiredFps)
Set the desired fps.
|
void |
setGravity(double gravity)
Set the gravity to use.
|
void |
setGravityMax(double max)
Set the maximum gravity value.
|
void |
setMass(double mass)
Set body mass.
|
void |
setVectors(Direction... vectors)
Set forces involved in gravity and movement.
|
static final double GRAVITY_EARTH
static final double GRAVITY_MARS
static final double GRAVITY_MOON
void resetGravity()
void setVectors(Direction... vectors)
vectors
- The vectors list.void setDesiredFps(int desiredFps)
desiredFps
- The desired fps.void setGravity(double gravity)
GRAVITY_EARTH
is used by default.gravity
- The gravity to use (in m/s²).void setGravityMax(double max)
max
- The maximum gravity value.void setMass(double mass)
mass
- The body mass.double getMass()
double getWeight()
Copyright © 2016 Byron 3D Games Studio. All rights reserved.