mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-02-16 10:30:42 +00:00
Fix minor Gaea related issues
This commit is contained in:
@@ -12,7 +12,7 @@ import java.io.Serializable;
|
||||
|
||||
public class SerializationUtil {
|
||||
public static Object fromFile(File f) throws IOException, ClassNotFoundException {
|
||||
ObjectInputStream ois = new MovedObjectInputStream(new FileInputStream(f), "com.dfsek.betterend.gaea", "com.dfsek.terra.api.gaea"); // Backwards compat with old BetterEnd shade location
|
||||
ObjectInputStream ois = new MovedObjectInputStream(new FileInputStream(f), "org.polydev.gaea", "com.dfsek.terra.api.gaea"); // Backwards compat with old Gaea location
|
||||
Object o = ois.readObject();
|
||||
ois.close();
|
||||
return o;
|
||||
|
||||
@@ -2,14 +2,11 @@ package com.dfsek.terra.command;
|
||||
|
||||
import com.dfsek.terra.api.gaea.command.Command;
|
||||
import com.dfsek.terra.config.lang.LangUtil;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
public class VersionCommand extends Command {
|
||||
public VersionCommand(Command parent) {
|
||||
@@ -28,12 +25,8 @@ public class VersionCommand extends Command {
|
||||
|
||||
@Override
|
||||
public boolean execute(@NotNull CommandSender sender, org.bukkit.command.@NotNull Command command, @NotNull String label, @NotNull String[] args) {
|
||||
Plugin gaea = Objects.requireNonNull(Bukkit.getPluginManager().getPlugin("Gaea"));
|
||||
String gaeaVersion = gaea.getDescription().getVersion();
|
||||
|
||||
String terraVersion = getMain().getDescription().getVersion();
|
||||
LangUtil.send("command.version", sender, terraVersion, gaeaVersion);
|
||||
|
||||
LangUtil.send("command.version", sender, terraVersion);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
name: "Terra"
|
||||
depend: [ "Gaea" ]
|
||||
main: "com.dfsek.terra.Terra"
|
||||
version: "@VERSION@"
|
||||
load: "STARTUP"
|
||||
|
||||
Reference in New Issue
Block a user