#include <NxDestructibleAsset.h>
Public Types | |
| enum | Enum { ACCUMULATE_DAMAGE = (1 << 0), DEBRIS_TIMEOUT = (1 << 1), DEBRIS_MAX_SEPARATION = (1 << 2), CRUMBLE_SMALLEST_CHUNKS = (1 << 3), ACCURATE_RAYCASTS = (1 << 4), USE_VALID_BOUNDS = (1 << 5), CRUMBLE_VIA_RUNTIME_FRACTURE = (1 << 6) } |
Flags that apply to a destructible actor, settable at runtime
| ACCUMULATE_DAMAGE |
If set, chunks will "remember" damage applied to them, so that many applications of a damage amount below damageThreshold will eventually fracture the chunk. If not set, a single application of damage must exceed damageThreshold in order to fracture the chunk. |
| DEBRIS_TIMEOUT |
Whether or not chunks at or deeper than the "debris" depth (see NxDestructibleParameters::debrisDepth) will time out. The lifetime is a value between NxDestructibleParameters::debrisLifetimeMin and NxDestructibleParameters::debrisLifetimeMax, based upon the destructible module's LOD setting. |
| DEBRIS_MAX_SEPARATION |
Whether or not chunks at or deeper than the "debris" depth (see NxDestructibleParameters::debrisDepth) will be removed if they separate too far from their origins. The maxSeparation is a value between NxDestructibleParameters::debrisMaxSeparationMin and NxDestructibleParameters::debrisMaxSeparationMax, based upon the destructible module's LOD setting. |
| CRUMBLE_SMALLEST_CHUNKS |
If set, the smallest chunks may be further broken down, either by fluid crumbles (if a crumble particle system is specified in the NxDestructibleActorDesc), or by simply removing the chunk if no crumble particle system is specified. Note: the "smallest chunks" are normally defined to be the deepest level of the fracture hierarchy. However, they may be taken from higher levels of the hierarchy if NxModuleDestructible::setMaxChunkDepthOffset is called with a non-zero value. |
| ACCURATE_RAYCASTS |
If set, the NxDestructibleActor::rayCast function will search within the nearest visible chunk hit for collisions with child chunks. This is used to get a better raycast position and normal, in case the parent collision volume does not tightly fit the graphics mesh. The returned chunk index will always be that of the visible parent that is intersected, however. |
| USE_VALID_BOUNDS |
If set, the validBounds field of NxDestructibleParameters will be used. These bounds are translated (but not scaled or rotated) to the origin of the destructible actor. If a chunk or chunk island moves outside of those bounds, it is destroyed. |
| CRUMBLE_VIA_RUNTIME_FRACTURE |
If set, chunk crumbling will be handled via the pattern-based runtime fracture pipeline. If no fracture pattern is specified in the NxDestructibleActorDesc, or no fracture pattern has been assigned to the destructible actor, chunks will simply be removed. |