MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / OnSplineUpdated

Method OnSplineUpdated

Source/Engine/Physics/Colliders/SplineCollider.cpp:61–71  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59}
60
61void SplineCollider::OnSplineUpdated()
62{
63 if (!_spline || !IsActiveInHierarchy() || _spline->GetSplinePointsCount() < 2 || !CollisionData || !CollisionData->IsLoaded())
64 {
65 _box = BoundingBox(_transform.Translation);
66 BoundingSphere::FromBox(_box, _sphere);
67 return;
68 }
69
70 UpdateGeometry();
71}
72
73bool SplineCollider::CanAttach(RigidBody* rigidBody) const
74{

Callers

nothing calls this directly

Calls 4

IsActiveInHierarchyFunction · 0.85
GetSplinePointsCountMethod · 0.80
BoundingBoxClass · 0.50
IsLoadedMethod · 0.45

Tested by

no test coverage detected