Added votekick button to the server lobby. Closes #190

This commit is contained in:
Joonas Rikkonen
2018-01-10 20:43:31 +02:00
parent 43ceb208ef
commit bd1cd15dd4
2 changed files with 13 additions and 3 deletions
@@ -1380,7 +1380,7 @@ namespace Barotrauma.Networking
public bool VoteForKick(GUIButton button, object userdata)
{
var votedClient = otherClients.Find(c => c.Character == userdata);
var votedClient = userdata is Client ? (Client)userdata : otherClients.Find(c => c.Character == userdata);
if (votedClient == null) return false;
votedClient.AddKickVote(new Client(name, ID));