mirror of
https://github.com/BentoBoxWorld/Challenges.git
synced 2024-11-29 22:13:22 +01:00
Fix issue when Description separator loses selected color (#77)
This commit is contained in:
parent
ab3275cd69
commit
8f3beb4c1d
@ -385,6 +385,17 @@ public class GuiUtils
|
|||||||
map(line -> Arrays.asList(WordUtils.wrap(line, warpLength).split(System.getProperty("line.separator")))).
|
map(line -> Arrays.asList(WordUtils.wrap(line, warpLength).split(System.getProperty("line.separator")))).
|
||||||
forEach(result::addAll);
|
forEach(result::addAll);
|
||||||
|
|
||||||
|
// Fix colors, as splitting my lost that information.
|
||||||
|
|
||||||
|
for (int i = 0, resultSize = result.size(); i < resultSize; i++)
|
||||||
|
{
|
||||||
|
if (i > 0)
|
||||||
|
{
|
||||||
|
String lastColor = ChatColor.getLastColors(result.get(i - 1));
|
||||||
|
result.set(i, lastColor + result.get(i));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user