13.6
This commit is contained in:
parent
e4c4aee0f7
commit
deeedcd408
2
pom.xml
2
pom.xml
@ -6,7 +6,7 @@
|
||||
|
||||
<groupId>net.t2code</groupId>
|
||||
<artifactId>T2CodeLib</artifactId>
|
||||
<version>13.5</version>
|
||||
<version>13.6</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>T2CodeLib</name>
|
||||
|
@ -5,6 +5,7 @@ import net.t2code.t2codelib.SPIGOT.system.T2CodeLibMain;
|
||||
import net.t2code.t2codelib.UpdateType;
|
||||
import net.t2code.t2codelib.T2CupdateObject;
|
||||
import net.t2code.t2codelib.T2CupdateWebData;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
import org.bukkit.plugin.java.JavaPlugin;
|
||||
@ -16,6 +17,15 @@ public class T2CupdateAPI {
|
||||
public static HashMap<String, T2CupdateObject> pluginVersions = new HashMap<>();
|
||||
|
||||
public static void join(Plugin plugin, String prefix, String perm, Player player, Integer spigotID, String discord) {
|
||||
if (pluginVersions.get(plugin.getName()) == null){
|
||||
Bukkit.getScheduler().runTaskLaterAsynchronously(T2CodeLibMain.getPlugin(), new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
join(plugin,prefix,perm,player,spigotID,discord);
|
||||
}
|
||||
},2*20L);
|
||||
}
|
||||
|
||||
if (!pluginVersions.get(plugin.getName()).updateCheckOnJoin) {
|
||||
return;
|
||||
}
|
||||
|
@ -143,15 +143,14 @@ public class CreateReportLog {
|
||||
file.delete();
|
||||
File zipFile = new File(zipPath);
|
||||
|
||||
if (!confirmUpload){
|
||||
if (sender instanceof Player) {
|
||||
T2Csend.sender(sender, Util.getPrefix() + " §6A DebugLog zip has been created. you can find it on in the files on your server under the path: §e" + zipPath);
|
||||
}
|
||||
T2Csend.console(Util.getPrefix() + " §6A DebugLog zip has been created. you can find it on in the files on your server under the path: §e" + zipPath);
|
||||
|
||||
Files.move(Paths.get(zipPath),Paths.get(directory+"/"+zipFile.getName()));
|
||||
if (!confirmUpload) {
|
||||
Files.move(Paths.get(zipPath), Paths.get(directory + "/" + zipFile.getName()));
|
||||
zipFile.delete();
|
||||
directoryTemp.delete();
|
||||
if (sender instanceof Player) {
|
||||
T2Csend.sender(sender, Util.getPrefix() + " §6A DebugLog zip has been created. you can find it on in the files on your server under the path: §e" + directory + "/" + zipFile.getName());
|
||||
}
|
||||
T2Csend.console(Util.getPrefix() + " §6A DebugLog zip has been created. you can find it on in the files on your server under the path: §e" + directory + "/" + zipFile.getName());
|
||||
return;
|
||||
}
|
||||
|
||||
@ -179,7 +178,7 @@ public class CreateReportLog {
|
||||
"<br>[prefix] <dark_red>Do not share the download URL with anyone!</dark_red>" +
|
||||
"<br><hover:show_text:'<yellow>Click to delete</yellow>'><click:run_command:'/t2code debug deleteReportLog [key]'>[prefix] <green>You can <b>delte</b> yor Debug-File by clicking me.</green>" +
|
||||
"<br>[prefix] <color:#910d06>(If you do not delete the debug file, it will be deleted automatically after <red>14</red> days!)</color></click></hover>")
|
||||
.replace("[key]", fileID).replace("[url]", downloadURL).replace("[prefix]",Util.getPrefix()));
|
||||
.replace("[key]", fileID).replace("[url]", downloadURL).replace("[prefix]", Util.getPrefix()));
|
||||
}
|
||||
T2Csend.console(Util.getPrefix() + (" <gold>A DebugLog zip has been created. You can download it here:</gold> <yellow>[url]</yellow>" +
|
||||
"<br><gold>Please enter the following key in the ticket:</gold> <yellow>[key]</yellow>." +
|
||||
|
Loading…
Reference in New Issue
Block a user