It tells me no perms, but I still can open the door with the codelock I placed and set the code for. With Unlock perms I can open it without it telling me no perms. This is what I changed to make it fit how I thought/think it should work:
private object CanUseLockedEntity(BasePlayer player, BaseLock baseLock)
{
if (!player.limitNetworking) return null;
if (HasPerm(player.UserIDString, PermUnlock)) return true;
if (config.EnableNotifications && !baseLock.HasLockPermission(player))
{
Message(player.IPlayer, "NoPerms");
return false;
}
return null;
}It checks if the user has permission to actually use said lock,Β thenΒ informs them if they don't have permission, and actually blocks it. Though I am not positive thats what your goal was when creating it. Feel free to use or not use it, I noticed it and thought it was an issue with one of my plugins so I dug a bit deeper into what was causing it.