回答編集履歴
1
追記
test
CHANGED
@@ -7,3 +7,53 @@
|
|
7
7
|
|
8
8
|
|
9
9
|
というか、過去にも同様な質問がある([こちら](https://teratail.com/questions/157150)とか[こちら](https://teratail.com/questions/183348))のですが、ちゃんと調べましたか?
|
10
|
+
|
11
|
+
|
12
|
+
|
13
|
+
---
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
追記:
|
18
|
+
|
19
|
+
|
20
|
+
|
21
|
+
```C#
|
22
|
+
|
23
|
+
float time = 0f;
|
24
|
+
|
25
|
+
|
26
|
+
|
27
|
+
void Update()
|
28
|
+
|
29
|
+
{
|
30
|
+
|
31
|
+
time += Time.deltaTime;
|
32
|
+
|
33
|
+
|
34
|
+
|
35
|
+
Vector3 pos;
|
36
|
+
|
37
|
+
if (time < 1f)
|
38
|
+
|
39
|
+
{
|
40
|
+
|
41
|
+
pos = Vector3.Lerp(new Vector3(0, 0, 0), new Vector3(0, 5, 0), time);
|
42
|
+
|
43
|
+
}
|
44
|
+
|
45
|
+
else
|
46
|
+
|
47
|
+
{
|
48
|
+
|
49
|
+
pos = new Vector3(0, 5, 0);
|
50
|
+
|
51
|
+
}
|
52
|
+
|
53
|
+
|
54
|
+
|
55
|
+
Debug.Log(pos.ToString("G"));
|
56
|
+
|
57
|
+
}
|
58
|
+
|
59
|
+
```
|