Files
nadekobot/src/NadekoBot/Modules/Gambling/Common/AnimalRacing/AnimalRacingUser.cs
Kwoth d5fd6aae8e - More code cleanup and codestyle updates
- Fixed some possible nullref exceptions
- Methods signatures now have up to 3 parameters before breakaing down each parameter in a separate line
- Method invocations have the same rule, except the first parameter will be in the same line as the invocation to prevent some ugliness when passing lambas as arguments
- Applied many more codestyles
- Extensions folder fully reformatted
2021-12-26 17:28:39 +01:00

27 lines
701 B
C#

using NadekoBot.Modules.Games.Common;
namespace NadekoBot.Modules.Gambling.Common.AnimalRacing;
public class AnimalRacingUser
{
public long Bet { get; }
public string Username { get; }
public ulong UserId { get; }
public RaceAnimal Animal { get; set; }
public int Progress { get; set; }
public AnimalRacingUser(string username, ulong userId, long bet)
{
this.Bet = bet;
this.Username = username;
this.UserId = userId;
}
public override bool Equals(object obj)
=> obj is AnimalRacingUser x
? x.UserId == this.UserId
: false;
public override int GetHashCode()
=> this.UserId.GetHashCode();
}