using System;
using UnityEngine;

namespace pdinklag.CPW.Common
{
    /// <summary>
    /// Describes a wrestler.
    /// </summary>
    [CreateAssetMenu(fileName = "Wrestler", menuName = "Wrestle/Wrestler Descriptor")]
    public class WrestlerDescriptor : ScriptableObject
    {
        [HideInInspector]
        public string GUID;

        [Header("Profile")]
        [Tooltip("The wrestler's display name.")]
        public string DisplayName = "Wrestler";

        [Tooltip("The wrestler's shorter display name for when there's not much room.")]
        public string ShortName = "Wrestler";

        [Tooltip("The wrestler's stats.")]
        public WrestlerStats Stats = WrestlerStats.Default;

        [Header("Settings")]
        [Tooltip("The wrestler prefab address. If empty, the name of this object will be used to construct it.")]
        public AssetAddress Prefab;

        [Tooltip("The group tag for grouping wrestlers in the roster.")]
        public string RosterGroupTag;

        [Tooltip("This particular wrestler should be the first shown in the group.")]
        public bool RosterGroupMaster;

        [Header("Moves")]
        [Tooltip("The wrestler's moves. Unset entries will be replaced by the default moveset.")]
        public Moveset Moves;

        [Header("Entrance")]
        [Tooltip("The entrance script address. If empty, the name of this object will be used to construct it.")]
        public AssetAddress Entrance;

        [Tooltip("The entrance theme address. If empty, the name of this object will be used to construct it.")]
        public AssetAddress Theme;

        private void Reset()
        {
            GUID = Guid.NewGuid().ToString();
        }
    }
}
