SteamWar/FightSystem
Archiviert
13
1

Merge branch 'master' into coreHider

Dieser Commit ist enthalten in:
Lixfel 2022-07-16 10:17:02 +02:00
Commit 8c9f93ef38
12 geänderte Dateien mit 64 neuen und 27 gelöschten Zeilen

Datei anzeigen

@ -44,7 +44,7 @@ sourceSets {
dependencies { dependencies {
implementation project(":FightSystem_Core") implementation project(":FightSystem_Core")
compileOnly files("${projectDir}/../lib/Spigot-1.10.jar") compileOnly swdep("Spigot-1.10")
compileOnly files("${projectDir}/../lib/WorldEdit-1.12.jar") compileOnly swdep("WorldEdit-1.12")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -45,7 +45,7 @@ dependencies {
implementation project(":FightSystem_Core") implementation project(":FightSystem_Core")
implementation project(":FightSystem_8") implementation project(":FightSystem_8")
compileOnly files("${projectDir}/../lib/Spigot-1.12.jar") compileOnly swdep("Spigot-1.12")
compileOnly files("${projectDir}/../lib/WorldEdit-1.12.jar") compileOnly swdep("WorldEdit-1.12")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -46,7 +46,7 @@ dependencies {
implementation project(":FightSystem_9") implementation project(":FightSystem_9")
implementation project(":FightSystem_8") implementation project(":FightSystem_8")
compileOnly files("${projectDir}/../lib/Spigot-1.14.jar") compileOnly swdep("Spigot-1.14")
compileOnly files("${projectDir}/../lib/WorldEdit-1.15.jar") compileOnly swdep("WorldEdit-1.15")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -44,7 +44,7 @@ sourceSets {
dependencies { dependencies {
implementation project(":FightSystem_Core") implementation project(":FightSystem_Core")
compileOnly files("${projectDir}/../lib/Spigot-1.15.jar") compileOnly swdep("Spigot-1.15")
compileOnly files("${projectDir}/../lib/WorldEdit-1.15.jar") compileOnly swdep("WorldEdit-1.15")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -49,7 +49,7 @@ dependencies {
compileOnly 'io.netty:netty-all:4.1.68.Final' compileOnly 'io.netty:netty-all:4.1.68.Final'
compileOnly 'com.mojang:authlib:1.5.25' compileOnly 'com.mojang:authlib:1.5.25'
compileOnly files("${projectDir}/../lib/Spigot-1.18.jar") compileOnly swdep("Spigot-1.18")
compileOnly files("${projectDir}/../lib/WorldEdit-1.15.jar") compileOnly swdep("WorldEdit-1.15")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -50,7 +50,7 @@ dependencies {
compileOnly 'io.netty:netty-all:4.1.68.Final' compileOnly 'io.netty:netty-all:4.1.68.Final'
compileOnly 'com.mojang:authlib:1.5.25' compileOnly 'com.mojang:authlib:1.5.25'
compileOnly files("${projectDir}/../lib/Spigot-1.19.jar") compileOnly swdep("Spigot-1.19")
compileOnly files("${projectDir}/../lib/WorldEdit-1.15.jar") compileOnly swdep("WorldEdit-1.15")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -44,7 +44,7 @@ sourceSets {
dependencies { dependencies {
implementation project(":FightSystem_Core") implementation project(":FightSystem_Core")
compileOnly files("${projectDir}/../lib/Spigot-1.8.jar") compileOnly swdep("Spigot-1.8")
compileOnly files("${projectDir}/../lib/WorldEdit-1.12.jar") compileOnly swdep("WorldEdit-1.12")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -45,7 +45,7 @@ dependencies {
implementation project(":FightSystem_Core") implementation project(":FightSystem_Core")
implementation project(":FightSystem_8") implementation project(":FightSystem_8")
compileOnly files("${projectDir}/../lib/Spigot-1.9.jar") compileOnly swdep("Spigot-1.9")
compileOnly files("${projectDir}/../lib/WorldEdit-1.12.jar") compileOnly swdep("WorldEdit-1.12")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -47,6 +47,6 @@ dependencies {
compileOnly 'io.netty:netty-all:4.1.68.Final' compileOnly 'io.netty:netty-all:4.1.68.Final'
compileOnly 'com.mojang:authlib:1.5.25' compileOnly 'com.mojang:authlib:1.5.25'
compileOnly files("${projectDir}/../lib/WorldEdit-1.15.jar") compileOnly swdep("WorldEdit-1.15")
compileOnly files("${projectDir}/../lib/SpigotCore.jar") compileOnly swdep("SpigotCore")
} }

Datei anzeigen

@ -29,10 +29,12 @@ import de.steamwar.fightsystem.states.FightState;
import de.steamwar.fightsystem.states.StateDependentListener; import de.steamwar.fightsystem.states.StateDependentListener;
import net.md_5.bungee.api.ChatMessageType; import net.md_5.bungee.api.ChatMessageType;
import org.bukkit.GameMode; import org.bukkit.GameMode;
import org.bukkit.Material;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.EventPriority; import org.bukkit.event.EventPriority;
import org.bukkit.event.Listener; import org.bukkit.event.Listener;
import org.bukkit.event.block.BlockFromToEvent;
import org.bukkit.event.entity.FoodLevelChangeEvent; import org.bukkit.event.entity.FoodLevelChangeEvent;
import org.bukkit.event.entity.PlayerDeathEvent; import org.bukkit.event.entity.PlayerDeathEvent;
import org.bukkit.event.entity.SpawnerSpawnEvent; import org.bukkit.event.entity.SpawnerSpawnEvent;
@ -147,4 +149,19 @@ public class Permanent implements Listener {
if(!Config.ArenaLeaveable) if(!Config.ArenaLeaveable)
e.getWorld().setAutoSave(false); e.getWorld().setAutoSave(false);
} }
@EventHandler
public void onBlockFromTo(BlockFromToEvent event) {
if(!event.getBlock().getType().equals(Material.DRAGON_EGG)) return;
for (FightTeam team : Fight.teams()) {
if(team.getExtendRegion().inRegion(event.getBlock())){
if(team.getExtendRegion().inRegion(event.getToBlock())) return;
}
}
event.setCancelled(true);
}
} }

Datei anzeigen

@ -61,7 +61,7 @@ dependencies {
} }
} }
implementation files("${projectDir}/../lib/SpigotCore.jar") implementation swdep("SpigotCore")
} }
task fixPluginYML(type: Copy) { task fixPluginYML(type: Copy) {

Datei anzeigen

@ -35,6 +35,18 @@ plugins {
id 'com.github.johnrengelman.shadow' version '5.0.0' id 'com.github.johnrengelman.shadow' version '5.0.0'
} }
ext.swdep = { s ->
if (file("${rootDir}/lib/${s}.jar").exists()) {
return files("${rootDir}/lib/${s}.jar")
} else {
if (s.contains("-")) {
return "de.steamwar:${s.toLowerCase().replace('-', ':')}"
} else {
return "de.steamwar:${s.toLowerCase()}:RELEASE"
}
}
}
group 'de.steamwar' group 'de.steamwar'
version '' version ''
@ -82,6 +94,14 @@ allprojects {
maven { maven {
url = uri('https://libraries.minecraft.net') url = uri('https://libraries.minecraft.net')
} }
maven {
url = uri('https://steamwar.de/maven')
credentials {
username = steamwarProperties.getProperty("maven.username")
password = steamwarProperties.getProperty("maven.password")
}
}
} }
} }