mung3r / ecoCreature

PvM/E Rewards
http://forums.bukkit.org/threads/29538
GNU Lesser General Public License v3.0
7 stars 12 forks source link

Could not pass event CUSTOM_EVENT to ecoCreature #23

Closed ScottSpittle closed 12 years ago

ScottSpittle commented 12 years ago
00:50:41 [SEVERE] Could not pass event CUSTOM_EVENT to ecoCreature
java.lang.NullPointerException
        at se.crafted.chrisb.ecoCreature.managers.ecoRewardManager.registerCreatureDeath(ecoRewardManager.java:143)
        at se.crafted.chrisb.ecoCreature.listeners.ecoDeathListener.onCreatureKilledByPlayer(ecoDeathListener.java:22)
        at se.crafted.chrisb.ecoCreature.listeners.DeathEventsListener.onCustomEvent(DeathEventsListener.java:27)
        at org.bukkit.plugin.java.JavaPluginLoader$97.execute(JavaPluginLoader.java:947)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at se.crafted.chrisb.ecoCreature.listeners.ecoEntityListener.onEntityDeath(ecoEntityListener.java:44)
        at org.bukkit.plugin.java.JavaPluginLoader$65.execute(JavaPluginLoader.java:720)
        at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62)
        at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:339)
        at org.bukkit.craftbukkit.event.CraftEventFactory.callEntityDeathEvent(CraftEventFactory.java:305)
        at net.minecraft.server.EntitySnowman.dropDeathLoot(EntitySnowman.java:89)
        at net.minecraft.server.EntityLiving.die(EntityLiving.java:606)
        at net.minecraft.server.EntityLiving.damageEntity(EntityLiving.java:502)
        at net.minecraft.server.EntityHuman.f(EntityHuman.java:794)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:916)
        at net.minecraft.server.Packet7UseEntity.a(SourceFile:33)
        at net.minecraft.server.NetworkManager.b(NetworkManager.java:226)
        at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:93)
        at org.getspout.spout.SpoutNetServerHandler.a(SpoutNetServerHandler.java:550)
        at net.minecraft.server.NetworkListenThread.a(SourceFile:108)
        at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:527)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:425)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:457)
mung3r commented 12 years ago

What's interesting about this is that it appears to be a Snowman which is supported. Not sure why it couldn't find the reward for snowman. I'm thinking of giving you a debug build if you are open to helping me track down the mob.

ScottSpittle commented 12 years ago

Sure

mung3r commented 12 years ago

Try this dev build: http://ci.milkbowl.net/view/mung3r/job/ecoCreature/55/artifact/target/ecoCreature-0.0.1-SNAPSHOT.jar

It will write to the server.log when it encounters an unknown mob.

ScottSpittle commented 12 years ago

O.k installed now.

ScottSpittle commented 12 years ago

18:29:38 [WARNING] [ecoCreature] Unknown creature type: SnowMan 18:29:38 [WARNING] [ecoCreature] Unknown creature type: SnowMan 18:29:38 [WARNING] [ecoCreature] Unknown creature type: SnowMan 18:29:38 [WARNING] [ecoCreature] No reward found for class org.bukkit.craftbukkit.entity.CraftSnowman

mung3r commented 12 years ago

Is the Snowman reward in your default.yml file listed as 'SnowMan' or 'Snowman'?

ScottSpittle commented 12 years ago

Haha its not in the configuration. Lol. And that's what the plugin generates

mung3r commented 12 years ago

Well, it is actually in the default configuration of the current version. The problem is, the plugin doesn't update or upgrade the config to put in the new entries.

Try renaming or backup your current default.yml and see if it shows up in the newly generated config.

ScottSpittle commented 12 years ago

O.k. But it should really update the config.. alot of other plugins do.

mung3r commented 12 years ago

Yup, I don't disagree. It's something that has been requested by others. I'll create a ticket to add/track that feature.

ScottSpittle commented 12 years ago

got it again

02:03:44 [WARNING] [ecoCreature] Unknown creature type: SnowMan 02:03:44 [WARNING] [ecoCreature] Unknown creature type: SnowMan 02:03:44 [WARNING] [ecoCreature] Unknown creature type: SnowMan 02:03:44 [WARNING] [ecoCreature] No reward found for class org.bukkit.craftbukkit.entity.CraftSnowman

THIS IS ON NEW CONFIG:

Snowman:
    Coin_Minimum: 1.00
    Coin_Maximum: 2.00
    Coin_Percent: 100.0
mung3r commented 12 years ago

Now I'm thinking it has to do with case sensitivity. I'll have another build for you to try in a few minutes.

ScottSpittle commented 12 years ago

O.k

mung3r commented 12 years ago

Try this build: http://ci.milkbowl.net/view/mung3r/job/ecoCreature/56/artifact/target/ecoCreature-0.0.1-SNAPSHOT.jar

ScottSpittle commented 12 years ago

Works like a charm.

mung3r commented 12 years ago

Awesome!

What bukkit version are you using? Reason I ask is that I haven't seen this case sensitive bug in 1597.

Thanks for helping out.

ScottSpittle commented 12 years ago

02:18:16 [INFO] This server is running Craftbukkit version git-Bukkit-1.0.1-R1-14-g3bdd14a-b1613jnks (MC: 1.0.1) (Implementing API version 1.0.1-R2-SNAPSHOT)