回答編集履歴
1
メソッド名修正:Clamp -> Clamp01
test
CHANGED
@@ -56,7 +56,7 @@
|
|
56
56
|
|
57
57
|
HP -= 1;
|
58
58
|
|
59
|
-
var currentHPPercentage = Mathf.Clamp(HP / (float)MaxHP);
|
59
|
+
var currentHPPercentage = Mathf.Clamp01(HP / (float)MaxHP);
|
60
60
|
|
61
61
|
this.hpGauge.GetComponent<Image>().fillAmount = currentHPPercentage;
|
62
62
|
|