public RoomState(int roomID) { RoomID = roomID; CurrentGameState = new GameState(); CurrentHandState = new CurrentHandState(this.CurrentGameState); CurrentTrickState = new CurrentTrickState(); roomSetting = new RoomSetting(); }
public override bool Equals(object obj) { if (obj == null) { return(false); } if (Object.ReferenceEquals(this, obj)) { return(true); } if (this.GetType() != obj.GetType()) { return(false); } RoomSetting rs = (RoomSetting)obj; if (RoomName != rs.RoomName) { return(false); } if (RoomOwner != rs.RoomOwner) { return(false); } if (AllowRiotWithTooFewScoreCards != rs.AllowRiotWithTooFewScoreCards) { return(false); } if (AllowRiotWithTooFewTrumpCards != rs.AllowRiotWithTooFewTrumpCards) { return(false); } if (secondsToWaitForReenter != rs.secondsToWaitForReenter) { return(false); } if (AllowJToBottom != rs.AllowJToBottom) { return(false); } if (DisplaySignalCardInfo != rs.DisplaySignalCardInfo) { return(false); } if (AllowSurrender != rs.AllowSurrender) { return(false); } if (AllowRobotMakeTrump != rs.AllowRobotMakeTrump) { return(false); } if (!ManditoryRanks.SequenceEqual(rs.ManditoryRanks)) { return(false); } return(true); }