Skip to content
Snippets Groups Projects
Commit 84d161d6 authored by Raffael Di Pietro's avatar Raffael Di Pietro
Browse files

j'ai enlevé le bouton

parent e68b6eec
No related merge requests found
...@@ -16,7 +16,7 @@ public class LoseNature : MonoBehaviour ...@@ -16,7 +16,7 @@ public class LoseNature : MonoBehaviour
{ {
nbFactory = GameObject.FindGameObjectsWithTag("factory").Length; nbFactory = GameObject.FindGameObjectsWithTag("factory").Length;
Debug.Log("il pert de la vie: " + nbFactory * damageByFactory); Debug.Log("il pert de la vie: " + nbFactory * damageByFactory);
//collision.GetComponent<PlayerNature>().LooseNature(damageByFactory * nbFactory); collision.GetComponent<PlayerNature>().LooseNature(damageByFactory * nbFactory);
this.lostLife = true; this.lostLife = true;
} }
} }
......
...@@ -96,7 +96,7 @@ public class PlayerMovement : MonoBehaviour ...@@ -96,7 +96,7 @@ public class PlayerMovement : MonoBehaviour
stage++; stage++;
} }
} }
void MoveCharacter() void MoveCharacter()
{ {
change.Normalize(); change.Normalize();
......
...@@ -69,6 +69,9 @@ public class PlayerNature : MonoBehaviour ...@@ -69,6 +69,9 @@ public class PlayerNature : MonoBehaviour
{ {
this.currentNature += bonus; this.currentNature += bonus;
if (this.currentNature >= 100)
this.currentNature = 100;
this.natureBar.SetValue(this.currentNature); this.natureBar.SetValue(this.currentNature);
} }
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment