 | MathConversionExtensionsToVector3 Method (Vector2F, Single) |
Note: This API is now obsolete.
Converts the specified framework vector to an Unity vector.
Namespace: Slash.Unity.Common.MathAssembly: Slash.Unity.Common (in Slash.Unity.Common.dll) Version: 1.0.6018.40182
Syntax[ObsoleteAttribute("Deprecated to make conversion clearer. Use ToVector3XY instead.")]
public static Vector3 ToVector3(
this Vector2F vector,
float z = 0f
)
<ObsoleteAttribute("Deprecated to make conversion clearer. Use ToVector3XY instead.")>
<ExtensionAttribute>
Public Shared Function ToVector3 (
vector As Vector2F,
Optional z As Single = 0F
) As Vector3
public:
[ObsoleteAttribute(L"Deprecated to make conversion clearer. Use ToVector3XY instead.")]
[ExtensionAttribute]
static Vector3 ToVector3(
Vector2F vector,
float z = 0f
)
[<ObsoleteAttribute("Deprecated to make conversion clearer. Use ToVector3XY instead.")>]
[<ExtensionAttribute>]
static member ToVector3 :
vector : Vector2F *
?z : float32
(* Defaults:
let _z = defaultArg z 0f
*)
-> Vector3
Parameters
- vector
- Type: Slash.Math.Algebra.VectorsVector2F
Vector to convert. - z (Optional)
- Type: SystemSingle
Z value.
Return Value
Type:
Vector3Corresponding Unity vector.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
Vector2F. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
See Also