Open Parties and Claims

Open Parties and Claims

25M Downloads

Luckperms intergration issue

dev-justin opened this issue · 24 comments

commented

The integration with luckperms seems to not be working unless I am misunderstanding something.

I've added the permission xaero.pac_max_claims to the group and set a meta key value pair of xaero.pac_max_claims = 50. But it does not override the default max claims... There isn't much information on this, how does openpac check for the override value?

commented

You don't have to set the permission, only the meta value. I don't know if that's the problem.
If that doesn't help, please post your openpartiesandclaims-server.toml

commented

Thanks for the reply. I've tried with only the meta value as well. For reference using the luckperms command to set a meta value /lp group member meta set xaero.pac_max_claims 50 it will in-turn create something that looks like meta.xaero.pac_max_claims.50. (and yes I tried with and without the auto '' it adds as well)

Screenshot 2024-01-16 at 9 54 45 AM

I assume the key is xaero.pac_max_claims and the value is the number of max claims you want.

Here is my config file as well: https://pastebin.com/LPNv6WZu

commented

(and yes I tried with and without the auto '' it adds as well)

What do you mean by this?

commented

The mod doesn't look at permissions created by setting the meta value (I don't even remember LuckPerms doing that), it checks the meta values directly.

commented

I meant the 'slash' it auto adds. What do you mean that it looks at the meta value directly when the only way to add a meta value is through the way shown? If you have meta.example. its a meta pair for the group for luckperms.

Screenshot 2024-01-16 at 10 52 24 AM

Do you have an example?

commented

You added the meta value correctly. I meant that that screenshot of permissions wasn't relevant.

I meant the 'slash' it auto adds.

Where were you "trying" the slash?

commented

This currently looks correct to me, unless you changed the config option after you sent me the file.

commented

So, if it is correct, then the most likely explanation is that the player that you are testing with does not belong to the "member" group.

commented

Hmmm, interesting. At what point does openpac check the meta info for the override? For example if a user gets promoted to a group with the meta max claim set when would they expect to see the new max claim value? Is it after each server restart or does it check periodically?

Also has this been tested with the Luckperms plugin or the luckperms mod?

commented

It checks the meta value every time you try to claim. Do you belong to the group "member" when you try to claim? How are you testing the claim limit and determining that the meta value doesn't work?
Also, please stop the server and send me the config file again. In some instances, restarting the server overrides all your changes to the config file. It's not anything on OPAC's end, it's how the Forge Config API works (worked).

commented

@zerevoidd The permissions seem to be set correctly. It's ":" (correct) not "=" though, which you keep saying. Did you configure OPAC to use FTB Ranks in the main config file? It would be optional if it was the only permission mod installed, but not if you have LuckPerms and have OPAC configured to use it.

commented

Yes I am testing while in the group "member". It'll only let me claim 25 (as set in the config for max claims) even though luckperms meta has it to 50.

Here is my config: https://pastebin.com/tX8g56hW

I was playing around with it again last night so just the autosave (5) and max claims (30) have changed.

For reference I'm running the below:

Mohist version 1.20.1-548 (MC: 1.20.1) (Implementing API version 1.20.1-R0.1-SNAPSHOT, Forge version 47.2.17, NeoForge version 47.2.17)
BetterMC (BMC4) Modpack
Latest Luckperms bukkit plugin

commented

How are you running a bukkit plugin on Forge? Is that possible now?

commented

Could be related to that. It shouldn't matter whether you use the plugin or the mod, because they have the same API afaik, but I'm wondering if Mohist somehow prevents my mod from seeing LuckPerms.

commented

Nevermind, I see how.

commented

Hmm, maybe I'll try an older version of Mohist. I've seen another server running the same kind of setup do it so maybe its a Mohist version issue.

commented

Can you try using the Forge mod for LuckPerms instead of the plugin?

commented

I'll try that with a fresh install and see. I noticed as well when the server starts it does say this:
Screenshot 2024-01-19 at 10 07 24 AM
Which is a bit odd as LuckPerms is initialized before this message happens.

commented

The log output means that OPAC in fact doesn't see the LuckPerms API. And neither does Forge's permission API it seems because that's what OPAC falls back to and LuckPerms is supposed to work with it.

commented

What is the permission you'd set using FTBranks? The meta.xaero.pac_max_claims.50 for luckperms doesn't work for me either.

commented

@zerevoidd It's simply xaero.pac_max_claims

commented

But what would an example of it be in an ftbranks config to edit a rank's chunk count specifically? "xaero.pac_max_claims = 9999"?

image

This config does not work

commented

@thexaero Even with luckperms installed and using the correct permissions it does not work, are you saying that I need to enable ftbranks usage in the OPAC config?

commented

Hi, @thexaero!
Can you tell me where I can find LuckPerms-API to work with this mod?
Like I looked everywhere, I did not find. Please!