Added whitelist command.
This commit is contained in:
parent
dc27c5a236
commit
5b0716c8ee
1 changed files with 11 additions and 0 deletions
|
|
@ -852,6 +852,17 @@ namespace TShockAPI
|
|||
|
||||
#region General Commands
|
||||
|
||||
public static void Whitelist(CommandArgs args)
|
||||
{
|
||||
if (args.Parameters.Count == 1)
|
||||
{
|
||||
TextWriter tw = new StreamWriter(FileTools.WhitelistPath, true);
|
||||
tw.WriteLine(args.Parameters[0]);
|
||||
tw.Close();
|
||||
args.Player.SendMessage("Added " + args.Parameters[0] + " to the whitelist.");
|
||||
}
|
||||
}
|
||||
|
||||
private static void Help(CommandArgs args)
|
||||
{
|
||||
args.Player.SendMessage("TShock Commands:");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue