コード例 #1
0
 internal CommunityGoalEvent InvokeEvent(CommunityGoalEvent arg)
 {
     if (_api.ValidateEvent(arg))
     {
         CommunityGoal?.Invoke(_api, arg);
     }
     return(arg);
 }
コード例 #2
0
 private static void AssertEvent(CommunityGoalEvent @event)
 {
     Assert.NotNull(@event);
     Assert.Equal(DateTime.Parse("2017-08-14T13:20:28Z"), @event.Timestamp);
     Assert.Equal(EventName, @event.Event);
     Assert.Equal(726, @event.CurrentGoals[0].GoalId);
     Assert.Equal("Alliance Research Initiative – Trade", @event.CurrentGoals[0].Title);
     Assert.Equal("Kaushpoos", @event.CurrentGoals[0].SystemName);
     Assert.Equal("Neville Horizons", @event.CurrentGoals[0].MarketName);
     Assert.Equal(DateTime.Parse("2017-08-17T14: 58: 14Z"), @event.CurrentGoals[0].Expiry);
     Assert.False(@event.CurrentGoals[0].IsComplete);
     Assert.Equal(10062, @event.CurrentGoals[0].CurrentTotal);
     Assert.Equal(562, @event.CurrentGoals[0].PlayerContribution);
     Assert.Equal(101, @event.CurrentGoals[0].NumContributors);
     Assert.Equal(10, @event.CurrentGoals[0].TopRankSize);
     Assert.False(@event.CurrentGoals[0].PlayerInTopRank);
     Assert.Equal("Tier 1", @event.CurrentGoals[0].TierReached);
     Assert.Equal(50, @event.CurrentGoals[0].PlayerPercentileBand);
     Assert.Equal(200000, @event.CurrentGoals[0].Bonus);
 }
コード例 #3
0
 internal void InvokeCommunityGoalEvent(CommunityGoalEvent arg)
 {
     CommunityGoalEvent?.Invoke(this, arg);
 }
コード例 #4
0
 internal void InvokeCommunityGoalEvent(CommunityGoalEvent arg) => CommunityGoalEvent?.Invoke(null, arg);