Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
ProceduralFairings.ColliderChunk Class Reference

Public Member Functions

 ColliderChunk (MeshArc bottom, MeshArc top, int nSidesTotal, int nArcs, int nColliders, int subdivIdx)
 
MeshCollider CreateColliderGO (GameObject parent, string name, int layer)
 
Mesh GenerateColliderMesh (bool triangulate, Vector3 offset)
 

Public Attributes

MeshCollider collider
 

Protected Member Functions

void TriangulateColliderMesh (MeshPoint[] pts, List< int > tris)
 

Constructor & Destructor Documentation

ProceduralFairings.ColliderChunk.ColliderChunk ( MeshArc  bottom,
MeshArc  top,
int  nSidesTotal,
int  nArcs,
int  nColliders,
int  subdivIdx 
)
inline

< if there isn't enough left to subtend another arc, extend to the last edge

< add an extra edge, because nsides refers to faces, so edges+1

< two outer sub-arcs, plus 4 inner corners

Member Function Documentation

MeshCollider ProceduralFairings.ColliderChunk.CreateColliderGO ( GameObject  parent,
string  name,
int  layer 
)
inline
Mesh ProceduralFairings.ColliderChunk.GenerateColliderMesh ( bool  triangulate,
Vector3  offset 
)
inline
void ProceduralFairings.ColliderChunk.TriangulateColliderMesh ( MeshPoint[]  pts,
List< int >  tris 
)
inlineprotected

< triangulate side panels

< hopefully we shouldn't need to triangulate the top and bottom faces, given this is supposed to be a convex mesh

Member Data Documentation

MeshCollider ProceduralFairings.ColliderChunk.collider

The documentation for this class was generated from the following file: