/// <summary> /// Start game. /// </summary> public void StartGame(int factor) { StopGame(); if (_chaosField.RandomPoint == null) { return; } _factor = factor; var userRandomPoint = _chaosField.RandomPoint.Value; _chaosField.DrawPoint(userRandomPoint, DotType.CurrentTrack); _anchorPoints = _chaosField.AnchorPoints.ToDictionary(i => i.Key, i => i.Value); _random = new Random(); _dispatcherTimer.Start(); }
/// <summary> /// Mouse pressed. /// </summary> /// <param name="position">Mouse click position.</param> public void MousePressed(Point position) { if (_handler != null) { _chaosField.DrawPoint(position, _handler(position)); } }