From 331e4a2bd1a46895ddc6ec48bc96222663e57f9d Mon Sep 17 00:00:00 2001 From: ikpil Date: Thu, 20 Apr 2023 22:51:43 +0900 Subject: [PATCH] new float[] -> Vector3f --- src/DotRecast.Recast.Demo/Tools/Gizmos/CapsuleGizmo.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/DotRecast.Recast.Demo/Tools/Gizmos/CapsuleGizmo.cs b/src/DotRecast.Recast.Demo/Tools/Gizmos/CapsuleGizmo.cs index 4bdd2ee..6ed4398 100644 --- a/src/DotRecast.Recast.Demo/Tools/Gizmos/CapsuleGizmo.cs +++ b/src/DotRecast.Recast.Demo/Tools/Gizmos/CapsuleGizmo.cs @@ -29,9 +29,9 @@ public class CapsuleGizmo : ColliderGizmo cross(ref normals[2], normals[0], normals[1]); normalize(ref normals[2]); triangles = generateSphericalTriangles(); - float[] trX = new float[] { normals[0][0], normals[1][0], normals[2][0] }; - float[] trY = new float[] { normals[0][1], normals[1][1], normals[2][1] }; - float[] trZ = new float[] { normals[0][2], normals[1][2], normals[2][2] }; + var trX = Vector3f.Of(normals[0][0], normals[1][0], normals[2][0]); + var trY = Vector3f.Of(normals[0][1], normals[1][1], normals[2][1]); + var trZ = Vector3f.Of(normals[0][2], normals[1][2], normals[2][2]); float[] spVertices = generateSphericalVertices(); float halfLength = 0.5f * vLen(axis); vertices = new float[spVertices.Length];