Bump version, fix build

This commit is contained in:
Gabriele C 2018-11-22 15:33:26 +01:00
parent ee8a7c806a
commit c15c99d06b
8 changed files with 77 additions and 16 deletions

View File

@ -7,7 +7,7 @@
<parent>
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-parent</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</parent>
<artifactId>worldguardwrapper-api</artifactId>

View File

@ -7,7 +7,7 @@
<parent>
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-implementation</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</parent>
<artifactId>worldguardwrapper-implementation-interface</artifactId>
@ -18,7 +18,7 @@
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>worldguardwrapper-api</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</dependency>
</dependencies>
</project>

View File

@ -7,7 +7,7 @@
<parent>
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-parent</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</parent>
<artifactId>worldguardwrapper-implementation</artifactId>

View File

@ -7,7 +7,7 @@
<parent>
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-implementation</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</parent>
<artifactId>worldguardwrapper-implementation-v6</artifactId>
@ -18,7 +18,7 @@
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>worldguardwrapper-implementation-interface</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>com.sk89q.worldguard</groupId>

View File

@ -7,7 +7,7 @@
<parent>
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-implementation</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</parent>
<artifactId>worldguardwrapper-implementation-v7</artifactId>
@ -18,7 +18,7 @@
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>worldguardwrapper-implementation-interface</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>com.sk89q.worldguard</groupId>

View File

@ -25,6 +25,7 @@ import org.bukkit.entity.Player;
import org.bukkit.plugin.java.JavaPlugin;
import org.codemc.worldguardwrapper.flags.AbstractWrappedFlag;
import org.codemc.worldguardwrapper.implementation.IWorldGuardImplementation;
import org.codemc.worldguardwrapper.region.PlayerDomain;
import org.codemc.worldguardwrapper.region.WrappedRegion;
import org.codemc.worldguardwrapper.selection.CuboidSelection;
import org.codemc.worldguardwrapper.selection.PolygonalSelection;
@ -141,15 +142,75 @@ public class WorldGuardImplementation implements IWorldGuardImplementation {
}
@Override
public Set<UUID> getOwners() {
public PlayerDomain getOwners() {
return new PlayerDomain() {
@Override
public Set<UUID> getPlayers() {
return region.getOwners().getUniqueIds();
}
@Override
public Set<UUID> getMembers() {
public void addPlayer(UUID uuid) {
region.getOwners().addPlayer(uuid);
}
@Override
public void removePlayer(UUID uuid) {
region.getOwners().removePlayer(uuid);
}
@Override
public Set<String> getGroups() {
return region.getOwners().getGroups();
}
@Override
public void addGroup(String name) {
region.getOwners().addGroup(name);
}
@Override
public void removeGroup(String name) {
region.getOwners().removeGroup(name);
}
};
}
@Override
public PlayerDomain getMembers() {
return new PlayerDomain() {
@Override
public Set<UUID> getPlayers() {
return region.getMembers().getUniqueIds();
}
@Override
public void addPlayer(UUID uuid) {
region.getMembers().addPlayer(uuid);
}
@Override
public void removePlayer(UUID uuid) {
region.getMembers().removePlayer(uuid);
}
@Override
public Set<String> getGroups() {
return region.getMembers().getGroups();
}
@Override
public void addGroup(String name) {
region.getMembers().addGroup(name);
}
@Override
public void removeGroup(String name) {
region.getMembers().removeGroup(name);
}
};
}
@Override
public boolean contains(Location location) {
return region.contains(BukkitAdapter.asBlockVector(location));

View File

@ -7,7 +7,7 @@
<parent>
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-parent</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
</parent>
<artifactId>worldguardwrapper</artifactId>
@ -18,13 +18,13 @@
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>worldguardwrapper-implementation-v6</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>worldguardwrapper-implementation-v7</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
<optional>true</optional>
</dependency>
</dependencies>

View File

@ -6,7 +6,7 @@
<groupId>org.codemc.worldguardwrapper</groupId>
<artifactId>worldguardwrapper-parent</artifactId>
<version>1.0.3-SNAPSHOT</version>
<version>1.0.4-SNAPSHOT</version>
<packaging>pom</packaging>
<modules>