狗屎Minimax坏我代码
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine;
|
||||
|
||||
namespace SickscoreGames.ExampleScene
|
||||
{
|
||||
@@ -21,7 +19,13 @@ namespace SickscoreGames.ExampleScene
|
||||
// reset velocity
|
||||
Rigidbody rBody = other.gameObject.GetComponent<Rigidbody> ();
|
||||
if (rBody != null)
|
||||
rBody.linearVelocity = other.transform.forward * 5f;
|
||||
{
|
||||
#if UNITY_6000_0_OR_NEWER
|
||||
rBody.linearVelocity = other.transform.forward * 5f;;
|
||||
#else
|
||||
rBody.velocity = other.transform.forward * 5f;;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
Reference in New Issue
Block a user