mirror of
https://github.com/darksaid98/AlathranWars.git
synced 2026-12-03 14:38:56 +00:00
Removing junk
This commit is contained in:
1 parent
421c6ac9a1
commit
49e4600d1b
2 files changed
+4
-27
No files matched your search
@@ -197,10 +197,6 @@ public class AdminCommands implements CommandExecutor {
|
|||||||
return fail(p, args, "syntax");
|
return fail(p, args, "syntax");
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean exclude(Player p, String[] args) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* //force end a war/event, can declare winner side, or no winner
|
* //force end a war/event, can declare winner side, or no winner
|
||||||
* -force end war [name] (side/victor)
|
* -force end war [name] (side/victor)
|
||||||
@@ -368,10 +364,7 @@ public class AdminCommands implements CommandExecutor {
|
|||||||
args[5],
|
args[5],
|
||||||
args[3]
|
args[3]
|
||||||
};
|
};
|
||||||
//find the player
|
|
||||||
Player target = p;
|
|
||||||
if (Bukkit.getPlayer(args[3]) != null) {
|
if (Bukkit.getPlayer(args[3]) != null) {
|
||||||
target = Bukkit.getPlayer(args[3]);
|
|
||||||
} else {
|
} else {
|
||||||
p.sendMessage(Helper.color("c") + args[3] + " does not exist!");
|
p.sendMessage(Helper.color("c") + args[3] + " does not exist!");
|
||||||
p.sendMessage(Helper.color("&cUsage: /alathrawaradmin force join war [player] [war] [side]"));
|
p.sendMessage(Helper.color("&cUsage: /alathrawaradmin force join war [player] [war] [side]"));
|
||||||
@@ -1617,12 +1610,6 @@ public class AdminCommands implements CommandExecutor {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private static boolean rule(Player p, String[] args) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
private static boolean awa(Player p, String[] args) {
|
private static boolean awa(Player p, String[] args) {
|
||||||
p.chat("awa awa! ^.^ UwU");
|
p.chat("awa awa! ^.^ UwU");
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@@ -13,22 +13,11 @@ import org.bukkit.Bukkit;
|
|||||||
import org.bukkit.OfflinePlayer;
|
import org.bukkit.OfflinePlayer;
|
||||||
|
|
||||||
import javax.annotation.Nonnull;
|
import javax.annotation.Nonnull;
|
||||||
import java.io.File;
|
|
||||||
import java.io.FilenameFilter;
|
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
|
|
||||||
public class RaidData {
|
public class RaidData {
|
||||||
// Static Raid list for all active raids
|
// Static Raid list for all active raids
|
||||||
private static ArrayList<Raid> raids = new ArrayList<Raid>();
|
private static ArrayList<Raid> raids = new ArrayList<Raid>();
|
||||||
private final static String dataFolderPath = "plugins" + File.separator + "AlathraWar" + File.separator + "data";
|
|
||||||
|
|
||||||
// Filter for only accessing yml files
|
|
||||||
private static FilenameFilter ymlFilter = new FilenameFilter() {
|
|
||||||
@Override
|
|
||||||
public boolean accept(File dir, String name) {
|
|
||||||
return name.endsWith(".yml");
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static ArrayList<Raid> getRaids() {
|
public static ArrayList<Raid> getRaids() {
|
||||||
return raids;
|
return raids;
|
||||||
@@ -220,9 +209,10 @@ public class RaidData {
|
|||||||
* @return
|
* @return
|
||||||
* @Isaac this is for getting when the last raid was on a town
|
* @Isaac this is for getting when the last raid was on a town
|
||||||
*/
|
*/
|
||||||
|
@SuppressWarnings("rawtypes")
|
||||||
public static long whenTownLastRaided(Town town) {
|
public static long whenTownLastRaided(Town town) {
|
||||||
if (town.hasMeta("lastRaided")) {
|
if (town.hasMeta("AlathraWar-lastRaided")) {
|
||||||
CustomDataField field = town.getMetadata("lastRaided");
|
CustomDataField field = town.getMetadata("AlathraWar-lastRaided");
|
||||||
if (field != null) {
|
if (field != null) {
|
||||||
if (field instanceof LongDataField) {
|
if (field instanceof LongDataField) {
|
||||||
return ((LongDataField) field).getValue();
|
return ((LongDataField) field).getValue();
|
||||||
@@ -230,7 +220,7 @@ public class RaidData {
|
|||||||
}
|
}
|
||||||
return -1L;
|
return -1L;
|
||||||
} else {
|
} else {
|
||||||
town.addMetaData(new LongDataField("lastRaided", 0L));
|
town.addMetaData(new LongDataField("AlathraWar-lastRaided", 0L));
|
||||||
}
|
}
|
||||||
return -1L;
|
return -1L;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user