enemy spawner
This commit is contained in:
23
Game/Scripts/Runtime/Data/EnemyDefinition.cs
Normal file
23
Game/Scripts/Runtime/Data/EnemyDefinition.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Game.Scripts.Runtime.Data
|
||||
{
|
||||
[CreateAssetMenu(menuName = "Game/Spawning/Enemy Definition", fileName = "EnemyDefinition")]
|
||||
public class EnemyDefinition : ScriptableObject
|
||||
{
|
||||
[Tooltip("Unique identifier leveraged by pooling and save systems. Defaults to asset name when left blank.")]
|
||||
[SerializeField] private string id;
|
||||
|
||||
[Tooltip("Prefab that represents this enemy. Should include required behaviours and visuals.")]
|
||||
public GameObject Prefab;
|
||||
|
||||
public bool IsBoss;
|
||||
public float BaseHP = 10f;
|
||||
public float MoveSpeed = 3.5f;
|
||||
public float Damage = 1f;
|
||||
public Vector3 PrefabPivotOffset = Vector3.zero;
|
||||
public string[] Tags = System.Array.Empty<string>();
|
||||
|
||||
public string Id => string.IsNullOrEmpty(id) ? name : id;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user