diff options
author | chai <chaifix@163.com> | 2021-08-31 19:07:21 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2021-08-31 19:07:21 +0800 |
commit | ffd1d5af496e0a0eff343b27c4f0f965bbbf79eb (patch) | |
tree | c5a8ae2116040ce8c483454b2e82093f247db341 /Assets/Art/Vfx/StylizedProjectilePack1/scripts/destroyMe.cs | |
parent | 476abf41a7357db0dd870f0d221f1a26481ab2bf (diff) |
*projectile
Diffstat (limited to 'Assets/Art/Vfx/StylizedProjectilePack1/scripts/destroyMe.cs')
-rw-r--r-- | Assets/Art/Vfx/StylizedProjectilePack1/scripts/destroyMe.cs | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/Assets/Art/Vfx/StylizedProjectilePack1/scripts/destroyMe.cs b/Assets/Art/Vfx/StylizedProjectilePack1/scripts/destroyMe.cs new file mode 100644 index 00000000..cb8061db --- /dev/null +++ b/Assets/Art/Vfx/StylizedProjectilePack1/scripts/destroyMe.cs @@ -0,0 +1,26 @@ +using UnityEngine;
+using System.Collections;
+
+public class destroyMe : MonoBehaviour{
+
+ float timer;
+ public float deathtimer = 10;
+
+
+ // Use this for initialization
+ void Start () {
+
+ }
+
+ // Update is called once per frame
+ void Update ()
+ {
+ timer += Time.deltaTime;
+
+ if(timer >= deathtimer)
+ {
+ Destroy(gameObject);
+ }
+
+ }
+}
|