2018-04-24 03:32:47 +02:00
|
|
|
using System.Collections;
|
2018-04-23 16:08:16 +02:00
|
|
|
using System.Collections.Generic;
|
|
|
|
using UnityEngine;
|
|
|
|
using Assets.Scripts.Entities.Attack;
|
|
|
|
|
2018-04-24 03:32:47 +02:00
|
|
|
namespace Assets.Scripts.Entities {
|
|
|
|
|
|
|
|
public class Spider : Enemy {
|
2018-04-24 02:51:35 +02:00
|
|
|
[SerializeField]
|
|
|
|
private Transform bulletSpawn;
|
|
|
|
[SerializeField]
|
|
|
|
private GameObject bullet;
|
|
|
|
|
2018-04-24 15:58:27 +02:00
|
|
|
public Spider() : base(15) {
|
2018-04-23 16:44:02 +02:00
|
|
|
|
2018-04-23 16:08:16 +02:00
|
|
|
}
|
|
|
|
|
2018-04-24 03:32:47 +02:00
|
|
|
protected override void Start() {
|
2018-04-24 03:45:59 +02:00
|
|
|
SingleShot s = new SingleShot(this.gameObject, 25, 4, 2);
|
2018-04-24 15:58:27 +02:00
|
|
|
s.SetRange(10);
|
2018-04-24 02:51:35 +02:00
|
|
|
s.SetPrefab(bullet);
|
|
|
|
s.SetSpawn(bulletSpawn);
|
2018-04-24 21:07:32 +02:00
|
|
|
SetAttack(s);
|
|
|
|
base.Start();
|
2018-04-23 16:08:16 +02:00
|
|
|
}
|
|
|
|
}
|
2018-04-23 16:44:02 +02:00
|
|
|
}
|