ソースコード
using UnityEngine; public static class Vector3IntExt { public static void Deconstruct ( this Vector3Int self, out int x, out int y, out int z ) { x = self.x; y = self.y; z = self.z; } }
使用例
通常
var vec = new Vector3Int( 1, 2, 3 );
Deconstruction
var ( x, y, z ) = new Vector3Int( 1, 2, 3 );