Merge branch 'development'

This commit is contained in:
Brianna 2020-12-16 10:02:18 -06:00
commit 9c9599880e
20 changed files with 46 additions and 19 deletions

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../</relativePath>
</parent>

View File

@ -53,7 +53,7 @@ public class SongodaCore {
/**
* This has been added as of Rev 6
*/
private final static String coreVersion = "2.4.28";
private final static String coreVersion = "2.4.29";
/**
* This is specific to the website api

View File

@ -32,6 +32,33 @@ public class TextUtils {
return list.stream().map(TextUtils::formatText).collect(Collectors.toList());
}
public static List<String> wrap(String line) {
return wrap(null, line);
}
public static List<String> wrap(String color, String line) {
if (color != null)
color = "&" + color;
else
color = "";
List<String> lore = new ArrayList<>();
int lastIndex = 0;
for (int n = 0; n < line.length(); n++) {
if (n - lastIndex < 25)
continue;
if (line.charAt(n) == ' ') {
lore.add(TextUtils.formatText(color + TextUtils.formatText(line.substring(lastIndex, n))));
lastIndex = n;
}
}
if (lastIndex - line.length() < 25)
lore.add(TextUtils.formatText(color + TextUtils.formatText(line.substring(lastIndex))));
return lore;
}
/**
* Convert a string to an invisible colored string that's lore-safe <br />

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -3,7 +3,7 @@
<parent>
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<relativePath>../../</relativePath>
</parent>

View File

@ -2,7 +2,7 @@
<groupId>com.songoda</groupId>
<artifactId>SongodaCore-Modules</artifactId>
<version>2.4.28</version>
<version>2.4.29</version>
<modelVersion>4.0.0</modelVersion>
<packaging>pom</packaging>