void Start() { actPart = GetComponent <ActivityParticipation>(); compAnim = gameObject.GetComponent <Animator>(); //hero = GameObject.FindGameObjectWithTag("Player"); }
//[SerializeField] GameObject hero; //[SerializeField] GameObject sidekick = null; //Hero script references //StatsPlayer heroStats; //Sidekick script references //StatsPlayer sideStats; //Local participation bools //bool heroDidIt = false; //bool sideDidIt = false; private void Start() { mapManager = GameObject.Find("MapSceneManager").GetComponent <MapSceneManager>(); actPart = GetComponent <ActivityParticipation>(); //hero = GameObject.FindGameObjectWithTag("Player"); //heroStats = hero.GetComponent<StatsPlayer>(); //sidekick = GameObject.FindGameObjectWithTag("Sidekick"); //if (sidekick != null) { //sideStats = sidekick.GetComponent<StatsPlayer>(); //} }
public HomeViewModel( IActivityParticipationService activityParticipationService, IActivityManagementService activityManagementService, IEventParticipationService eventParticipationService, IEventManagementService eventManagementService) { _activityParticipationService = activityParticipationService; _activityManagementService = activityManagementService; _eventParticipationService = eventParticipationService; _eventManagementService = eventManagementService;; NewEventParticipation = new EventParticipation(); NewActivityParticipation = new ActivityParticipation(); }
public async Task SaveActivity() { NewActivityParticipation.Id = Guid.NewGuid(); NewActivityParticipation.PointsEarned = Math.Round(NewActivityParticipation.Minutes * 0.166666666667m); NewActivityParticipation.UserId = Id; await _activityParticipationService.Create(NewActivityParticipation); SelectedRelativeIndex = (DateTimeOffset.UtcNow.Month - NewActivityParticipation.SubmissionDate.Month); await SetActivityParticipations(); //clear out UI NewActivityParticipation = new ActivityParticipation(); }
public Task Create(ActivityParticipation activityParticipation) { return(_proxy.Create(activityParticipation)); }