Depenizen icon indicating copy to clipboard operation
Depenizen copied to clipboard

DungeonsXL Support

Open ofseaandstars opened this issue 5 years ago • 4 comments

DungeonsXL is a pretty commonly used Dungeon instancing plugin, and has a documented API here: https://erethon.de/javadocs/dungeonsxl/de/erethon/dungeonsxl/api/DungeonsAPI.html

Would love to see some integration built in to Depenizen.

Plugin: https://www.spigotmc.org/resources/dungeonsxl.9488/

ofseaandstars avatar Dec 05 '20 12:12 ofseaandstars

... what integration?

mcmonkey4eva avatar Dec 05 '20 13:12 mcmonkey4eva

DungeonsAPI.getGameWorld().getDungeon() - https://erethon.de/javadocs/dungeonsxl/de/erethon/dungeonsxl/api/world/GameWorld.html#getDungeon-- Currently getting the name of the dungeon is not really doable with just Denizen, as the worlds are named DXL_Game_<instance> so this would help to get the name of the world. Also allows for dungeon-specific scripts, even if there are multiple instances. I previously wanted to have a script for a specific dungeon I have, but as the world name changes based on how many instances are already active, there's no way to have a consistent name to work with.

DungeonsAPI.getPlayerGroup() - https://erethon.de/javadocs/dungeonsxl/de/erethon/dungeonsxl/api/DungeonsAPI.html#getPlayerGroup-org.bukkit.entity.Player- So I can grab the group the player is in and (if they are in a group) apply different buffs etc for grouped players and scale mobs according to the number of players.

DungeonsAPI.getPlayerGroup().getMembers() - https://erethon.de/javadocs/dungeonsxl/de/erethon/dungeonsxl/api/player/PlayerGroup.html#getMembers-- If the player is in a group and triggers a certain event, I want to get a list of all the players within that group so I can apply effects to all of them (group buffs).

DungeonsAPI.isInstance() - https://erethon.de/javadocs/dungeonsxl/de/erethon/dungeonsxl/api/DungeonsAPI.html#isInstance-org.bukkit.World- For checking if the player is actually in an instance in the first place. Currently no easy way to do this other than checking the world name and seeing if it contains 'GAME' in it. I want to run some scripts only when there are players in an active instance.

ofseaandstars avatar Dec 05 '20 14:12 ofseaandstars

The javadocs are nice, but what do you want the depenizen integration to look like?

SXRWahrheit avatar Dec 05 '20 15:12 SXRWahrheit

Ideally, something like:

<dxl[<world>].dungeon> - returns DungeonTag?

<dxl[<world>].dungeon.get_name> - returns el tag with the dungeon name

<dxl[<world>].is_instance> - returns boolean as to whether the specified world is an instance.

<dxl[<player>].group> - returns either the name/id of the group or null (as that is a valid return to say the player doesn't have a group).

<dxl[<player>].get_group_members> - return a list tag with the list of players in the group if there is one. If null, perhaps return the player as a single list element.

These are suggested formats for the tags, but that's the general idea I'm thinking.

ofseaandstars avatar Dec 05 '20 16:12 ofseaandstars