Skip to content
Snippets Groups Projects
Commit ca840924 authored by Louis's avatar Louis
Browse files

fixed

parents 17c13be1 f70777d4
No related branches found
No related tags found
No related merge requests found
using System.Collections;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
......@@ -7,7 +7,6 @@ public class Loot : MonoBehaviour
{
public Gun.GunName gunName;
public int value;
//public Transform roomCanvas;
public WeaponData weapons;
// Start is called before the first frame update
......
This diff is collapsed.
using System.Collections;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
......@@ -46,7 +46,7 @@ public class LifeBobby : MonoBehaviour
}
}
private void AlterLife(int alteration) {
public void AlterLife(int alteration) {
count_life += alteration;
if(count_life >= maxHealth){
healthBar.setHealth(maxHealth);
......@@ -57,3 +57,4 @@ public class LifeBobby : MonoBehaviour
}
}
......@@ -27,10 +27,12 @@ public class LifeClyde : MonoBehaviour
void OnTriggerEnter2D (Collider2D Target){
if(Target.tag == "DamageMaker"){
LoseLife(Target.GetComponent<damageMaker>().damage);
}
if(Target.tag == "LifeUp"){
AlterLife(20);
}
}
......
......@@ -40,14 +40,14 @@ public class LifeVillain : MonoBehaviour
}
/*
if(Target.tag == "Bullet"){
LoseLife(10);
LoseLife(5);
}
if(Target.tag == "Plomb" && count_life > 0){
LoseLife(5);
}
if(Target.tag == "Explosion"){
LoseLife(300);
LoseLife(40);
}
*/
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment