mirror of
https://github.com/Ste3et/furniture.git
synced 2024-11-22 02:25:44 +01:00
Fix plugin.yml pom integration
This commit is contained in:
parent
58af285ace
commit
7c1ce3b70b
156
pom.xml
156
pom.xml
@ -1,101 +1,71 @@
|
||||
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>de.Ste3et_C0st.furniture</groupId>
|
||||
<artifactId>DiceFurniture</artifactId>
|
||||
|
||||
<properties>
|
||||
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>de.Ste3et_C0st.furniture</groupId>
|
||||
<artifactId>DiceFurniture</artifactId>
|
||||
|
||||
<properties>
|
||||
<furniture.tag></furniture.tag>
|
||||
</properties>
|
||||
|
||||
<version>3.5${furniture.tag}</version>
|
||||
<build>
|
||||
<defaultGoal>clean package install</defaultGoal>
|
||||
<sourceDirectory>src</sourceDirectory>
|
||||
<finalName>DiceFurniture</finalName>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src</directory>
|
||||
<excludes>
|
||||
<exclude>**/*.java</exclude>
|
||||
</excludes>
|
||||
</resource>
|
||||
</resources>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.7.0</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<artifactId>maven-assembly-plugin</artifactId>
|
||||
<configuration>
|
||||
<archive>
|
||||
<manifest>
|
||||
<mainClass>
|
||||
de.Ste3et_C0st.ProtectionLib.main.ProtectionLib
|
||||
</mainClass>
|
||||
</manifest>
|
||||
</archive>
|
||||
<descriptorRefs>
|
||||
<descriptorRef>jar-with-dependencies</descriptorRef>
|
||||
</descriptorRefs>
|
||||
<appendAssemblyId>false</appendAssemblyId>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<version>2.8.1</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>default-deploy</id>
|
||||
<phase>deploy</phase>
|
||||
<goals>
|
||||
<goal>deploy</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-deploy-plugin</artifactId>
|
||||
<version>3.0.0-M1</version>
|
||||
<configuration>
|
||||
<skip>false</skip>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>spigot-repo</id>
|
||||
<url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url>
|
||||
</repository>
|
||||
|
||||
</properties>
|
||||
|
||||
<version>3.5.0${furniture.tag}</version>
|
||||
<build>
|
||||
<defaultGoal>clean package install</defaultGoal>
|
||||
<sourceDirectory>src</sourceDirectory>
|
||||
<finalName>DiceFurniture</finalName>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src</directory>
|
||||
<excludes>
|
||||
<exclude>**/*.java</exclude>
|
||||
</excludes>
|
||||
<filtering>true</filtering>
|
||||
</resource>
|
||||
</resources>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>3.7.0</version>
|
||||
<configuration>
|
||||
<source>1.8</source>
|
||||
<target>1.8</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>jitpack.io</id>
|
||||
<url>https://jitpack.io</url>
|
||||
<id>spigot-repo</id>
|
||||
<url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url>
|
||||
</repository>
|
||||
|
||||
<repository>
|
||||
<id>jitpack.io</id>
|
||||
<url>https://jitpack.io</url>
|
||||
</repository>
|
||||
</repositories>
|
||||
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.spigotmc</groupId>
|
||||
<artifactId>spigot-api</artifactId>
|
||||
<version>1.17-R0.1-SNAPSHOT</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.Ste3et</groupId>
|
||||
<artifactId>FurnitureLib</artifactId>
|
||||
<version>22fb4086de</version>
|
||||
<groupId>org.spigotmc</groupId>
|
||||
<artifactId>spigot-api</artifactId>
|
||||
<version>1.17-R0.1-SNAPSHOT</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.Ste3et</groupId>
|
||||
<artifactId>FurnitureLib</artifactId>
|
||||
<version>22fb4086de</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<description>Add some new Objects to the Server</description>
|
||||
<url>https://dicecraft.de/furniture/</url>
|
||||
<issueManagement>
|
||||
<url>https://github.com/Ste3et/FurnitureLib/issues</url>
|
||||
<system>GitHub</system>
|
||||
</issueManagement>
|
||||
</project>
|
@ -1,5 +1,7 @@
|
||||
package de.Ste3et_C0st.Furniture.Main;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
import de.Ste3et_C0st.Furniture.Main.Event.redstoneEvent;
|
||||
@ -96,7 +98,9 @@ public class FurnitureHook extends FurniturePlugin{
|
||||
new Project("AdventCalender", getPlugin(), getResource(modelFolder + "AdventCalender" + ending), PlaceableSide.TOP, AdventCalender::new).setSize(1, 1, 1, CenterType.RIGHT);
|
||||
new Project("FireworkLauncher", getPlugin(), getResource(modelFolder + "FireworkLauncher" + ending), PlaceableSide.TOP, FireworkLauncher::new).setSize(1, 1, 1, CenterType.CENTER);
|
||||
|
||||
FurnitureLib.getInstance().getFurnitureManager().getProjects().stream().filter(pro -> pro.getPlugin().equals(getPlugin())).forEach(pro -> pro.setEditorProject(editModels));
|
||||
FurnitureLib.getInstance().getFurnitureManager().getProjects().stream().filter(pro -> pro.getPlugin().equals(getPlugin())).forEach(pro -> {
|
||||
if(Objects.nonNull(pro)) pro.setEditorProject(editModels);
|
||||
});
|
||||
}catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
@ -27,8 +27,19 @@ public class main extends JavaPlugin{
|
||||
public static HashMap<String, Vector> catapultRange = new HashMap<String, Vector>();
|
||||
|
||||
public void onEnable(){
|
||||
if(!Bukkit.getPluginManager().isPluginEnabled("FurnitureLib")){Bukkit.getPluginManager().disablePlugin(this);}
|
||||
if(getServer().getPluginManager().isPluginEnabled("FurnitureLib") == false){
|
||||
this.disablePlugin("[DiceFurniture] FurnitureLib is missing please install it!");
|
||||
System.out.println("You can find the download here: https://www.spigotmc.org/resources/furniturelibary-protectionlib.9368/");
|
||||
return;
|
||||
}
|
||||
|
||||
instance = this;
|
||||
|
||||
if(FurnitureLib.getInstance().isEnabledPlugin() == false) {
|
||||
this.disablePlugin("[DiceFurniture] Plugin disabled because FurnitureLib is incorectly installed!");
|
||||
return;
|
||||
}
|
||||
|
||||
util = FurnitureLib.getInstance().getLocationUtil();
|
||||
if(FurnitureLib.getInstance().getDescription().getVersion().startsWith("2.")){
|
||||
FurnitureHook furniturePlugin = new FurnitureHook(getInstance());
|
||||
@ -41,9 +52,16 @@ public class main extends JavaPlugin{
|
||||
}else{
|
||||
FurnitureLib.getInstance().send("FurnitureLib Version > 2.x not found");
|
||||
FurnitureLib.getInstance().send("DiceFurniture deos not load");
|
||||
this.disablePlugin("");
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void disablePlugin(String string) {
|
||||
if(string.isEmpty() == false) System.out.println(string);
|
||||
Bukkit.getPluginManager().disablePlugin(this);
|
||||
}
|
||||
|
||||
private void setDefaults_2(){
|
||||
c = new config();
|
||||
|
@ -1,8 +1,8 @@
|
||||
name: DiceFurniture
|
||||
version: 3.4.6
|
||||
description: Add some new Objects to the Server
|
||||
name: ${project.name}
|
||||
version: ${project.version}
|
||||
description: ${project.description}
|
||||
author: Ste3et_C0st
|
||||
website: http://dicecraft.de
|
||||
website: ${project.url}
|
||||
depend: [FurnitureLib]
|
||||
main: de.Ste3et_C0st.Furniture.Main.main
|
||||
api-version: 1.13
|
||||
api-version: 1.13
|
||||
|
Loading…
Reference in New Issue
Block a user