This commit is contained in:
nossr50 2011-01-05 10:51:43 -08:00
parent af1f52baaf
commit 1fd278a3c9

View File

@ -92,7 +92,6 @@ public class vChat {
+ " has you on their ignore list.");
return;
}
String[] message = applyColors(wordWrap(msg));
for(String out : message)
receiver.sendMessage(out);
@ -172,7 +171,7 @@ public class vChat {
//and their following color codes
for(int x = 0; x<str.length(); x++)
{
if(str.charAt(x) == '^' || str.charAt(x) == Colors.White.charAt(0))
if((x+1 <= str.length()) && (str.charAt(x) == '^' || str.charAt(x) == Colors.White.charAt(0)))
{
if(colorChange(str.charAt(x + 1)) != null)
{
@ -321,7 +320,7 @@ public class vChat {
//=====================================================================
public static String colorChange(char colour)
{
String color = "";
String color;
switch(colour)
{
case '0':