Class SplineCollider
A collider represented by an arbitrary mesh that goes over the spline.
Inherited Members
Assembly: FlaxEngine.dll
File: Engine/Physics/Colliders/SplineCollider.h
Syntax
public class SplineCollider : public Collider
Fields
CollisionData
Linked collision data asset that contains convex mesh or triangle mesh used to represent a spline collider shape.
Declaration
public AssetReference<CollisionData> CollisionData
Field Value
AssetReference<CollisionData>
|
Methods
CanAttach(RigidBody* rigidBody)
Determines whether this collider can be attached the specified rigid body.
Declaration
public virtual bool CanAttach(RigidBody* rigidBody) const override
Parameters
RigidBody
rigidBody
The rigid body. |
Returns
bool
|
Overrides
CanBeTrigger()
Determines whether this collider can be a trigger shape.
Declaration
public virtual bool CanBeTrigger() const override
Returns
bool
|
Overrides
DrawPhysicsDebug(RenderView& view)
Declaration
protected virtual void DrawPhysicsDebug(RenderView& view) override
Parameters
RenderView
view
|
Overrides
EndPlay()
Called when removing object from the game.
Declaration
public virtual void EndPlay() override
Overrides
ExtractGeometry(Array<Float3>& vertexBuffer, Array<int32>& indexBuffer)
Extracts the collision data geometry into list of triangles.
Declaration
public void ExtractGeometry(Array<Float3>& vertexBuffer, Array<int32>& indexBuffer) const
Parameters
Array<Float3>
vertexBuffer
The output vertex buffer. |
Array<int32>
indexBuffer
The output index buffer. |
GetGeometry(CollisionShape& collision)
Gets the collider shape geometry.
Declaration
protected virtual void GetGeometry(CollisionShape& collision) override
Parameters
CollisionShape
collision
The output collision shape. |
Overrides
GetPreTransform()
Gets the transformation applied to the collision data model geometry before placing it over the spline. Can be used to change the way model goes over the spline.
Declaration
public Transform GetPreTransform() const
Returns
Transform
|
IntersectsItself(const Ray& ray, Real& distance, Vector3& normal)
Determines if there is an intersection between the current object and a ray.
Declaration
public virtual bool IntersectsItself(const Ray& ray, Real& distance, Vector3& normal) override
Parameters
Ray
ray
The ray to test. |
Real
distance
When the method completes, contains the distance of the intersection (if any valid). |
Vector3
normal
When the method completes, contains the intersection surface normal vector (if any valid). |
Returns
bool
True whether the two objects intersected, otherwise false. |
Overrides
OnDebugDrawSelected()
Draws debug shapes for the selected actor and all child scripts.
Declaration
public virtual void OnDebugDrawSelected() override
Overrides
OnParentChanged()
Called when actor parent gets changed.
Declaration
public virtual void OnParentChanged() override
Overrides
SetPreTransform(const Transform& value)
Sets the transformation applied to the collision data model geometry before placing it over the spline. Can be used to change the way model goes over the spline.
Declaration
public void SetPreTransform(const Transform& value)
Parameters
Transform
value
|
UpdateBounds()
Updates the bounding box of the shape.
Declaration
protected virtual void UpdateBounds() override