public override int GetHashCode() { int hash = 1; if (display_ != null) { hash ^= Display.GetHashCode(); } if (extraCase_ == ExtraOneofCase.Unspecified) { hash ^= Unspecified.GetHashCode(); } if (extraCase_ == ExtraOneofCase.MoveToTile) { hash ^= MoveToTile.GetHashCode(); } if (extraCase_ == ExtraOneofCase.MoneyExchange) { hash ^= MoneyExchange.GetHashCode(); } if (extraCase_ == ExtraOneofCase.MoveSteps) { hash ^= MoveSteps.GetHashCode(); } if (extraCase_ == ExtraOneofCase.Collectible) { hash ^= Collectible.GetHashCode(); } hash ^= (int)extraCase_; if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return(hash); }
public void MergeFrom(Chance other) { if (other == null) { return; } if (other.display_ != null) { if (display_ == null) { Display = new global::Monopoly.Protobuf.ChanceDisplay(); } Display.MergeFrom(other.Display); } switch (other.ExtraCase) { case ExtraOneofCase.Unspecified: Unspecified = other.Unspecified; break; case ExtraOneofCase.MoveToTile: if (MoveToTile == null) { MoveToTile = new global::Monopoly.Protobuf.MoveToTileExtra(); } MoveToTile.MergeFrom(other.MoveToTile); break; case ExtraOneofCase.MoneyExchange: if (MoneyExchange == null) { MoneyExchange = new global::Monopoly.Protobuf.MoneyExchangeExtra(); } MoneyExchange.MergeFrom(other.MoneyExchange); break; case ExtraOneofCase.MoveSteps: if (MoveSteps == null) { MoveSteps = new global::Monopoly.Protobuf.MoveStepsExtra(); } MoveSteps.MergeFrom(other.MoveSteps); break; case ExtraOneofCase.Collectible: if (Collectible == null) { Collectible = new global::Monopoly.Protobuf.CollectibleExtra(); } Collectible.MergeFrom(other.Collectible); break; } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); }
public override int GetHashCode() { int hash = 1; if (display_ != null) { hash ^= Display.GetHashCode(); } if (Timing != global::Monopoly.Protobuf.TileEffect.Types.Timing.Unspecified) { hash ^= Timing.GetHashCode(); } if (extraCase_ == ExtraOneofCase.Unspecified) { hash ^= Unspecified.GetHashCode(); } if (extraCase_ == ExtraOneofCase.MoveToTile) { hash ^= MoveToTile.GetHashCode(); } if (extraCase_ == ExtraOneofCase.MoneyExchange) { hash ^= MoneyExchange.GetHashCode(); } if (extraCase_ == ExtraOneofCase.MoveSteps) { hash ^= MoveSteps.GetHashCode(); } if (extraCase_ == ExtraOneofCase.Collectible) { hash ^= Collectible.GetHashCode(); } if (extraCase_ == ExtraOneofCase.Detained) { hash ^= Detained.GetHashCode(); } hash ^= (int)extraCase_; if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } return(hash); }