Added NoTrail, Slowmotion and BulletFreezeRemove Pickups

Also refactored Extinguisher to remove particles from the end (still wonky though)
This commit is contained in:
2022-04-19 23:21:03 +02:00
parent e2511e2d53
commit 095fc0742b
19 changed files with 5467 additions and 45 deletions

View File

@@ -4,6 +4,7 @@ using UnityEngine;
public class Pickup : MonoBehaviour
{
protected bool pickedUp = false;
public virtual void OnPickup()
{
@@ -14,8 +15,18 @@ public class Pickup : MonoBehaviour
Debug.Log("Pickup");
if (other.gameObject.tag == "Player")
{
pickedUp = true;
OnPickup();
Destroy(gameObject);
}
}
//Draw text gizmo in editor to show class name
void OnDrawGizmos()
{
//get curren class name
string className = this.GetType().ToString();
GUI.color = Color.blue;
UnityEditor.Handles.Label(transform.position, className);
}
}