Exemplo n.º 1
0
        private void CreateButton(State state)
        {
            GameObject buttonGameObject = Instantiate(prefab);
            GameButton button           = buttonGameObject.GetComponent <GameButton>();

            gameButtons.Add(button);
            button.RestoreWith(state);
        }
Exemplo n.º 2
0
        public override bool Equals(object other)
        {
            if (this == other)
            {
                return(true);
            }

            if (other == null)
            {
                return(false);
            }

            if (!(other is GameButton))
            {
                return(false);
            }

            GameButton gameButton = (GameButton)other;

            return(nameLabel.Equals(gameButton.nameLabel) &&
                   levelLabel.Equals(gameButton.levelLabel) &&
                   dateTimeLabel.Equals(gameButton.dateTimeLabel));
        }
Exemplo n.º 3
0
 public void Remove(GameButton gameButton)
 {
     gameButton.DeleteLinkedFile();
     gameButtons.Remove(gameButton);
     Destroy(gameButton.gameObject);
 }