Пример #1
0
 public Event(GridHandler.Level level, string title, string description, EventOption option1, EventOption option2)
 {
     Level       = level;
     Title       = title;
     Description = description;
     Option1     = option1;
     Option2     = option2;
 }
Пример #2
0
        public void ChooseEventOption(EventOption eventOption)
        {
            switch (eventOption.OptionType)
            {
            case EventOption.EventOptionType.FUNDING:
                _projectProgressor.AddFundingCost(eventOption.Amount);
                break;

            case EventOption.EventOptionType.MONTHS:
                _projectProgressor.AddOverTime(eventOption.Amount);
                break;

            case EventOption.EventOptionType.CANCEL:
                _projectProgressor.CancelProject();
                break;

            default:
                throw new ArgumentOutOfRangeException();
            }

            Destroy(_currentEventCard);
            _projectProgressor.EventInProgress = false;
        }
Пример #3
0
        public void ChooseEventOption(EventOption eventOption)
        {
            var manager = GameObject.Find("GameManager").GetComponent <EventCardManager>();

            manager.ChooseEventOption(eventOption);
        }