Skip to content

Instantly share code, notes, and snippets.

@todorok1
Created Nov 21, 2020
Embed
What would you like to do?
transform.positionを取得して値を変えたらセットし直す
// transform.positionを取得してみる
Vector3 pos = gameObject.transform.position;
// 値を変えてみる
pos.x += 5.0f;
// transform.positionにセットし直す
gameObject.transform.position = pos;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment