mirror of
https://github.com/islehorse/HISP.git
synced 2025-04-18 19:01:32 +12:00
Allow option to skip non-violation chat checks
This commit is contained in:
parent
1916d20031
commit
41578298b6
4 changed files with 13 additions and 1 deletions
|
@ -440,6 +440,8 @@ namespace HISP.Game.Chat
|
||||||
|
|
||||||
public static string NonViolationChecks(User user, string message)
|
public static string NonViolationChecks(User user, string message)
|
||||||
{
|
{
|
||||||
|
if(ConfigReader.DoNonViolations)
|
||||||
|
return null;
|
||||||
|
|
||||||
// Check if contains password.
|
// Check if contains password.
|
||||||
if (message.ToLower().Contains(user.Password.ToLower()))
|
if (message.ToLower().Contains(user.Password.ToLower()))
|
||||||
|
|
|
@ -1124,7 +1124,8 @@ namespace HISP.Game
|
||||||
if(TileCode == "MULTIROOM")
|
if(TileCode == "MULTIROOM")
|
||||||
{
|
{
|
||||||
user.MetaPriority = false; // acturally want to track updates here >-<
|
user.MetaPriority = false; // acturally want to track updates here >-<
|
||||||
message += buildMultiroom(TileArg, user);
|
if(TileArg != "")
|
||||||
|
message += buildMultiroom(TileArg, user);
|
||||||
}
|
}
|
||||||
if(TileCode == "PASSWORD")
|
if(TileCode == "PASSWORD")
|
||||||
{
|
{
|
||||||
|
|
|
@ -35,6 +35,11 @@ enable_word_filter=true
|
||||||
# (NOTE: This feature is also used to filter some less-'bad' words disabling it will allow users to say them!)
|
# (NOTE: This feature is also used to filter some less-'bad' words disabling it will allow users to say them!)
|
||||||
enable_corrections=true
|
enable_corrections=true
|
||||||
|
|
||||||
|
# Include non-violations
|
||||||
|
# stuff like blocking you from saying your password in chat
|
||||||
|
# and FULL CAPS messages.
|
||||||
|
non_violation=true
|
||||||
|
|
||||||
# Wether or not to consider all users "Subscribers"
|
# Wether or not to consider all users "Subscribers"
|
||||||
all_users_subscribed=false
|
all_users_subscribed=false
|
||||||
|
|
||||||
|
|
|
@ -24,6 +24,7 @@ namespace HISP.Server
|
||||||
public static bool AllUsersSubbed;
|
public static bool AllUsersSubbed;
|
||||||
public static bool BadWords;
|
public static bool BadWords;
|
||||||
public static bool DoCorrections;
|
public static bool DoCorrections;
|
||||||
|
public static bool DoNonViolations;
|
||||||
|
|
||||||
public const int MAX_STACK = 40;
|
public const int MAX_STACK = 40;
|
||||||
|
|
||||||
|
@ -99,6 +100,9 @@ namespace HISP.Server
|
||||||
case "enable_corrections":
|
case "enable_corrections":
|
||||||
BadWords = data == "true";
|
BadWords = data == "true";
|
||||||
break;
|
break;
|
||||||
|
case "non_violation":
|
||||||
|
DoNonViolations = data == "true";
|
||||||
|
break;
|
||||||
case "enable_word_filter":
|
case "enable_word_filter":
|
||||||
DoCorrections = data == "true";
|
DoCorrections = data == "true";
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue