private void FishingEventHandler(object sender, FishingEvent e) { Dispatch(() => { switch (e.Action) { case FishingAction.BobberMove: if (!this.GraphFlipper.IsFlipped) { this.Chart.Add(e.Amplitude); } break; case FishingAction.Loot: this.flyingFishAnimation.Start(); this.LootingGrid.Visibility = Visibility.Visible; break; case FishingAction.Cast: this.Chart.ClearChart(); this.LootingGrid.Visibility = Visibility.Collapsed; this.flyingFishAnimation.Stop(); setImageBackgroundColour = true; break; } ; }); }
public void RaiseEvent(FishingEvent ev) { FishingEventHandler?.Invoke(ev); }