Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
You cannot cast CollisionFlags in Vector3, but you can write your own transformation method, though it will turn out to be nonsense.
private Vector3 GetVector3(CollisionFlags flags)
{
switch (flags)
{
case CollisionFlags.None:
return Vector3.zero;
case CollisionFlags.Above:
return Vector3.up;
case CollisionFlags.Below:
return Vector3.down;
case CollisionFlags.Sides:
default:
return Vector3.zero;
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question