Created
July 9, 2018 11:55
-
-
Save nopitech/7478d2ccb4e11e2f20590a1adcb1360f to your computer and use it in GitHub Desktop.
2点間の移動
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
public class VectorScript : MonoBehaviour | |
{ | |
void Update() | |
{ | |
Vector3 from = Vector3.zero; | |
Vector3 to = Vector3.one*10; | |
transform.position = Vector3.Lerp(from, to, Time.time * 0.3f); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment