LuckPerms

LuckPerms

41.4k Downloads

Implement LuckPerms for MinecraftForge

CKATEPTb opened this issue ยท 3 comments

commented

GIT - https://github.com/MinecraftForge/MinecraftForge.
Permission API - https://github.com/MinecraftForge/MinecraftForge/blob/1.16.x/src/main/java/net/minecraftforge/server/permission/PermissionAPI.java
Example permissions hook for command (with mixin) -

@Mixin(CommandSource.class)
public class MixinCommandSource {
    @Final
    @Shadow
    private ICommandSource source;

    @Inject(method = "hasPermissionLevel", at = @At(value = "HEAD"), cancellable = true)
    public void onHasPermissionLevel(int level, CallbackInfoReturnable<Boolean> callbackInfo) {
        if (this.source instanceof PlayerEntity) {
        //TODO
commented

Hey, my suggestion for people wanting to use permissions on Forge servers is to install Sponge. :)

commented

Hey, my suggestion for people wanting to use permissions on Forge servers is to install Sponge. :)

At the moment, it does not support versions higher than 1.13, and in addition to advantages it has disadvantages. For example, in real tests, forge will withstand more online than spongeforge

commented

Hey, my suggestion for people wanting to use permissions on Forge servers is to install Sponge. :)

SpongeForge brings a few issues with it. There are communities out there that are looking forwards a forge only server and simply do not use sponge.