Drag[en]gine Script Module DragonScript
1.23
|
Collision information. More...
Public Member Functions | |
Management | |
int | getOwnerBone () |
Owner bone or -1 if not applicable. More... | |
int | getOwnerShape () |
Owner shape or -1 if not applicable. More... | |
int | getOwnerFace () |
Owner face or -1 if not applicable. More... | |
Collider | getCollider () |
Ccollider or null if hit something else. More... | |
int | getBone () |
Collider bone or -1 if hit something else. More... | |
int | getShape () |
Collider rig (bone) shape or -1 if hit something else. More... | |
int | getFace () |
Collider bone or -1 if hit something else. More... | |
bool | hasCollision () |
Collision has occurred. More... | |
bool | isCollider () |
Collision with collider occurred,. More... | |
bool | hasBone () |
Collision with collider bone occurred. More... | |
bool | hasShape () |
Collision with collider rig (bone) shape occurred. More... | |
bool | hasFace () |
Collision with collider face occurred. More... | |
float | getParticleLifetime () |
Particle lifetime. More... | |
float | getParticleMass () |
Particle mass. More... | |
DVector | getParticlePosition () |
Particle position. More... | |
void | setParticlePosition (DVector position) |
Set particle position. More... | |
Vector | getParticleVelocity () |
Particle velocity. More... | |
void | setParticleVelocity (Vector velocity) |
Set particle velocity. More... | |
ParticleCollisionResponse | getParticleResponse () |
Collision response to apply to particle. More... | |
void | setParticleResponse (ParticleCollisionResponse respone) |
Set collision response to apply to particle. More... | |
float | getDistance () |
Distance relative to displacement vector resulting in collision. More... | |
Vector | getNormal () |
Hit normal at collision point. More... | |
DVector | getPosition () |
Hit position. More... | |
float | getImpulse () |
Hit impulse. More... | |
bool | getStopTesting () |
Collision detection has to stop. More... | |
void | setStopTesting (bool stopTesting) |
Set if collision detection has to stop. More... | |
Collision information.
This is a native class.
int Dragengine.Scenery.CollisionInfo.getBone | ( | ) |
Collider bone or -1 if hit something else.
Collider Dragengine.Scenery.CollisionInfo.getCollider | ( | ) |
Ccollider or null if hit something else.
float Dragengine.Scenery.CollisionInfo.getDistance | ( | ) |
Distance relative to displacement vector resulting in collision.
int Dragengine.Scenery.CollisionInfo.getFace | ( | ) |
Collider bone or -1 if hit something else.
float Dragengine.Scenery.CollisionInfo.getImpulse | ( | ) |
Hit impulse.
Set by the physics module for dynamic collision response to a reasonable hit impulse relative between both collision objects.
Vector Dragengine.Scenery.CollisionInfo.getNormal | ( | ) |
Hit normal at collision point.
Depending on the geometry involved in the collision a single optimal hit normal can not be defined. In this case the physics module sets a reasonable hit normal. Hit normals are well defined with ray casts.
int Dragengine.Scenery.CollisionInfo.getOwnerBone | ( | ) |
Owner bone or -1 if not applicable.
int Dragengine.Scenery.CollisionInfo.getOwnerFace | ( | ) |
Owner face or -1 if not applicable.
int Dragengine.Scenery.CollisionInfo.getOwnerShape | ( | ) |
Owner shape or -1 if not applicable.
float Dragengine.Scenery.CollisionInfo.getParticleLifetime | ( | ) |
Particle lifetime.
float Dragengine.Scenery.CollisionInfo.getParticleMass | ( | ) |
Particle mass.
DVector Dragengine.Scenery.CollisionInfo.getParticlePosition | ( | ) |
Particle position.
ParticleCollisionResponse Dragengine.Scenery.CollisionInfo.getParticleResponse | ( | ) |
Collision response to apply to particle.
Vector Dragengine.Scenery.CollisionInfo.getParticleVelocity | ( | ) |
Particle velocity.
DVector Dragengine.Scenery.CollisionInfo.getPosition | ( | ) |
Hit position.
Set by the physics module for dynamic collision response indicating a reasonable hit position in world space. A typical use is to play a sound or emit particles at this location.
int Dragengine.Scenery.CollisionInfo.getShape | ( | ) |
Collider rig (bone) shape or -1 if hit something else.
bool Dragengine.Scenery.CollisionInfo.getStopTesting | ( | ) |
Collision detection has to stop.
bool Dragengine.Scenery.CollisionInfo.hasBone | ( | ) |
Collision with collider bone occurred.
bool Dragengine.Scenery.CollisionInfo.hasCollision | ( | ) |
Collision has occurred.
bool Dragengine.Scenery.CollisionInfo.hasFace | ( | ) |
Collision with collider face occurred.
bool Dragengine.Scenery.CollisionInfo.hasShape | ( | ) |
Collision with collider rig (bone) shape occurred.
bool Dragengine.Scenery.CollisionInfo.isCollider | ( | ) |
Collision with collider occurred,.
void Dragengine.Scenery.CollisionInfo.setParticlePosition | ( | DVector | position | ) |
Set particle position.
void Dragengine.Scenery.CollisionInfo.setParticleResponse | ( | ParticleCollisionResponse | respone | ) |
Set collision response to apply to particle.
void Dragengine.Scenery.CollisionInfo.setParticleVelocity | ( | Vector | velocity | ) |
Set particle velocity.
void Dragengine.Scenery.CollisionInfo.setStopTesting | ( | bool | stopTesting | ) |
Set if collision detection has to stop.