Added site generation to pom.xml

Fixed encoding of some files
This commit is contained in:
Butzlabben 2019-03-03 16:28:19 +01:00
parent 664f66e541
commit cbf41729a9
5 changed files with 143 additions and 135 deletions

14
pom.xml
View File

@ -8,7 +8,8 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.build.number>-</project.build.number>
<project.build.version>${project.version}
Build:${project.build.number}</project.build.version>
Build:${project.build.number}
</project.build.version>
</properties>
<reporting>
@ -18,6 +19,11 @@
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.0.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>2.6</version>
</plugin>
</plugins>
</reporting>
@ -28,7 +34,9 @@
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<excludes><exclude>LICENSE.txt</exclude></excludes>
<excludes>
<exclude>LICENSE.txt</exclude>
</excludes>
</resource>
</resources>
<plugins>
@ -51,7 +59,7 @@
<version>3.1.0</version>
<executions>
<execution>
<phase>package</phase>
<id>attach-javadocs</id>
<goals>
<goal>shade</goal>
</goals>

View File

@ -105,7 +105,7 @@ public class GuiConfig {
try {
return Material.valueOf(cfg.getString(path + ".material").toUpperCase());
} catch (IllegalArgumentException ex) {
Bukkit.getConsoleSender().sendMessage(PluginConfig.getPrefix() + "§cUnknown material: " + path);
Bukkit.getConsoleSender().sendMessage(PluginConfig.getPrefix() + "§cUnknown material: " + path);
return null;
}
}
@ -120,7 +120,7 @@ public class GuiConfig {
return new OrcItem(getMaterial(cfg, path), getDisplay(cfg, path), getLore(cfg, path));
} catch (Exception e) {
}
return OrcItem.error.clone().setDisplay("§c" + path);
return OrcItem.error.clone().setDisplay("§c" + path);
}
public static OrcItem getEnabled() {

View File

@ -36,7 +36,7 @@ public class PluginConfig {
file = f;
if (file.exists()) {
YamlConfiguration cfg = getConfig();
if (false == (cfg.isString("worldfolder") && cfg.isInt("unloadingtime")
if (!(cfg.isString("worldfolder") && cfg.isInt("unloadingtime")
&& cfg.isBoolean("survival") && cfg.isString("language") && cfg.isString("prefix")
&& cfg.isInt("request_expires") && cfg.isBoolean("need_confirm")
&& cfg.isBoolean("contact_authserver") && cfg.isBoolean("spawn_teleportation")
@ -88,7 +88,7 @@ public class PluginConfig {
// Should fix #2
if (getSpawn().getWorld() == null) {
Bukkit.getConsoleSender().sendMessage(getPrefix() + "§cWorld is null in spawn.world!");
Bukkit.getConsoleSender().sendMessage(getPrefix() + "§cWorld is null in spawn.world!");
}
}
@ -154,7 +154,7 @@ public class PluginConfig {
}
public static String getPrefix() {
return ChatColor.translateAlternateColorCodes('&', getConfig().getString("prefix", "§8[§3WorldSystem§8] §6"));
return ChatColor.translateAlternateColorCodes('&', getConfig().getString("prefix", "§8[§3WorldSystem§8] §6"));
}
public static Location getWorldSpawn(World w) {

View File

@ -11,7 +11,7 @@ public class ComingSoonClickListener implements OrcClickListener {
@Override
public void onClick(Player p, OrcInventory inv, OrcItem item) {
p.closeInventory();
p.sendMessage("§cComing soon...");
p.sendMessage("§cComing soon...");
}
}

View File

@ -207,7 +207,7 @@ public class SystemWorld {
// FileUtils.deleteDirectory(new
// File(Bukkit.getWorldContainer(), worldname));
// } catch (IOException e) {
// p.sendMessage(PluginConfig.getPrefix() + "§cError");
// p.sendMessage(PluginConfig.getPrefix() + "§cError");
// e.printStackTrace();
// }
}
@ -215,7 +215,7 @@ public class SystemWorld {
FileUtils.moveDirectoryToDirectory(world, Bukkit.getWorldContainer(), false);
} catch (IOException e) {
System.err.println("Couldn't load world of " + p.getName());
p.sendMessage(PluginConfig.getPrefix() + "§cError: " + e.getMessage());
p.sendMessage(PluginConfig.getPrefix() + "§cError: " + e.getMessage());
e.printStackTrace();
}
}
@ -302,7 +302,7 @@ public class SystemWorld {
try {
FileUtils.moveDirectoryToDirectory(world, Bukkit.getWorldContainer(), false);
} catch (IOException e) {
p.sendMessage(PluginConfig.getPrefix() + "§cError: " + e.getMessage());
p.sendMessage(PluginConfig.getPrefix() + "§cError: " + e.getMessage());
System.err.println("Couldn't load world of " + p.getName());
e.printStackTrace();
return false;