public virtual IEnumerator Live(Animal script, TimeController timeController, byte[] stagePreps, byte[] stageEvents) { foreach (byte preparation in stagePreps) { GetPrep(preparation)(script); } while ((stageDays - livedDays) > 0) { byte dayThirds = 0; while (dayThirds < 3) { float thirdDuration = timeController.TimeSpeedMinuteSecs / Random.Range(2.5f, 3.2f); if (!script.busy) { foreach (byte myEvent in stageEvents) { GetEvent(myEvent)(script, thirdDuration); } } dayThirds++; yield return(new WaitForSeconds(thirdDuration)); } livedDays++; } script.lifeStage = GetNextStage(script.lifeStage); LifeStage.InitStage(script, timeController); }
public EventModelDto Get(Guid id) { var eventQuery = new GetEvent(id); var model = _eventsQueryHandler.Handle(eventQuery); return(model); }
public GetEventTests() { this.Database = new MockSponsorServiceDatabase(); IConfiguration config = Mock.Create <IConfiguration>(); this.Controller = new GetEvent(config, this.Database); }
public async Task <Event> Get(GetEvent request) { request.CompanyUid = await _currentCompanyProvider.GetCompanyUid(); request.UserUid = _currentUserProvider.GetUserUid(); return(await _mediator.Send(request)); }
public EventModelDto Get(Guid id) { var eventQuery = new GetEvent(id); var eventModel = _eventsQueryHandler.Handle(eventQuery); eventModel.Users = _getPlayersQuery.Handle(); return(eventModel); }
private void UpdateViews() { DelSheduleText.Items.Clear(); SheduleData.Rows.Clear(); GetEvent events = new GetEvent(); var shedules = events.Get(); foreach (Event shedule in shedules) { SheduleData.Rows.Add(shedule.CODE, shedule.EventText, shedule.Date); DelSheduleText.Items.Add(shedule.EventText); } }
public R this[P parm] { get { return(GetEvent.Invoke(parm)); } set { SetEvent.Invoke(parm, value); } }
public async Task <Employee> Handle(GetEvent <Employee> request, CancellationToken cancellationToken) { return(await _repository.GetById(request.Id)); }
internal static EventInfo?Find(ExpressionSyntax expression, SemanticModel semanticModel, CancellationToken cancellationToken) { if (GetEvent.Match(expression, semanticModel, cancellationToken) is { Member : { ReflectedType : { } reflectedType, Symbol : IEventSymbol symbol } })