diff --git a/MCGalaxy/Chat/LineWrapper.cs b/MCGalaxy/Chat/LineWrapper.cs index 0b5211262..321723552 100644 --- a/MCGalaxy/Chat/LineWrapper.cs +++ b/MCGalaxy/Chat/LineWrapper.cs @@ -26,7 +26,7 @@ namespace MCGalaxy { message = Regex.Replace(message, @"(&[0-9a-f])+(&[0-9a-f])", "$2"); message = Regex.Replace(message, @"(&[0-9a-f])+$", ""); - int limit = 64; string color = ""; + int limit = NetUtils.StringSize; string color = ""; while ( message.Length > 0 ) { //if (Regex.IsMatch(message, "&a")) break; diff --git a/MCGalaxy/Economy/MessageItems.cs b/MCGalaxy/Economy/MessageItems.cs index 78d2861cc..fd16a5feb 100644 --- a/MCGalaxy/Economy/MessageItems.cs +++ b/MCGalaxy/Economy/MessageItems.cs @@ -40,7 +40,7 @@ namespace MCGalaxy.Eco { if (text == PlayerDB.GetLoginMessage(p)) { Player.Message(p, "%cYou already have that login message."); return; } - if (text.Length > 64) { + if (text.Length > NetUtils.StringSize) { Player.Message(p, "%cLogin message must be 64 characters or less."); return; } Command.all.Find("loginmessage").Use(null, p.name + " " + text); @@ -69,7 +69,7 @@ namespace MCGalaxy.Eco { if (text == PlayerDB.GetLogoutMessage(p)) { Player.Message(p, "%cYou already have that logout message."); return; } - if (text.Length > 64) { + if (text.Length > NetUtils.StringSize) { Player.Message(p, "%cLogin message must be 64 characters or less."); return; } Command.all.Find("logoutmessage").Use(null, p.name + " " + text); diff --git a/MCGalaxy/Player/Player.Handlers.cs b/MCGalaxy/Player/Player.Handlers.cs index 60f7cb2a7..8b19164c8 100644 --- a/MCGalaxy/Player/Player.Handlers.cs +++ b/MCGalaxy/Player/Player.Handlers.cs @@ -600,7 +600,7 @@ namespace MCGalaxy { } if (HasCpeExt(CpeExt.LongerMessages) && continued != 0) { - if (text.Length < 64) storedMessage = storedMessage + text + " "; + if (text.Length < NetUtils.StringSize) storedMessage = storedMessage + text + " "; else storedMessage = storedMessage + text; return true; }