From e5bbe641edc143fde446e05f2517f9f593b666a6 Mon Sep 17 00:00:00 2001 From: aPunch Date: Tue, 20 Mar 2012 20:10:32 -0500 Subject: [PATCH] Convert to maven --- .gitignore | 5 +- .settings/org.eclipse.jdt.core.prefs | 8 +-- .settings/org.eclipse.m2e.core.prefs | 4 ++ pom.xml | 60 +++++++++++++++++++ .../net/apunch/blacksmith/Blacksmith.java | 13 ++-- .../apunch/blacksmith/BlacksmithPlugin.java | 0 .../net/apunch/blacksmith/ReforgeSession.java | 0 .../net/apunch/blacksmith/util/Settings.java | 0 plugin.yml => src/main/resources/plugin.yml | 0 9 files changed, 78 insertions(+), 12 deletions(-) create mode 100644 .settings/org.eclipse.m2e.core.prefs create mode 100644 pom.xml rename src/{ => main/java}/net/apunch/blacksmith/Blacksmith.java (95%) rename src/{ => main/java}/net/apunch/blacksmith/BlacksmithPlugin.java (100%) rename src/{ => main/java}/net/apunch/blacksmith/ReforgeSession.java (100%) rename src/{ => main/java}/net/apunch/blacksmith/util/Settings.java (100%) rename plugin.yml => src/main/resources/plugin.yml (100%) diff --git a/.gitignore b/.gitignore index f46e6a5..b2a0e87 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,4 @@ /bin -/build /target .classpath -.project -Blacksmith.jar -build.xml \ No newline at end of file +.project \ No newline at end of file diff --git a/.settings/org.eclipse.jdt.core.prefs b/.settings/org.eclipse.jdt.core.prefs index f931203..8e4055a 100644 --- a/.settings/org.eclipse.jdt.core.prefs +++ b/.settings/org.eclipse.jdt.core.prefs @@ -1,12 +1,12 @@ -#Thu Feb 09 16:52:58 CST 2012 eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.compliance=1.5 org.eclipse.jdt.core.compiler.debug.lineNumber=generate org.eclipse.jdt.core.compiler.debug.localVariable=generate org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.source=1.5 diff --git a/.settings/org.eclipse.m2e.core.prefs b/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 0000000..f897a7f --- /dev/null +++ b/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..15d7087 --- /dev/null +++ b/pom.xml @@ -0,0 +1,60 @@ + + + + 4.0.0 + + net.apunch + blacksmith + 1.0-SNAPSHOT + Blacksmith + Blacksmith Character for the CitizensAPI + + + + UTF-8 + 1.2.3-R0.3-SNAPSHOT + 2.0-SNAPSHOT + 1.2.13-SNAPSHOT + Unknown + + + + + + bukkit-repo + http://repo.bukkit.org/content/groups/public/ + + + citizens-repo + http://repo.citizensnpcs.net/ + + + vault-repo + http://ci.milkbowl.net/plugin/repository/everything + + + + + + + org.bukkit + bukkit + ${bukkit.version} + provided + + + net.citizensnpcs + citizensapi + ${citizensapi.version} + provided + + + net.milkbowl.vault + Vault + ${vault.version} + provided + + + + \ No newline at end of file diff --git a/src/net/apunch/blacksmith/Blacksmith.java b/src/main/java/net/apunch/blacksmith/Blacksmith.java similarity index 95% rename from src/net/apunch/blacksmith/Blacksmith.java rename to src/main/java/net/apunch/blacksmith/Blacksmith.java index 04672f8..b12300d 100644 --- a/src/net/apunch/blacksmith/Blacksmith.java +++ b/src/main/java/net/apunch/blacksmith/Blacksmith.java @@ -125,8 +125,10 @@ public class Blacksmith extends Character { return; } session = new ReforgeSession(player, npc); - npc.chat(player, costMsg.replace("", plugin.formatCost(player)).replace("", - hand.getType().name().toLowerCase().replace('_', ' '))); + npc.chat( + player, + costMsg.replace("", plugin.formatCost(player)).replace("", + hand.getType().name().toLowerCase().replace('_', ' '))); } } @@ -160,8 +162,11 @@ public class Blacksmith extends Character { private void reforge(NPC npc, Player player) { npc.chat(player, startReforgeMsg); plugin.withdraw(player); - session.setTask(plugin.getServer().getScheduler().scheduleAsyncDelayedTask(plugin, - new ReforgeTask(npc, player), (new Random().nextInt(maxReforgeDelay) + minReforgeDelay) * 20)); + session.setTask(plugin + .getServer() + .getScheduler() + .scheduleAsyncDelayedTask(plugin, new ReforgeTask(npc, player), + (new Random().nextInt(maxReforgeDelay) + minReforgeDelay) * 20)); if (npc.getBukkitEntity() instanceof Player) ((Player) npc.getBukkitEntity()).setItemInHand(player.getItemInHand()); player.setItemInHand(null); diff --git a/src/net/apunch/blacksmith/BlacksmithPlugin.java b/src/main/java/net/apunch/blacksmith/BlacksmithPlugin.java similarity index 100% rename from src/net/apunch/blacksmith/BlacksmithPlugin.java rename to src/main/java/net/apunch/blacksmith/BlacksmithPlugin.java diff --git a/src/net/apunch/blacksmith/ReforgeSession.java b/src/main/java/net/apunch/blacksmith/ReforgeSession.java similarity index 100% rename from src/net/apunch/blacksmith/ReforgeSession.java rename to src/main/java/net/apunch/blacksmith/ReforgeSession.java diff --git a/src/net/apunch/blacksmith/util/Settings.java b/src/main/java/net/apunch/blacksmith/util/Settings.java similarity index 100% rename from src/net/apunch/blacksmith/util/Settings.java rename to src/main/java/net/apunch/blacksmith/util/Settings.java diff --git a/plugin.yml b/src/main/resources/plugin.yml similarity index 100% rename from plugin.yml rename to src/main/resources/plugin.yml