Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PlayCommand.java didn't use GroupAdapter, should it? #1113

Open
RadND opened this issue Jan 9, 2023 · 2 comments
Open

PlayCommand.java didn't use GroupAdapter, should it? #1113

RadND opened this issue Jan 9, 2023 · 2 comments
Labels

Comments

@RadND
Copy link

RadND commented Jan 9, 2023

I want to let players use Multverse-Portal(https://github.com/Multiverse/Multiverse-Portals) 's Portal to enter DXL 's Dungeon
So I write some code , it listen portal event and check some player condition -> if true -> /dxl play <portal_destnation_name>

that's fine,at least if that's not fine it's not dxl to blame,but then I plan to use my own Group plugin (to make every player have a group by default because dungeons I made usually can be played single-player), and DungeonsAPI do not provide getGroupAdapter()
so what will happen is only player who enter the portal is teleported to dungeon , and in dxl 's perspective this player is playing dungeon alone

Should /dxl play use groupadapter? Is it the only way to solve my problem?

@Sataniel98
Copy link
Member

Hi, sorry for the late reply. /dxl play starts a game with the group the player's in or creates one if he isn't in one. You by design can't use it to gather players in one instance. Set the group with all players up before entering the dungeon. Then make the players enter.

And yes, there is currently no API method to easily initialize a dungeon and game. This is because because of some quirks of the internals, and it will be rewritten in DXL 0.19. If you're still interested in doing this, you can have a look at the code in DPortal and PlayCommand.

@RadND
Copy link
Author

RadND commented Feb 12, 2023

So currently , as 3rd party developer (me) , there is no way to "Create DXL Group based on Vendor Group" , right?
If this is true ,currently when using a vendor group plugin , only way to really use it ( player's vendor group ) is ask player to interact with the [Group] sign , because according to my code search result, only GroupSign.java#L167 use GroupAdapter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants