MilkBowl/Vault — Issue #115: Permissions(EX) problem
Author: Sluijsens
Created: 2012-02-27 16:41:14+00:00
State: open

Hello,

For my plugin I want to remove and add permissions to a player.

I am using playerRemove() and playerAdd().

But when I want to execute them I get the following error:
2012-02-27 17:28:32 [SEVERE] Could not pass event org.bukkit.event.player.PlayerChatEvent to StartersQuiz
org.bukkit.event.EventException
at org.bukkit.plugin.java.JavaPluginLoader$103.execute(JavaPluginLoader.java:1026)
at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:61)
at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:460)
at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:749)
at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:732)
at net.minecraft.server.Packet3Chat.handle(Packet3Chat.java:33)
at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:100)
at net.minecraft.server.NetworkListenThread.a(NetworkListenThread.java:78)
at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:537)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:435)
at net.minecraft.server.ThreadServerApplication.run(SourceFile:465)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.bukkit.plugin.java.JavaPluginLoader$103.execute(JavaPluginLoader.java:1024)
... 11 more
Caused by: java.lang.NullPointerException
at ru.tehkode.permissions.config.ConfigurationNode.removeProperty(ConfigurationNode.java:111)
at ru.tehkode.permissions.backends.file.FileEntity.setPermissions(FileEntity.java:94)
at ru.tehkode.permissions.ProxyPermissionUser.setPermissions(ProxyPermissionUser.java:91)
at ru.tehkode.permissions.PermissionUser.removePermission(PermissionUser.java:719)
at net.milkbowl.vault.permission.plugins.Permission_PermissionsEx.playerRemove(Permission_PermissionsEx.java:168)
at net.milkbowl.vault.permission.Permission.playerRemove(Permission.java:267)
at me.sluijsens.StartersQuiz.QuizHandler.passed(QuizHandler.java:209)
at me.sluijsens.StartersQuiz.QuizHandler.answer(QuizHandler.java:100)
at me.sluijsens.StartersQuiz.PlayerHandler.onPlayerChat(PlayerHandler.java:47)
... 16 more

Also when reloading my plugin it gives me a NullPointerException for my permissions variable.
This occured after updating to the latest PEX (Not sure for the add and remove permissions)

What could be the problem and/or can you fix this?