mirror of
https://github.com/LBPUnion/ProjectLighthouse.git
synced 2025-08-02 18:18:39 +00:00
commit
8ecc5b1aad
1 changed files with 10 additions and 10 deletions
|
@ -20,6 +20,8 @@ public class Room
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
[RedisIdField]
|
[RedisIdField]
|
||||||
public string RedisId { get; set; }
|
public string RedisId { get; set; }
|
||||||
|
|
||||||
|
@ -43,18 +45,16 @@ public class Room
|
||||||
public bool IsLookingForPlayers => this.State == RoomState.PlayingLevel || this.State == RoomState.DivingInWaiting;
|
public bool IsLookingForPlayers => this.State == RoomState.PlayingLevel || this.State == RoomState.DivingInWaiting;
|
||||||
|
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public int HostId {
|
public int HostId
|
||||||
get {
|
|
||||||
try
|
|
||||||
{
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (this.PlayerIds.Count > 0)
|
||||||
return this.PlayerIds[0];
|
return this.PlayerIds[0];
|
||||||
}
|
|
||||||
catch
|
|
||||||
{
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#nullable enable
|
#nullable enable
|
||||||
public override bool Equals(object? obj)
|
public override bool Equals(object? obj)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue