From 7c7a9a90ee6ff653411d9f3ab5faed1d61facec6 Mon Sep 17 00:00:00 2001 From: Zack Piispanen Date: Sun, 15 Apr 2012 14:59:10 -0400 Subject: [PATCH] Whitelist kick message. --- TShockAPI/ConfigFile.cs | 2 ++ TShockAPI/TShock.cs | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/TShockAPI/ConfigFile.cs b/TShockAPI/ConfigFile.cs index d03ff4f7..5e301589 100644 --- a/TShockAPI/ConfigFile.cs +++ b/TShockAPI/ConfigFile.cs @@ -118,6 +118,8 @@ namespace TShockAPI [Description("String that is used when kicking people when the server is full.")] public string ServerFullReason = "Server is full"; + [Description("String that is used when a user is kicked due to not being on the whitelist.")] public string WhitelistKickReason = "You are not on the whitelist."; + [Description("String that is used when kicking people when the server is full with no reserved slots.")] public string ServerFullNoReservedReason = "Server is full. No reserved slots open."; diff --git a/TShockAPI/TShock.cs b/TShockAPI/TShock.cs index 9fc3aabb..7fd56bb5 100755 --- a/TShockAPI/TShock.cs +++ b/TShockAPI/TShock.cs @@ -656,7 +656,7 @@ namespace TShockAPI if (!FileTools.OnWhitelist(player.IP)) { - Utils.ForceKick(player, "Not on whitelist."); + Utils.ForceKick(player, Config.WhitelistKickReason); handler.Handled = true; return; }