Skip to content

Commit da67b5e

Browse files
Im-FranTheProgramSrc
authored andcommitted
New CommandAPI - Fixed incompatibility Issues
+ Added CommandAPI by JorelAli * Fixed incompatibility issues with other plugins.
1 parent bb60855 commit da67b5e

File tree

5 files changed

+31
-3
lines changed

5 files changed

+31
-3
lines changed

SuperCoreAPI.iml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,6 @@
5050
<orderEntry type="library" scope="PROVIDED" name="Maven: org.apache.logging.log4j:log4j-api:2.13.2" level="project" />
5151
<orderEntry type="library" scope="PROVIDED" name="Maven: me.clip:placeholderapi:2.10.9" level="project" />
5252
<orderEntry type="library" scope="PROVIDED" name="Maven: org.jetbrains:annotations:19.0.0" level="project" />
53+
<orderEntry type="library" name="Maven: dev.jorel:commandapi-shade:5.3" level="project" />
5354
</component>
5455
</module>

dependency-reduced-pom.xml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<groupId>xyz.theprogramsrc</groupId>
55
<artifactId>SuperCoreAPI</artifactId>
66
<name>SuperCoreAPI</name>
7-
<version>4.5.2</version>
7+
<version>4.6.0</version>
88
<build>
99
<sourceDirectory>src/main/java</sourceDirectory>
1010
<defaultGoal>clean package</defaultGoal>
@@ -49,6 +49,10 @@
4949
<pattern>org.apache.commons.io</pattern>
5050
<shadedPattern>xyz.theprogramsrc.supercoreapi.apache.commons.io</shadedPattern>
5151
</relocation>
52+
<relocation>
53+
<pattern>dev.jorel.commandapi-shade</pattern>
54+
<shadedPattern>xyz.theprogramsrc.supercoreapi.commandapi</shadedPattern>
55+
</relocation>
5256
</relocations>
5357
</configuration>
5458
</execution>
@@ -77,6 +81,10 @@
7781
<id>sonatype</id>
7882
<url>https://oss.sonatype.org/content/groups/public/</url>
7983
</repository>
84+
<repository>
85+
<id>commandapi</id>
86+
<url>https://raw.githubusercontent.com/JorelAli/CommandAPI/mvn-repo/</url>
87+
</repository>
8088
</repositories>
8189
<dependencies>
8290
<dependency>

pom.xml

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
<groupId>xyz.theprogramsrc</groupId>
88
<artifactId>SuperCoreAPI</artifactId>
9-
<version>4.5.2</version>
9+
<version>4.6.0</version>
1010
<packaging>jar</packaging>
1111

1212
<name>SuperCoreAPI</name>
@@ -56,6 +56,10 @@
5656
<pattern>org.apache.commons.io</pattern>
5757
<shadedPattern>xyz.theprogramsrc.supercoreapi.apache.commons.io</shadedPattern>
5858
</relocation>
59+
<relocation>
60+
<pattern>dev.jorel.commandapi-shade</pattern>
61+
<shadedPattern>xyz.theprogramsrc.supercoreapi.commandapi</shadedPattern>
62+
</relocation>
5963
</relocations>
6064
</configuration>
6165
</execution>
@@ -107,6 +111,11 @@
107111
<id>sonatype</id>
108112
<url>https://oss.sonatype.org/content/groups/public/</url>
109113
</repository>
114+
<!-- Command API -->
115+
<repository>
116+
<id>commandapi</id>
117+
<url>https://raw.githubusercontent.com/JorelAli/CommandAPI/mvn-repo/</url>
118+
</repository>
110119
</repositories>
111120

112121
<dependencies>
@@ -192,5 +201,12 @@
192201
<version>2.10.9</version>
193202
<scope>provided</scope>
194203
</dependency>
204+
<!-- CommandAPI -->
205+
<dependency>
206+
<groupId>dev.jorel</groupId>
207+
<artifactId>commandapi-shade</artifactId>
208+
<version>5.3</version>
209+
<scope>compile</scope>
210+
</dependency>
195211
</dependencies>
196212
</project>

src/main/java/xyz/theprogramsrc/supercoreapi/SuperPlugin.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ public interface SuperPlugin<PLUGIN> {
1818
/*
1919
* This need to be updated on every new release
2020
*/
21-
String SUPER_CORE_API_VERSION = "4.5.2";
21+
String SUPER_CORE_API_VERSION = "4.6.0";
2222

2323
/**
2424
* Gets if this plugin is paid, By default is set to true, but is recommended to change it if your plugin is free.

src/main/java/xyz/theprogramsrc/supercoreapi/spigot/SpigotPlugin.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package xyz.theprogramsrc.supercoreapi.spigot;
22

3+
import dev.jorel.commandapi.CommandAPI;
34
import org.bukkit.configuration.ConfigurationSection;
45
import org.bukkit.event.HandlerList;
56
import org.bukkit.event.Listener;
@@ -62,6 +63,7 @@ public void onLoad() {
6263
this.firstStart = !this.getDataFolder().exists();
6364
Utils.folder(this.getDataFolder());
6465
this.pluginDataStorage = new PluginDataStorage(this);
66+
CommandAPI.onLoad(false);
6567
this.onPluginLoad();
6668
if(this.emergencyStop) {
6769
setEnabled(false);
@@ -90,6 +92,7 @@ public void onEnable() {
9092
this.recipeCreator = new RecipeCreator();
9193
Skulls.loadFromGitHub();
9294
this.placeholderManager = new SpigotPlaceholderManager(this);
95+
CommandAPI.onEnable(this);
9396
this.onPluginEnable();
9497
if(this.emergencyStop) {
9598
setEnabled(false);

0 commit comments

Comments
 (0)