Skip to content

Commit

Permalink
Merge pull request #1 from Jachou-yt/features
Browse files Browse the repository at this point in the history
Features
  • Loading branch information
Jachou-yt authored Oct 18, 2023
2 parents 01fb379 + e0c5924 commit b5995bb
Show file tree
Hide file tree
Showing 41 changed files with 221 additions and 2 deletions.
Binary file added server/logs/2023-10-14-6.log.gz
Binary file not shown.
Binary file added server/logs/2023-10-15-1.log.gz
Binary file not shown.
Binary file added server/logs/2023-10-15-2.log.gz
Binary file not shown.
Binary file added server/logs/2023-10-15-3.log.gz
Binary file not shown.
160 changes: 159 additions & 1 deletion server/logs/latest.log
Original file line number Diff line number Diff line change
@@ -1 +1,159 @@
[19:29:35] [ServerMain/INFO]: Environment: Environment[accountsHost=https://api.mojang.com, sessionHost=https://sessionserver.mojang.com, servicesHost=https://api.minecraftservices.com, name=PROD]
[17:33:41] [ServerMain/INFO]: Environment: Environment[accountsHost=https://api.mojang.com, sessionHost=https://sessionserver.mojang.com, servicesHost=https://api.minecraftservices.com, name=PROD]
[17:33:42] [ServerMain/INFO]: Loaded 7 recipes
[17:33:42] [Server thread/INFO]: Starting minecraft server version 1.20.2
[17:33:42] [Server thread/INFO]: Loading properties
[17:33:42] [Server thread/INFO]: This server is running CraftBukkit version 3915-Spigot-e0e223f-2a38185 (MC: 1.20.2) (Implementing API version 1.20.2-R0.1-SNAPSHOT)
[17:33:42] [Server thread/INFO]: Debug logging is disabled
[17:33:42] [Server thread/INFO]: Server Ping Player Sample Count: 12
[17:33:42] [Server thread/INFO]: Using 4 threads for Netty based IO
[17:33:42] [Server thread/INFO]: Default game type: SURVIVAL
[17:33:42] [Server thread/INFO]: Generating keypair
[17:33:42] [Server thread/INFO]: Starting Minecraft server on *:25565
[17:33:43] [Server thread/INFO]: Using default channel type
[17:33:43] [Server thread/WARN]: Initializing Legacy Material Support. Unless you have legacy plugins and/or data this is a bug!
[17:33:44] [Server thread/WARN]: Legacy plugin ReanimateMC valpha-1.0.2 does not specify an api-version.
[17:33:44] [Server thread/INFO]: [ReanimateMC] Loading ReanimateMC valpha-1.0.2
[17:33:44] [Server thread/INFO]: [ServerUtils] Loading ServerUtils v3.5.4
[17:33:44] [Server thread/WARN]: **** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!
[17:33:44] [Server thread/WARN]: The server will make no attempt to authenticate usernames. Beware.
[17:33:44] [Server thread/WARN]: While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose.
[17:33:44] [Server thread/WARN]: To change this, set "online-mode" to "true" in the server.properties file.
[17:33:44] [Server thread/INFO]: Preparing level "world"
[17:33:44] [Server thread/INFO]: -------- World Settings For [world] --------
[17:33:44] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true
[17:33:44] [Server thread/INFO]: Item Despawn Rate: 6000
[17:33:44] [Server thread/INFO]: Item Merge Radius: 2.5
[17:33:44] [Server thread/INFO]: View Distance: 10
[17:33:44] [Server thread/INFO]: Simulation Distance: 10
[17:33:44] [Server thread/INFO]: Nerfing mobs spawned from spawners: false
[17:33:44] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200
[17:33:44] [Server thread/INFO]: Cactus Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Cane Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Melon Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Mushroom Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Pumpkin Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Sapling Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Beetroot Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Carrot Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Potato Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Wheat Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: NetherWart Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Vine Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Cocoa Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Bamboo Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: SweetBerry Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Kelp Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: TwistingVines Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: WeepingVines Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: CaveVines Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Entity Activation Range: An 32 / Mo 32 / Ra 48 / Mi 16 / Tiv true / Isa false
[17:33:44] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Nether: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645
[17:33:44] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1 Hopper Can Load Chunks: false
[17:33:44] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Di 128 / Other 64
[17:33:44] [Server thread/INFO]: Max TNT Explosions: 100
[17:33:44] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms
[17:33:44] [Server thread/INFO]: Experience Merge Radius: 3.0
[17:33:44] [Server thread/INFO]: Mob Spawn Range: 6
[17:33:44] [Server thread/INFO]: Zombie Aggressive Towards Villager: true
[17:33:44] [Server thread/INFO]: -------- World Settings For [world_nether] --------
[17:33:44] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true
[17:33:44] [Server thread/INFO]: Item Despawn Rate: 6000
[17:33:44] [Server thread/INFO]: Item Merge Radius: 2.5
[17:33:44] [Server thread/INFO]: View Distance: 10
[17:33:44] [Server thread/INFO]: Simulation Distance: 10
[17:33:44] [Server thread/INFO]: Nerfing mobs spawned from spawners: false
[17:33:44] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200
[17:33:44] [Server thread/INFO]: Cactus Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Cane Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Melon Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Mushroom Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Pumpkin Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Sapling Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Beetroot Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Carrot Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Potato Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Wheat Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: NetherWart Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Vine Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Cocoa Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Bamboo Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: SweetBerry Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Kelp Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: TwistingVines Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: WeepingVines Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: CaveVines Growth Modifier: 100%
[17:33:44] [Server thread/INFO]: Entity Activation Range: An 32 / Mo 32 / Ra 48 / Mi 16 / Tiv true / Isa false
[17:33:44] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Nether: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645
[17:33:44] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1 Hopper Can Load Chunks: false
[17:33:44] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Di 128 / Other 64
[17:33:44] [Server thread/INFO]: Max TNT Explosions: 100
[17:33:44] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms
[17:33:44] [Server thread/INFO]: Experience Merge Radius: 3.0
[17:33:44] [Server thread/INFO]: Mob Spawn Range: 6
[17:33:44] [Server thread/INFO]: Zombie Aggressive Towards Villager: true
[17:33:45] [Server thread/INFO]: -------- World Settings For [world_the_end] --------
[17:33:45] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true
[17:33:45] [Server thread/INFO]: Item Despawn Rate: 6000
[17:33:45] [Server thread/INFO]: Item Merge Radius: 2.5
[17:33:45] [Server thread/INFO]: View Distance: 10
[17:33:45] [Server thread/INFO]: Simulation Distance: 10
[17:33:45] [Server thread/INFO]: Nerfing mobs spawned from spawners: false
[17:33:45] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200
[17:33:45] [Server thread/INFO]: Cactus Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Cane Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Melon Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Mushroom Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Pumpkin Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Sapling Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Beetroot Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Carrot Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Potato Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Wheat Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: NetherWart Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Vine Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Cocoa Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Bamboo Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: SweetBerry Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Kelp Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: TwistingVines Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: WeepingVines Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: CaveVines Growth Modifier: 100%
[17:33:45] [Server thread/INFO]: Entity Activation Range: An 32 / Mo 32 / Ra 48 / Mi 16 / Tiv true / Isa false
[17:33:45] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Nether: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645
[17:33:45] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1 Hopper Can Load Chunks: false
[17:33:45] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Di 128 / Other 64
[17:33:45] [Server thread/INFO]: Max TNT Explosions: 100
[17:33:45] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms
[17:33:45] [Server thread/INFO]: Experience Merge Radius: 3.0
[17:33:45] [Server thread/INFO]: Mob Spawn Range: 6
[17:33:45] [Server thread/INFO]: Zombie Aggressive Towards Villager: true
[17:33:45] [Server thread/INFO]: Preparing start region for dimension minecraft:overworld
[17:33:47] [Worker-Main-6/INFO]: Preparing spawn area: 0%
[17:33:47] [Worker-Main-6/INFO]: Preparing spawn area: 0%
[17:33:47] [Worker-Main-6/INFO]: Preparing spawn area: 0%
[17:33:47] [Worker-Main-6/INFO]: Preparing spawn area: 0%
[17:33:47] [Worker-Main-9/INFO]: Preparing spawn area: 1%
[17:33:47] [Server thread/INFO]: Time elapsed: 2409 ms
[17:33:47] [Server thread/INFO]: Preparing start region for dimension minecraft:the_nether
[17:33:49] [Worker-Main-3/INFO]: Preparing spawn area: 0%
[17:33:49] [Worker-Main-12/INFO]: Preparing spawn area: 0%
[17:33:49] [Worker-Main-8/INFO]: Preparing spawn area: 0%
[17:33:49] [Worker-Main-3/INFO]: Preparing spawn area: 0%
[17:33:49] [Worker-Main-2/INFO]: Preparing spawn area: 43%
[17:33:49] [Server thread/INFO]: Time elapsed: 2156 ms
[17:33:49] [Server thread/INFO]: Preparing start region for dimension minecraft:the_end
[17:33:51] [Worker-Main-12/INFO]: Preparing spawn area: 0%
[17:33:51] [Worker-Main-3/INFO]: Preparing spawn area: 0%
[17:33:51] [Worker-Main-4/INFO]: Preparing spawn area: 0%
[17:33:51] [Worker-Main-12/INFO]: Preparing spawn area: 0%
[17:33:51] [Worker-Main-3/INFO]: Preparing spawn area: 86%
[17:33:51] [Server thread/INFO]: Time elapsed: 2032 ms
[17:33:51] [Server thread/INFO]: [ReanimateMC] Enabling ReanimateMC valpha-1.0.2
[17:33:51] [Server thread/INFO]: [ReanimateMC] Plugin is up to date.
[17:33:51] [Server thread/INFO]: [ReanimateMC] Version: alpha-1.0.3
[17:33:51] [Server thread/INFO]: [ReanimateMC] You can download the latest version at https://modrinth.com/plugin/reanimatemc
[17:33:51] [Server thread/INFO]: [ServerUtils] Enabling ServerUtils v3.5.4
[17:33:52] [Server thread/INFO]: Server permissions file permissions.yml is empty, ignoring it
[17:33:52] [Server thread/INFO]: Done (7.715s)! For help, type "help"
[17:33:52] [Craft Scheduler Thread - 0/INFO]: [ServerUtils] Checking for updates...
[17:33:52] [Craft Scheduler Thread - 0/INFO]: [ServerUtils] We are up-to-date!
Binary file not shown.
2 changes: 1 addition & 1 deletion server/server.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#Minecraft server properties
#Sat Oct 14 19:29:35 CEST 2023
#Sun Oct 15 17:33:41 CEST 2023
allow-flight=false
allow-nether=true
broadcast-console-to-ops=true
Expand Down
Binary file modified server/world/data/raids.dat
Binary file not shown.
Binary file modified server/world/entities/r.-1.-1.mca
Binary file not shown.
Binary file modified server/world/entities/r.-1.0.mca
Binary file not shown.
Binary file modified server/world/entities/r.0.-1.mca
Binary file not shown.
Binary file modified server/world/entities/r.0.0.mca
Binary file not shown.
Binary file modified server/world/level.dat
Binary file not shown.
Binary file modified server/world/level.dat_old
Binary file not shown.
Binary file modified server/world/region/r.-1.-1.mca
Binary file not shown.
Binary file modified server/world/region/r.-1.0.mca
Binary file not shown.
Binary file modified server/world/region/r.0.-1.mca
Binary file not shown.
Binary file modified server/world/region/r.0.0.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/data/raids.dat
Binary file not shown.
Binary file modified server/world_nether/DIM-1/entities/r.-1.-1.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/entities/r.0.-1.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/entities/r.0.0.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/region/r.-1.-1.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/region/r.-1.0.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/region/r.0.-1.mca
Binary file not shown.
Binary file modified server/world_nether/DIM-1/region/r.0.0.mca
Binary file not shown.
Binary file modified server/world_nether/level.dat
Binary file not shown.
Binary file modified server/world_nether/level.dat_old
Binary file not shown.
Binary file modified server/world_the_end/DIM1/data/raids_end.dat
Binary file not shown.
Binary file modified server/world_the_end/DIM1/entities/r.-1.-1.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/entities/r.-1.0.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/entities/r.0.-1.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/entities/r.0.0.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/region/r.-1.-1.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/region/r.-1.0.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/region/r.0.-1.mca
Binary file not shown.
Binary file modified server/world_the_end/DIM1/region/r.0.0.mca
Binary file not shown.
Binary file modified server/world_the_end/level.dat
Binary file not shown.
Binary file modified server/world_the_end/level.dat_old
Binary file not shown.
9 changes: 9 additions & 0 deletions src/main/java/fr/jachou/reanimatemc/ReanimateMC.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import fr.jachou.reanimatemc.commands.KOCommand;
import fr.jachou.reanimatemc.commands.ReanimateCommand;
import fr.jachou.reanimatemc.events.PlayerEvents;
import fr.jachou.reanimatemc.update.VersionChecker;
import fr.jachou.reanimatemc.utils.KOPlayers;
import fr.jachou.reanimatemc.utils.Metrics;
import org.bukkit.Bukkit;
Expand All @@ -31,6 +32,14 @@ public void onEnable() {
// Plugin startup logic
instance = this;

if (VersionChecker.isUpToDate("alpha-1.0.2")) {
Bukkit.getConsoleSender().sendMessage(PREFIX + "§aPlugin is up to date.");
Bukkit.getConsoleSender().sendMessage(PREFIX + "§aVersion: " + VersionChecker.getLatestVersion());
Bukkit.getConsoleSender().sendMessage(PREFIX + "You can download the latest version at https://modrinth.com/plugin/reanimatemc");
} else {
Bukkit.getConsoleSender().sendMessage(PREFIX + "§c ReanimateMC running on the latest version.");
}


registerEvents(this);
registerCommands();
Expand Down
52 changes: 52 additions & 0 deletions src/main/java/fr/jachou/reanimatemc/update/VersionChecker.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
package fr.jachou.reanimatemc.update;

import fr.jachou.reanimatemc.ReanimateMC;
import org.bukkit.Bukkit;

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.HttpURLConnection;
import java.net.URL;

public class VersionChecker {
private static String checkVersion() {
String pasteBinUrl = "https://pastebin.com/raw/QRX6Y4C0";

try {
URL url = new URL(pasteBinUrl);
HttpURLConnection connection = (HttpURLConnection) url.openConnection();
connection.setRequestMethod("GET");

int responseCode = connection.getResponseCode();
if (responseCode == HttpURLConnection.HTTP_OK) {
BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
String inputLine;
StringBuilder content = new StringBuilder();
while ((inputLine = in.readLine()) != null) {
content.append(inputLine);
}
in.close();

return content.toString();
} else {
System.out.println(ReanimateMC.PREFIX + "Error while check update : " + responseCode);
return null;
}
} catch (Exception e) {
return null;
}
}

public static boolean isUpToDate(String thisVersion) {
String version = checkVersion();
if (version == null) {
Bukkit.getConsoleSender().sendMessage(ReanimateMC.PREFIX + "§cError while checking update.");
return false;
}
return !version.equals(thisVersion);
}

public static String getLatestVersion() {
return checkVersion();
}
}

0 comments on commit b5995bb

Please sign in to comment.