diff options
author | chai <chaifix@163.com> | 2021-08-06 19:02:03 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2021-08-06 19:02:03 +0800 |
commit | 754ceacd8ab62e7094f1827ae45ea16a502725ad (patch) | |
tree | 7165384f470bf0c4ae261d7dd22876416c150964 /Assets/Scripts/Unit/Controller | |
parent | 35f2e468715e12d93cb88f2258c2d0ae82d1d189 (diff) |
*curve
Diffstat (limited to 'Assets/Scripts/Unit/Controller')
-rw-r--r-- | Assets/Scripts/Unit/Controller/UnitController.cs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/Assets/Scripts/Unit/Controller/UnitController.cs b/Assets/Scripts/Unit/Controller/UnitController.cs index a9baf595..a48ef6ee 100644 --- a/Assets/Scripts/Unit/Controller/UnitController.cs +++ b/Assets/Scripts/Unit/Controller/UnitController.cs @@ -109,4 +109,14 @@ public class UnitController : MonoBehaviour/*, Interactable*/ public virtual void OnGrab()
{
}
+
+
+ public void SetYPosition(float y)
+ {
+ Vector3 pos = transform.position;
+ pos.y = y;
+ transform.position = pos;
+ }
+
}
+
|