コード例 #1
0
ファイル: TiledMap.cs プロジェクト: Bamboy/motherload
    void OnDrawGizmos()
    {
        Bounds b = new Bounds(transform.position + Vector3.down, Vector3.zero);           // - Vector3.down

        b.Encapsulate((transform.position + new Vector3(mapSize.x, mapSize.y, 0f)) + Vector3.down);

        DebugExtension.DrawBounds(b, Color.blue);
    }
コード例 #2
0
ファイル: Example.cs プロジェクト: gemshin/UnityScrap
 void OnDrawGizmos()
 {
     if (debugPoint)
     {
         DebugExtension.DrawPoint(debugPoint_Position, debugPoint_Color, debugPoint_Scale);
     }
     if (debugBounds)
     {
         DebugExtension.DrawBounds(new Bounds(new Vector3(10, 0, 0), debugBounds_Size), debugBounds_Color);
     }
     if (debugCircle)
     {
         DebugExtension.DrawCircle(new Vector3(20, 0, 0), debugCircle_Up, debugCircle_Color, debugCircle_Radius);
     }
     if (debugWireSphere)
     {
         Gizmos.color = debugWireSphere_Color;
         Gizmos.DrawWireSphere(new Vector3(30, 0, 0), debugWireSphere_Radius);
     }
     if (debugCylinder)
     {
         DebugExtension.DrawCylinder(new Vector3(40, 0, 0), debugCylinder_End, debugCylinder_Color, debugCylinder_Radius);
     }
     if (debugCone)
     {
         DebugExtension.DrawCone(new Vector3(50, 0, 0), debugCone_Direction, debugCone_Color, debugCone_Angle);
     }
     if (debugArrow)
     {
         DebugExtension.DrawArrow(new Vector3(60, 0, 0), debugArrow_Direction, debugArrow_Color);
     }
     if (debugCapsule)
     {
         DebugExtension.DrawCapsule(new Vector3(70, 0, 0), debugCapsule_End, debugCapsule_Color, debugCapsule_Radius);
     }
     if (debugCapsule)
     {
         DebugExtension.DrawCapsule(new Vector3(80, 0, 0), 20, debugCapsule_Radius);
     }
 }
コード例 #3
0
 private void OnDrawGizmos()
 {
     DebugExtension.DrawBounds(new Bounds(transform.position, new Vector3(1, 1, 1)), Color.yellow);
 }
コード例 #4
0
 private void OnDrawGizmos()
 {
     DebugExtension.DrawBounds(collider.bounds, Color.green);
 }