Dungeon Architect  17.0.0
DungeonArchitect.Editors.InspectorUtils Class Reference

Utility functions for drawing UI in the Inspector window More...

Static Public Member Functions

static void DrawMatrixProperty (string caption, ref Matrix4x4 matrix)
 Draws the translation / rotation / scale widgets for a Matrix4x4 More...
 
static void RoundVector (ref Vector3 vector, int precision)
 Rounds the Vector to the nearest precision More...
 
static float Round (float f, int precision)
 rounds a float to the nearest precision More...
 
static void DrawVectorProperty (string caption, ref Vector3 vector)
 Draws XYZ components of a Vector3 in the inspector window within the same line for better usability and asthetics More...
 

Detailed Description

Utility functions for drawing UI in the Inspector window

Definition at line 12 of file InspectorUtils.cs.

Member Function Documentation

◆ DrawMatrixProperty()

static void DungeonArchitect.Editors.InspectorUtils.DrawMatrixProperty ( string  caption,
ref Matrix4x4  matrix 
)
static

Draws the translation / rotation / scale widgets for a Matrix4x4

Parameters
captionThe caption to display above the widget
matrixThe transform matrix to modify

Definition at line 19 of file InspectorUtils.cs.

◆ DrawVectorProperty()

static void DungeonArchitect.Editors.InspectorUtils.DrawVectorProperty ( string  caption,
ref Vector3  vector 
)
static

Draws XYZ components of a Vector3 in the inspector window within the same line for better usability and asthetics

Parameters
captionThe caption to use on the property
vectorThe vector to modify

Definition at line 73 of file InspectorUtils.cs.

◆ Round()

static float DungeonArchitect.Editors.InspectorUtils.Round ( float  f,
int  precision 
)
static

rounds a float to the nearest precision

Parameters
fThe value to round
precisionThe precision in digits
Returns

Definition at line 62 of file InspectorUtils.cs.

◆ RoundVector()

static void DungeonArchitect.Editors.InspectorUtils.RoundVector ( ref Vector3  vector,
int  precision 
)
static

Rounds the Vector to the nearest precision

Parameters
vectorThe vector to round
precisionThe precision in digits

Definition at line 49 of file InspectorUtils.cs.


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