Document toolboxDocument toolbox

2022.1.1551.1 ConvexConusGenerator



Overview

Creates an Conus/Cylinder of given radii and rotation on an game object.


Where to find

The feature can be found under Utility > Mesh Tools > Create Shape.

And the mono behavior variant can be found under Mechanics > Collider Generators > Conus Generator or by clicking on game object going to Add Component and adding a Conus Collider Generator.


Feature Layout

Will only describe Cylinder window.

 

Shape Type

Type of shape given to game objects.

  • Ellipse: Creates a ellipse of given radii for object.

  • Cube: Creates cube.

  • Cylinder: Creates cylinder.

Center

Center of the created cylinder in world space.

Local Up Direction

The direction the local up is in (in this direction the y radius will be drawn).

Tessellation

Amount the cylinder is tessellated.

Radius

Radius of the cylinder in units.

Height

Height of the cylinder in units.

Create Shape

Button to press to add shape to selected game objects

Make Normals for Mesh

When checked the normals of created mesh are calculated (generated by unity if unchecked).

Inverse Normals Top Bottom Mesh

When checked will inverse the calculated normals of bottom and top cap of cylinder.

Inverse Normals Side Mesh

When checked will inverse the calculated normals of side of cylinder.

Edit Conus Shape

When checked allows you to edit the conus in the scene view.

Tessellation (# of sides)

Amount the conus is tessellated.

Scene Line Color

The line color of top and bottom caps of conus drawn in scene.

Scene Label Color

The label color of top and bottom control points drawn in scene.

Scaling Tool

The method to set to cap of the conus.

  • Points: Using 3 points in space per cap.

  • Circle: Setting centre and radius of cap.

Point 0:

First control point of bottom cap.

Point 1:

Second control point of bottom cap.

Point 2:

Third control point of bottom cap.

Point 3:

First control point of top cap.

Point 4:

Second control point of top cap.

Point 5:

Third control point of top cap.

Centre 0:

Centre of bottom cap.

radius 0:

Radius of bottom cap.

Centre 1:

Centre of top cap.

radius 1:

Radius of top cap.

Normal Offset Alignment

The offset that is taken in normal direction between top and bottom cap when aligning.

Align Bottom To Top

Align the bottom to top with given offset.

Align Top To Bottom

Align the top to bottom with given offset.

Mesh Name Prefix

Prefix name applied to mesh (if empty standard name is taken).

(Re)Generate Collider

(Re)Generates the ellipse from given values.

Reset Collider Control Points

Resets the control points for conus creation to start state.

Store Collider

Button to press if want to store the created collider in Unity project.


How to use

Window:

  1. Select game objects want to given cylinder.

  2. Indicate where the center of the cylinder needs to be.

  3. Set local up direction to rotated the cylinder to right orientation.

  4. Set the radius of cylinder.

  5. Set the amount of tessellation.

  6. Press Create Shape. Now the selected objects with Mesh Filter will have their meshes replaced with cylinder and rest will have a Mesh Filter added and puts the cylinder into that.

Inspector:

  1. Add Conus Collider Generator to game object.

  2. Use the gizmo’s in the scene view to set the conus shape you want to generate.

  3. Press (Re)Generate Collider. This will create a mesh filter and collider to the object to put the conus in. If the gameobject already has a mesh filter a child object will be made with the conus.

  4. Press Store Collider if want to save the conus in Unity project.

Conus mesh is stored in Resources/Colliders folder

Prespective Documentation