Made the traitorlist command usable by clients (assuming they have the permission to use it). Closes #539
This commit is contained in:
@@ -190,6 +190,17 @@ namespace Barotrauma
|
|||||||
NewMessage("- Traitor " + t.Character.Name + "'s target is " + t.TargetCharacter.Name + ".", Color.Cyan);
|
NewMessage("- Traitor " + t.Character.Name + "'s target is " + t.TargetCharacter.Name + ".", Color.Cyan);
|
||||||
}
|
}
|
||||||
NewMessage("The code words are: " + traitorManager.codeWords + ", response: " + traitorManager.codeResponse + ".", Color.Cyan);
|
NewMessage("The code words are: " + traitorManager.codeWords + ", response: " + traitorManager.codeResponse + ".", Color.Cyan);
|
||||||
|
},
|
||||||
|
null,
|
||||||
|
(Client client, Vector2 cursorPos, string[] args) =>
|
||||||
|
{
|
||||||
|
TraitorManager traitorManager = GameMain.Server.TraitorManager;
|
||||||
|
if (traitorManager == null) return;
|
||||||
|
foreach (Traitor t in traitorManager.TraitorList)
|
||||||
|
{
|
||||||
|
GameMain.Server.SendConsoleMessage("- Traitor " + t.Character.Name + "'s target is " + t.TargetCharacter.Name + ".", client);
|
||||||
|
}
|
||||||
|
GameMain.Server.SendConsoleMessage("The code words are: " + traitorManager.codeWords + ", response: " + traitorManager.codeResponse + ".", client);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
commands.Add(new Command("itemlist", "itemlist: List all the item prefabs available for spawning.", (string[] args) =>
|
commands.Add(new Command("itemlist", "itemlist: List all the item prefabs available for spawning.", (string[] args) =>
|
||||||
|
|||||||
Reference in New Issue
Block a user