質問編集履歴
1
コード直し
title
CHANGED
File without changes
|
body
CHANGED
@@ -23,11 +23,14 @@
|
|
23
23
|
Instantiate(A1, new Vector3(transform.position.x, 0.01f, transform.position.z + 1), Quaternion.identity) as GameObject;
|
24
24
|
|
25
25
|
}
|
26
|
+
}
|
26
27
|
void Update()
|
27
28
|
{
|
28
29
|
if (Input.GetMouseButtonDown(0))
|
29
30
|
{
|
30
31
|
A1.GetComponent<B>().destroy();
|
32
|
+
}
|
33
|
+
}
|
31
34
|
|
32
35
|
```
|
33
36
|
●破壊するオブジェクトにアタッチ
|