From d308671441ce473bc2b56fa166d7a214aec980c6 Mon Sep 17 00:00:00 2001 From: Bryson Steck Date: Sun, 6 Jun 2021 00:15:30 -0600 Subject: allowing out folder for now --- .gitignore | 2 +- out/artifacts/Resurrection_jar/Resurrection.jar | Bin 0 -> 1615231 bytes .../DeadForADay/net/brysonsteck/DeadForADay.class | Bin 0 -> 1840 bytes .../DeadForADay/net/brysonsteck/PlayerData.class | Bin 0 -> 1749 bytes out/production/DeadForADay/net/brysonsteck/plugin.yml | 0 out/production/Resurrection/META-INF/MANIFEST.MF | 3 +++ .../net/brysonsteck/PlayerAttributes.class | Bin 0 -> 2079 bytes .../Resurrection/net/brysonsteck/PlayerData.class | Bin 0 -> 2006 bytes .../Resurrection/net/brysonsteck/PlayerListener.class | Bin 0 -> 1579 bytes .../Resurrection/net/brysonsteck/Resurrection.class | Bin 0 -> 760 bytes .../Resurrection/net/brysonsteck/plugin.yml | 3 +++ src/META-INF/MANIFEST.MF | 3 +++ src/net/brysonsteck/PlayerListener.java | 17 +++++++++++++++++ src/net/brysonsteck/Resurrection.java | 4 ++-- src/net/brysonsteck/plugin.yml | 3 +++ 15 files changed, 32 insertions(+), 3 deletions(-) create mode 100644 out/artifacts/Resurrection_jar/Resurrection.jar create mode 100644 out/production/DeadForADay/net/brysonsteck/DeadForADay.class create mode 100644 out/production/DeadForADay/net/brysonsteck/PlayerData.class create mode 100644 out/production/DeadForADay/net/brysonsteck/plugin.yml create mode 100644 out/production/Resurrection/META-INF/MANIFEST.MF create mode 100644 out/production/Resurrection/net/brysonsteck/PlayerAttributes.class create mode 100644 out/production/Resurrection/net/brysonsteck/PlayerData.class create mode 100644 out/production/Resurrection/net/brysonsteck/PlayerListener.class create mode 100644 out/production/Resurrection/net/brysonsteck/Resurrection.class create mode 100644 out/production/Resurrection/net/brysonsteck/plugin.yml create mode 100644 src/META-INF/MANIFEST.MF create mode 100644 src/net/brysonsteck/PlayerListener.java diff --git a/.gitignore b/.gitignore index e142237..e938891 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,3 @@ .idea/ -out/ + Resurrection.iml diff --git a/out/artifacts/Resurrection_jar/Resurrection.jar b/out/artifacts/Resurrection_jar/Resurrection.jar new file mode 100644 index 0000000..3669061 Binary files /dev/null and b/out/artifacts/Resurrection_jar/Resurrection.jar differ diff --git a/out/production/DeadForADay/net/brysonsteck/DeadForADay.class b/out/production/DeadForADay/net/brysonsteck/DeadForADay.class new file mode 100644 index 0000000..6fe8bca Binary files /dev/null and b/out/production/DeadForADay/net/brysonsteck/DeadForADay.class differ diff --git a/out/production/DeadForADay/net/brysonsteck/PlayerData.class b/out/production/DeadForADay/net/brysonsteck/PlayerData.class new file mode 100644 index 0000000..978e898 Binary files /dev/null and b/out/production/DeadForADay/net/brysonsteck/PlayerData.class differ diff --git a/out/production/DeadForADay/net/brysonsteck/plugin.yml b/out/production/DeadForADay/net/brysonsteck/plugin.yml new file mode 100644 index 0000000..e69de29 diff --git a/out/production/Resurrection/META-INF/MANIFEST.MF b/out/production/Resurrection/META-INF/MANIFEST.MF new file mode 100644 index 0000000..6af58fd --- /dev/null +++ b/out/production/Resurrection/META-INF/MANIFEST.MF @@ -0,0 +1,3 @@ +Manifest-Version: 1.0 +Main-Class: Resurrection + diff --git a/out/production/Resurrection/net/brysonsteck/PlayerAttributes.class b/out/production/Resurrection/net/brysonsteck/PlayerAttributes.class new file mode 100644 index 0000000..831949d Binary files /dev/null and b/out/production/Resurrection/net/brysonsteck/PlayerAttributes.class differ diff --git a/out/production/Resurrection/net/brysonsteck/PlayerData.class b/out/production/Resurrection/net/brysonsteck/PlayerData.class new file mode 100644 index 0000000..3b9818b Binary files /dev/null and b/out/production/Resurrection/net/brysonsteck/PlayerData.class differ diff --git a/out/production/Resurrection/net/brysonsteck/PlayerListener.class b/out/production/Resurrection/net/brysonsteck/PlayerListener.class new file mode 100644 index 0000000..feee780 Binary files /dev/null and b/out/production/Resurrection/net/brysonsteck/PlayerListener.class differ diff --git a/out/production/Resurrection/net/brysonsteck/Resurrection.class b/out/production/Resurrection/net/brysonsteck/Resurrection.class new file mode 100644 index 0000000..aca34c9 Binary files /dev/null and b/out/production/Resurrection/net/brysonsteck/Resurrection.class differ diff --git a/out/production/Resurrection/net/brysonsteck/plugin.yml b/out/production/Resurrection/net/brysonsteck/plugin.yml new file mode 100644 index 0000000..36632da --- /dev/null +++ b/out/production/Resurrection/net/brysonsteck/plugin.yml @@ -0,0 +1,3 @@ +main: net.brysonsteck.Resurrection +name: Resurrection +version: alpha 0.0.1 \ No newline at end of file diff --git a/src/META-INF/MANIFEST.MF b/src/META-INF/MANIFEST.MF new file mode 100644 index 0000000..6af58fd --- /dev/null +++ b/src/META-INF/MANIFEST.MF @@ -0,0 +1,3 @@ +Manifest-Version: 1.0 +Main-Class: Resurrection + diff --git a/src/net/brysonsteck/PlayerListener.java b/src/net/brysonsteck/PlayerListener.java new file mode 100644 index 0000000..8a57624 --- /dev/null +++ b/src/net/brysonsteck/PlayerListener.java @@ -0,0 +1,17 @@ +package net.brysonsteck; + +import org.bukkit.entity.Player; +import org.bukkit.event.EventHandler; +import org.bukkit.event.Listener; +import org.bukkit.event.entity.PlayerDeathEvent; + +public class PlayerListener implements Listener { + @EventHandler + public void onDeath(PlayerDeathEvent e) { + Player p = e.getEntity(); + Long timeOfDeath = System.currentTimeMillis(); + Long resurrectionTime = timeOfDeath + 86400000; + + p.sendMessage("You have died at " + timeOfDeath + ". You will respawn at " + resurrectionTime); + } +} diff --git a/src/net/brysonsteck/Resurrection.java b/src/net/brysonsteck/Resurrection.java index c4553e8..74fc8af 100644 --- a/src/net/brysonsteck/Resurrection.java +++ b/src/net/brysonsteck/Resurrection.java @@ -8,7 +8,7 @@ import java.io.*; import java.nio.Buffer; public class Resurrection extends JavaPlugin { - public Plugin plugin = getPlugin(Resurrection.class); +// public Plugin plugin = getPlugin(Resurrection.class); //spigot things @Override @@ -19,7 +19,7 @@ public class Resurrection extends JavaPlugin { @Override public void onEnable() { super.onEnable(); - + System.out.println("I'm alive!"); } // end of spigot things diff --git a/src/net/brysonsteck/plugin.yml b/src/net/brysonsteck/plugin.yml index e69de29..36632da 100644 --- a/src/net/brysonsteck/plugin.yml +++ b/src/net/brysonsteck/plugin.yml @@ -0,0 +1,3 @@ +main: net.brysonsteck.Resurrection +name: Resurrection +version: alpha 0.0.1 \ No newline at end of file -- cgit v1.2.3