mirror of
https://github.com/BentoBoxWorld/Level.git
synced 2024-11-23 18:45:17 +01:00
Makes the BSkyBlock and AcidIsland commands configurable.
https://github.com/BentoBoxWorld/addon-acidisland/pull/4
This commit is contained in:
parent
3d8c7dafea
commit
b3ba8c935e
2
pom.xml
2
pom.xml
@ -70,7 +70,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>world.bentobox</groupId>
|
<groupId>world.bentobox</groupId>
|
||||||
<artifactId>bentobox</artifactId>
|
<artifactId>bentobox</artifactId>
|
||||||
<version>0.9.0-SNAPSHOT</version>
|
<version>0.10.0-SNAPSHOT</version>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
@ -117,22 +117,22 @@ public class Level extends Addon {
|
|||||||
// Register commands
|
// Register commands
|
||||||
// AcidIsland hook in
|
// AcidIsland hook in
|
||||||
this.getPlugin().getAddonsManager().getAddonByName("AcidIsland").ifPresent(a -> {
|
this.getPlugin().getAddonsManager().getAddonByName("AcidIsland").ifPresent(a -> {
|
||||||
CompositeCommand acidIslandCmd = getPlugin().getCommandsManager().getCommand("ai");
|
CompositeCommand acidIslandCmd = getPlugin().getCommandsManager().getCommand(getConfig().getString("acidisland.user-command","ai"));
|
||||||
if (acidIslandCmd != null) {
|
if (acidIslandCmd != null) {
|
||||||
new IslandLevel(this, acidIslandCmd);
|
new IslandLevel(this, acidIslandCmd);
|
||||||
new IslandTop(this, acidIslandCmd);
|
new IslandTop(this, acidIslandCmd);
|
||||||
CompositeCommand acidCmd = getPlugin().getCommandsManager().getCommand("acid");
|
CompositeCommand acidCmd = getPlugin().getCommandsManager().getCommand(getConfig().getString("acidisland.admin-command","acid"));
|
||||||
new AdminLevel(this, acidCmd);
|
new AdminLevel(this, acidCmd);
|
||||||
new AdminTop(this, acidCmd);
|
new AdminTop(this, acidCmd);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// BSkyBlock hook in
|
// BSkyBlock hook in
|
||||||
this.getPlugin().getAddonsManager().getAddonByName("BSkyBlock").ifPresent(a -> {
|
this.getPlugin().getAddonsManager().getAddonByName("BSkyBlock").ifPresent(a -> {
|
||||||
CompositeCommand bsbIslandCmd = getPlugin().getCommandsManager().getCommand("island");
|
CompositeCommand bsbIslandCmd = getPlugin().getCommandsManager().getCommand(getConfig().getString("bskyblock.user-command","island"));
|
||||||
if (bsbIslandCmd != null) {
|
if (bsbIslandCmd != null) {
|
||||||
new IslandLevel(this, bsbIslandCmd);
|
new IslandLevel(this, bsbIslandCmd);
|
||||||
new IslandTop(this, bsbIslandCmd);
|
new IslandTop(this, bsbIslandCmd);
|
||||||
CompositeCommand bsbAdminCmd = getPlugin().getCommandsManager().getCommand("bsbadmin");
|
CompositeCommand bsbAdminCmd = getPlugin().getCommandsManager().getCommand(getConfig().getString("bskyblock.admin-command","bsbadmin"));
|
||||||
new AdminLevel(this, bsbAdminCmd);
|
new AdminLevel(this, bsbAdminCmd);
|
||||||
new AdminTop(this, bsbAdminCmd);
|
new AdminTop(this, bsbAdminCmd);
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,15 @@
|
|||||||
|
# Config file for Level add-on for BSkyBlock or AcidIsland
|
||||||
|
|
||||||
|
# Command hook-in configuration.
|
||||||
|
# Level will try to hook into these commands when it starts
|
||||||
|
# If you have changed the default AcidIsland or BSkyBlock commands, change them here
|
||||||
|
acidisland:
|
||||||
|
admin-command: acid
|
||||||
|
user-command: ai
|
||||||
|
bskyblock:
|
||||||
|
admin-command: bsbadmin
|
||||||
|
user-command: island
|
||||||
|
|
||||||
# This file lists the values for various blocks that are used to calculate the
|
# This file lists the values for various blocks that are used to calculate the
|
||||||
# island level. Level = total of all blocks in island boundary / 100.
|
# island level. Level = total of all blocks in island boundary / 100.
|
||||||
# Players with the permission askyblock.island.multiplier.# will have their blocks
|
# Players with the permission askyblock.island.multiplier.# will have their blocks
|
||||||
|
Loading…
Reference in New Issue
Block a user