質問するログイン新規登録

質問編集履歴

3

コード表記修正

2017/10/15 07:38

投稿

sutegoma
sutegoma

スコア37

title CHANGED
File without changes
body CHANGED
@@ -102,7 +102,8 @@
102
102
  starcount -= 1;
103
103
  }
104
104
  }
105
- ```  
105
+ ``` 
106
+
106
107
  Starcontroller.cs
107
108
  ``` 
108
109
  using System.Collections;

2

コードの整形

2017/10/15 07:38

投稿

sutegoma
sutegoma

スコア37

title CHANGED
File without changes
body CHANGED
@@ -15,6 +15,7 @@
15
15
  mutekijikanメソッドのほうにif文で処理しようとする
16
16
  結果:HPが増えない上一度に2ずつカウントが減り、残り1でストップしてしまう
17
17
  例:
18
+ ``` 
18
19
 
19
20
  else if (other.gameObject.tag == "Star") {
20
21
  motonoHP = tankHP;
@@ -31,8 +32,10 @@
31
32
  tankLife.text = "むてきあと" + starcount + "秒";
32
33
  starcount -= 1;
33
34
  }
34
-
35
+ ``` 
36
+  
35
37
  TankHealth.cs
38
+ ``` 
36
39
  using System.Collections;
37
40
  using System.Collections.Generic;
38
41
  using UnityEngine;
@@ -99,8 +102,9 @@
99
102
  starcount -= 1;
100
103
  }
101
104
  }
102
-
105
+ ```  
103
106
  Starcontroller.cs
107
+ ``` 
104
108
  using System.Collections;
105
109
  using System.Collections.Generic;
106
110
  using UnityEngine;
@@ -129,4 +133,5 @@
129
133
  Destroy (Destroyeffect);
130
134
  Destroy (get_audio);
131
135
  }
132
- }
136
+ }
137
+ ```

1

初心者マーク付随

2017/10/15 07:36

投稿

sutegoma
sutegoma

スコア37

title CHANGED
File without changes
body CHANGED
File without changes