static public Boolean WordSearch(String _SearchingString) { if (_SearchingString.Length > 0) { SearchingString = _SearchingString; } else { return(false); } for (int i = 0; i < CharMas.GetLength(0); i++) { for (int j = 0; j < CharMas.GetLength(1); j++) { VisitMas = new Boolean [CharMas.GetLength(0) + 1, CharMas.GetLength(1) + 1]; if (CharMas[i, j] == SearchingString.First()) { if (Walker.Invoke(i, j)) { return(true); } } } } return(false); }
public void OnWalk(Position position) { Walk?.Invoke(this, new WalkEventArgs { X = position.X, Y = position.Y }); }
public void WalkAction() { Walk?.Invoke(); }