// Start is called before the first frame update
    void Start()
    {
        _image = this.gameObject.GetComponent <Image>();
        this.gameObject.name = this.gameObject.name.Replace("(Clone)", "");
        commandPlayer        = GetComponentInParent <CommandPlayer>();
        movePlayer           = GetComponentInParent <MovePlayer>();
        _button_hideTime     = 0.45f;

        //スキル番号抽出
        for (int i = 0; i < skillname.Length; i++)
        {
            if (this.gameObject.name == skillname[i] + "Button")
            {
                skill_number = i;
            }
        }
    }
Beispiel #2
0
 public void PickUp(CommandPlayer player)
 {
     GUIConsole.Instance.Log($"{player.GetPlayerName()} has the flag!");
 }
 // Constructor for player and flag reference
 public CaptureFlag(Flag flag, CommandPlayer player)
 {
     this.player = player;
     this.flag   = flag;
 }
 /// <summary>Heal the player by a select amount.</summary>
 /// <param name="health">Amount of health to give the player.</param>
 public Heal(CommandPlayer player, int health)
 {
     this.player = player;
     this.health = health;
 }
 /// <summary>Respawn a player in a select location.</summary>
 public Spawn(CommandPlayer player, string location)
 {
     this.player   = player;
     this.location = location;
 }