Skip to content

Commit

Permalink
Refactoring in preparation for Minepacks v3.X
Browse files Browse the repository at this point in the history
  • Loading branch information
GeorgH93 committed Aug 31, 2020
1 parent c491d17 commit 8053b5d
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<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>
<artifactId>MarriageMaster-MinepacksLegacy</artifactId>
<artifactId>MarriageMaster-MinepacksV1</artifactId>
<parent>
<artifactId>MarriageMaster-Parent</artifactId>
<groupId>at.pcgamingfreaks</groupId>
Expand All @@ -10,7 +10,7 @@
<version>${revision}</version>
<packaging>jar</packaging>

<name>MarriageMaster Minepacks legacy integration</name>
<name>MarriageMaster Minepacks V1.x integration</name>
<description>The Minepacks integration of Marriage Master.</description>

<dependencies>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<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>
<artifactId>MarriageMaster-Minepacks</artifactId>
<artifactId>MarriageMaster-MinepacksV2</artifactId>
<parent>
<artifactId>MarriageMaster-Parent</artifactId>
<groupId>at.pcgamingfreaks</groupId>
Expand All @@ -10,7 +10,7 @@
<version>${revision}</version>
<packaging>jar</packaging>

<name>MarriageMaster Minepacks integration</name>
<name>MarriageMaster Minepacks V2.x integration</name>
<description>The Minepacks integration of Marriage Master.</description>

<dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@

import java.util.MissingResourceException;

public class MinepacksIntegration implements IBackpackIntegration
public class MinepacksV2Integration implements IBackpackIntegration
{
private static final String PLUGIN_NAME = "Minepacks";
private static final Version MIN_VERSION = new Version("2.0");
private MinepacksPlugin minepacks;
@Getter private final String version;

public MinepacksIntegration() throws NullPointerException, BackpackPluginIncompatibleException
public MinepacksV2Integration() throws NullPointerException, BackpackPluginIncompatibleException
{
Plugin bukkitPlugin = Bukkit.getPluginManager().getPlugin(PLUGIN_NAME);
if(!(bukkitPlugin instanceof MinepacksPlugin)) throw new MissingResourceException("Plugin " + PLUGIN_NAME + " is not available!", this.getClass().getName(), PLUGIN_NAME);
Expand Down
4 changes: 2 additions & 2 deletions MarriageMaster/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,12 @@
</dependency>
<dependency>
<groupId>at.pcgamingfreaks</groupId>
<artifactId>MarriageMaster-Minepacks</artifactId>
<artifactId>MarriageMaster-MinepacksV2</artifactId>
<version>${revision}</version>
</dependency>
<dependency>
<groupId>at.pcgamingfreaks</groupId>
<artifactId>MarriageMaster-MinepacksLegacy</artifactId>
<artifactId>MarriageMaster-MinepacksV1</artifactId>
<version>${revision}</version>
</dependency>
<!-- PCGF Plugin Lib -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ private static void registerCompatiblePlugin(String identifier, VersionRange ver
static
{
registerCompatiblePlugin("MinePacks", new VersionRange("1.17.7", "1.999"), MinepacksV1Integration.class);
registerCompatiblePlugin("Minepacks", new VersionRange("2.0-SNAPSHOT", null), MinepacksIntegration.class);
registerCompatiblePlugin("Minepacks", new VersionRange("2.0-SNAPSHOT", "2.999"), MinepacksV2Integration.class);
}

public static IBackpackIntegration getIntegration()
Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,8 @@
<modules>
<module>MarriageMaster-API</module>
<module>Extensions/MarriageMaster-BackpackIntegration</module>
<module>Extensions/MarriageMaster-MinepacksLegacy</module>
<module>Extensions/MarriageMaster-Minepacks</module>
<module>Extensions/MarriageMaster-MinepacksV1</module>
<module>Extensions/MarriageMaster-MinepacksV2</module>
<module>MarriageMaster</module>
</modules>

Expand Down

0 comments on commit 8053b5d

Please sign in to comment.