geforkt von SteamWar/BungeeCore
Fixing symlinks on world reset
Dieser Commit ist enthalten in:
Ursprung
bdf5ec20c6
Commit
736cdcdf36
17
pom.xml
17
pom.xml
@ -32,18 +32,6 @@
|
|||||||
</resource>
|
</resource>
|
||||||
</resources>
|
</resources>
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-shade-plugin</artifactId>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<phase>package</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>shade</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
@ -63,10 +51,5 @@
|
|||||||
<type>jar</type>
|
<type>jar</type>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
|
||||||
<groupId>commons-io</groupId>
|
|
||||||
<artifactId>commons-io</artifactId>
|
|
||||||
<version>2.6</version>
|
|
||||||
</dependency>
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
</project>
|
</project>
|
@ -3,7 +3,6 @@ package de.steamwar.bungeecore.bausystem;
|
|||||||
import de.steamwar.bungeecore.BungeeCore;
|
import de.steamwar.bungeecore.BungeeCore;
|
||||||
import de.steamwar.bungeecore.sql.Bauwelt;
|
import de.steamwar.bungeecore.sql.Bauwelt;
|
||||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||||
import org.apache.commons.io.FileUtils;
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
@ -40,8 +39,12 @@ public class BauSystem {
|
|||||||
File w = new File(BungeeCore.WorldFolder + owner);
|
File w = new File(BungeeCore.WorldFolder + owner);
|
||||||
if (!w.exists() || !w.isDirectory()){
|
if (!w.exists() || !w.isDirectory()){
|
||||||
try {
|
try {
|
||||||
FileUtils.copyDirectory(new File(BungeeCore.BauweltPrototyp), w);
|
Process pr;
|
||||||
} catch (IOException e) {
|
ProcessBuilder pb = new ProcessBuilder(
|
||||||
|
"cp", "-r", BungeeCore.BauweltPrototyp, BungeeCore.WorldFolder + owner);
|
||||||
|
pr = pb.start();
|
||||||
|
pr.waitFor();
|
||||||
|
} catch (InterruptedException | IOException e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
p.sendMessage(BungeeCore.ChatPrefix + "§cDas Erstellen der Welt ist fehlgeschlagen.");
|
p.sendMessage(BungeeCore.ChatPrefix + "§cDas Erstellen der Welt ist fehlgeschlagen.");
|
||||||
return;
|
return;
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren