示例#1
0
    public void Reset()
    {
        _hits   = 0;
        _misses = 0;
        _shots  = 0;
        _playerGrid.Reset();

        foreach (KeyValuePair <ShipName, Ship> ship in _Ships)
        {
            ship.Value.Reset();
        }
    }
示例#2
0
    // Reset the values of the objects
    public virtual void Reset()
    {
        _shots  = 0;
        _hits   = 0;
        _misses = 0;
        foreach (KeyValuePair <ShipName, Ship> s in _ships)
        {
            s.Value.Reset();
        }

        _playerGrid.Reset();
    }