-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 6efdd9e
Showing
7 changed files
with
489 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
/nbproject/private/ | ||
/dist/lib/ | ||
/test-in-spigot.bat | ||
/lib/ | ||
/target/ | ||
/build/ | ||
/dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# WGItemFrameBreakFlags | ||
|
||
Requires Worldguard 7 and a 1.16+ server. Other configurations are untested. | ||
|
||
This plugin was specifically made because if the following behavior in spigot https://hub.spigotmc.org/jira/browse/SPIGOT-3999 | ||
which means Worldguard does not catch Physics events causes by Boats, as well as other Removal Causes ( https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/event/hanging/HangingBreakEvent.RemoveCause.html ) | ||
|
||
This plugin serves to cover these specific cases by adding flags for each but cannot and will not implement any more exhaustive checks on the source of the event. | ||
|
||
|
||
Adds: | ||
|
||
* `default-item-frame-destroy` for unknown causes | ||
* `explosion-item-frame-destroy` for explosion-caused item frame destruction | ||
* `obstruction-item-frame-destroy` for when block placement would cause the item frame to break | ||
* `physics-item-frame-destroy` for when physics or bounding boxes (like those of a Boat) cause the item frame to break. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
/* | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/ . | ||
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,238 @@ | ||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<groupId>com.github.crashdemons</groupId> | ||
<artifactId>WGItemFrameBreakFlags</artifactId> | ||
<version>0.0.1-SNAPSHOT</version> | ||
<packaging>jar</packaging> | ||
|
||
<name>WGItemFrameBreakFlags</name> | ||
|
||
<properties> | ||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
</properties> | ||
|
||
<repositories> | ||
<repository> | ||
<id>mojang</id> | ||
<name>Mojang's Repository</name> | ||
<url>https://libraries.minecraft.net/</url> | ||
</repository> | ||
<repository> | ||
<id>spigot-repo</id> | ||
<url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url> | ||
</repository> | ||
<repository> | ||
<id>md_5-releases</id> | ||
<url>http://repo.md-5.net/content/repositories/releases/</url> | ||
</repository> | ||
<repository> | ||
<id>spigot-group-repo</id> | ||
<url>https://hub.spigotmc.org/nexus/content/groups/public/</url> | ||
</repository> | ||
<repository> | ||
<id>crashdemons-repo</id> | ||
<url>https://meme.tips/java-repos/</url> | ||
</repository> | ||
<repository> | ||
<id>sk89q-repo</id> | ||
<url>http://maven.sk89q.com/repo/</url> | ||
</repository> | ||
</repositories> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.spigotmc</groupId> | ||
<artifactId>spigot-api</artifactId> | ||
<version>1.16.5-R0.1-SNAPSHOT</version> | ||
<!-- | ||
<exclusions> | ||
<exclusion> | ||
<groupId>*</groupId> | ||
<artifactId>*</artifactId> | ||
</exclusion> | ||
</exclusions> | ||
--> | ||
</dependency> | ||
<dependency> | ||
<groupId>com.sk89q.worldguard</groupId> | ||
<artifactId>worldguard-bukkit</artifactId> | ||
<version>7.0.4</version> | ||
<exclusions> | ||
<exclusion> | ||
<groupId>org.bukkit</groupId> | ||
<artifactId>bukkit</artifactId> | ||
</exclusion> | ||
<exclusion> | ||
<groupId>org.spigotmc</groupId> | ||
<artifactId>spigot-api</artifactId> | ||
</exclusion> | ||
</exclusions> | ||
</dependency> | ||
|
||
|
||
<dependency> | ||
<groupId>org.jetbrains</groupId> | ||
<artifactId>annotations-java5</artifactId> | ||
<version>15.0</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>junit</groupId> | ||
<artifactId>junit</artifactId> | ||
<version>4.13.1</version> | ||
<type>jar</type> | ||
<scope>test</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.powermock</groupId> | ||
<artifactId>powermock-module-junit4</artifactId> | ||
<version>2.0.7</version> | ||
<type>jar</type> | ||
<scope>test</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.powermock</groupId> | ||
<artifactId>powermock-api-mockito2</artifactId> | ||
<version>2.0.7</version> | ||
<type>jar</type> | ||
<scope>test</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.mockito</groupId> | ||
<artifactId>mockito-core</artifactId> | ||
<version>3.5.11</version> | ||
<scope>test</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.powermock</groupId> | ||
<artifactId>powermock-api-mockito-common</artifactId> | ||
<version>1.7.4</version> | ||
<scope>test</scope> | ||
</dependency> | ||
</dependencies> | ||
|
||
|
||
|
||
<build> | ||
<finalName>${project.name}-${project.version}</finalName> | ||
<resources> | ||
<resource> | ||
<directory>${basedir}/src/main/resources</directory> | ||
<filtering>true</filtering> | ||
</resource> | ||
</resources> | ||
|
||
<plugins> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-compiler-plugin</artifactId> | ||
<version>3.8.1</version> | ||
<configuration> | ||
<source>1.8</source> | ||
<target>1.8</target> | ||
<useIncrementalCompilation>true</useIncrementalCompilation> | ||
<excludes> | ||
<exclude>**/package-info.java</exclude> | ||
</excludes> | ||
<testExcludes> | ||
<exclude>**/package-info.java</exclude> | ||
</testExcludes> | ||
<compilerArgs> | ||
<arg>-Xlint:all</arg> | ||
</compilerArgs> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<artifactId>maven-jar-plugin</artifactId> | ||
<version>3.2.0</version> | ||
<configuration> | ||
<archive> | ||
<manifestEntries> | ||
<Built-By>Maven</Built-By> | ||
<Implementation-Title>${project.name}</Implementation-Title> | ||
<Implementation-Version>${project.version}</Implementation-Version> | ||
<Implementation-Vendor-Id>${project.groupId}</Implementation-Vendor-Id> | ||
<Implementation-Vendor>${project.organization.name}</Implementation-Vendor> | ||
</manifestEntries> | ||
</archive> | ||
</configuration> | ||
</plugin> | ||
|
||
|
||
<plugin> | ||
<groupId>org.codehaus.mojo</groupId> | ||
<artifactId>versions-maven-plugin</artifactId> | ||
<version>2.2</version> | ||
<configuration> | ||
<includes> | ||
<include>org.bukkit</include> | ||
<include>org.spigotmc</include> | ||
</includes> | ||
</configuration> | ||
<executions> | ||
<execution> | ||
<id>versions</id> | ||
<phase>validate</phase> | ||
<configuration> | ||
<allowSnapshots>true</allowSnapshots> | ||
</configuration> | ||
<goals> | ||
<goal>use-latest-versions</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
|
||
<plugin> | ||
<artifactId>maven-antrun-plugin</artifactId> | ||
<version>1.8</version> | ||
<executions> | ||
<execution> | ||
<phase>package</phase> | ||
<configuration> | ||
<target> | ||
<copy file="${project.build.directory}/${project.build.finalName}.${project.packaging}" | ||
tofile="${project.build.directory}/${project.name}.${project.packaging}"/> | ||
</target> | ||
</configuration> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
</plugins> | ||
<pluginManagement> | ||
<plugins> | ||
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.--> | ||
<plugin> | ||
<groupId>org.eclipse.m2e</groupId> | ||
<artifactId>lifecycle-mapping</artifactId> | ||
<version>1.0.0</version> | ||
<configuration> | ||
<lifecycleMappingMetadata> | ||
<pluginExecutions> | ||
<pluginExecution> | ||
<pluginExecutionFilter> | ||
<groupId>org.codehaus.mojo</groupId> | ||
<artifactId>versions-maven-plugin</artifactId> | ||
<versionRange>[2.2,)</versionRange> | ||
<goals> | ||
<goal>use-latest-versions</goal> | ||
</goals> | ||
</pluginExecutionFilter> | ||
<action> | ||
<ignore/> | ||
</action> | ||
</pluginExecution> | ||
</pluginExecutions> | ||
</lifecycleMappingMetadata> | ||
</configuration> | ||
</plugin> | ||
</plugins> | ||
</pluginManagement> | ||
|
||
</build> | ||
|
||
</project> |
Oops, something went wrong.