1
0
mirror of https://github.com/BentoBoxWorld/Warps.git synced 2024-09-27 14:52:55 +02:00

Merge branch 'develop'

This commit is contained in:
tastybento 2020-07-07 18:44:01 -07:00
commit 619b5b45ad
5 changed files with 14 additions and 37 deletions

View File

@ -58,15 +58,15 @@
<!-- Non-minecraft related dependencies -->
<powermock.version>2.0.2</powermock.version>
<!-- More visible way how to change dependency versions -->
<spigot.version>1.14.4-R0.1-SNAPSHOT</spigot.version>
<bentobox.version>1.14.0-SNAPSHOT</bentobox.version>
<spigot.version>1.16.1-R0.1-SNAPSHOT</spigot.version>
<bentobox.version>1.14.0</bentobox.version>
<level.version>1.5.0</level.version>
<!-- Revision variable removes warning about dynamic version -->
<revision>${build.version}-SNAPSHOT</revision>
<!-- Do not change unless you want different name for local builds. -->
<build.number>-LOCAL</build.number>
<!-- This allows to change between versions. -->
<build.version>1.9.7</build.version>
<build.version>1.10.0</build.version>
</properties>
<!-- Profiles will allow to automatically change build version. -->

View File

@ -17,7 +17,7 @@ public class SignCacheManager {
private Warp addon;
// Database handler for level data
private Database<SignCache> handler;
public SignCacheManager(Warp addon) {
this.addon = addon;
handler = new Database<>(addon, SignCache.class);
@ -33,9 +33,9 @@ public class SignCacheManager {
}
});
}
void saveCache() {
cachedSigns.forEach((w, m) -> handler.saveObject(new SignCache(w, m)));
cachedSigns.forEach((w, m) -> handler.saveObjectAsync(new SignCache(w, m)));
}
Material getSignIcon(World world, UUID warpOwner) {
@ -65,7 +65,7 @@ public class SignCacheManager {
cachedSigns.get(world).put(playerUUID, result);
return result.getSignText();
}
/**
* Removes sign text from the cache
* @param world - world

View File

@ -9,8 +9,10 @@ import org.bukkit.World;
import com.google.gson.annotations.Expose;
import world.bentobox.bentobox.database.objects.DataObject;
import world.bentobox.bentobox.database.objects.Table;
import world.bentobox.warps.SignCacheItem;
@Table(name = "WarpSignCache")
public class SignCache implements DataObject {
@Expose

View File

@ -10,7 +10,9 @@ import org.bukkit.World;
import com.google.gson.annotations.Expose;
import world.bentobox.bentobox.database.objects.DataObject;
import world.bentobox.bentobox.database.objects.Table;
@Table(name = "WarpsData")
public class WarpsData implements DataObject {
@Expose

View File

@ -2,43 +2,16 @@ name: Warps
main: world.bentobox.warps.Warp
version: ${version}${build.number}
icon: OAK_SIGN
api-version: 1.14
authors: tastybento
softdepend: AcidIsland, BSkyBlock, CaveBlock, SkyGrid, AOneBlock
permissions:
bskyblock.island.warp:
'[gamemode].island.warp':
description: Player can use warp or warps commands
default: true
bskyblock.island.addwarp:
description: Player can create a welcome warp sign
default: true
acidisland.island.warp:
description: Player can use warp or warps commands
default: true
acidisland.island.addwarp:
description: Player can create a welcome warp sign
default: true
caveblock.island.warp:
description: Player can use warp or warps commands
default: true
caveblock.island.addwarp:
description: Player can create a welcome warp sign
default: true
skygrid.island.warp:
description: Player can use warp or warps commands
default: true
skygrid.island.addwarp:
description: Player can create a welcome warp sign
default: true
aoneblock.island.warp:
description: Player can use warp or warps commands
default: true
aoneblock.island.addwarp:
'[gamemode].island.addwarp':
description: Player can create a welcome warp sign
default: true