Shopkeepers

Shopkeepers

2M Downloads

Error Sneak-Click Player Shop

blablubbabcDEV opened this issue ยท 6 comments

commented

Migrated from: https://dev.bukkit.org/projects/shopkeepers/issues/400

Originally posted by boushwa (May 1, 2016):

What steps will reproduce the problem?

  1. Creating a player shop
  2. Sneak+Right-Click to set pricesWhat is the expected output? What do you see instead?
    Expected GUI to open to allow prices to be set; instead I get a normal villager GUI with preset items instead of what's in my chestWhat version of the product are you using?
    1.71Do you have an error log of what happened?
    01.05 08:09:54 [Multicraft] Skipped 6 lines due to rate limit (30/s)
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.LivingEntityShopListener.onEntityInteract(LivingEntityShopListener.java:57) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.shoptypes.PlayerShopkeeper.onPlayerInteraction(PlayerShopkeeper.java:341) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.Shopkeeper.onPlayerInteraction(Shopkeeper.java:483) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.Shopkeeper.openEditorWindow(Shopkeeper.java:439) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.Shopkeeper.openWindow(Shopkeeper.java:426) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.ui.UIManager.requestUI(UIManager.java:67) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.shoptypes.NormalPlayerShopkeeper$NormalPlayerShopEditorHandler.openWindow(NormalPlayerShopkeeper.java:53) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.shoptypes.PlayerShopkeeper$PlayerShopEditorHandler.setEditColumnCost(PlayerShopkeeper.java:136) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.shoptypes.PlayerShopkeeper.createZeroCurrencyItem(PlayerShopkeeper.java:591) ~[?:?]
    01.05 08:09:43 [Server] INFO at com.nisovin.shopkeepers.Utils.setItemStackNameAndLore(Utils.java:455) ~[?:?]
    01.05 08:09:43 [Server] INFO Caused by: java.lang.NullPointerException
    01.05 08:09:43 [Server] INFO at java.lang.Thread.run(Unknown Source) [?:1.8.0_40]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.MinecraftServer.run(MinecraftServer.java:559) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.MinecraftServer.C(MinecraftServer.java:660) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.DedicatedServer.D(DedicatedServer.java:400) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.MinecraftServer.D(MinecraftServer.java:721) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.SystemUtils.a(SourceFile:45) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at java.util.concurrent.FutureTask.run(Unknown Source) [?:1.8.0_40]
    01.05 08:09:43 [Server] INFO at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [?:1.8.0_40]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.PlayerConnectionUtils$1.run(SourceFile:13) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.PacketPlayInUseEntity.a(SourceFile:12) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.PacketPlayInUseEntity.a(SourceFile:68) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at de.robingrether.idisguise.management.channel.InjectedPlayerConnection191.a(InjectedPlayerConnection191.java:39) [iDisguise-5.2.1.jar:?]
    01.05 08:09:43 [Server] INFO at net.minecraft.server.v1_9_R1.PlayerConnection.a(PlayerConnection.java:1532) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:487) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:502) [custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) ~[custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:310) ~[custom.jar:git-Spigot-e6f93f4-935f18b]
    01.05 08:09:43 [Server] INFO org.bukkit.event.EventException
    01.05 08:09:43 [Server] ERROR Could not pass event PlayerInteractEntityEvent to Shopkeepers v1.71Please provide any additional information below.
    Using the latest version of Spigot as of 8AM ET today.
commented

Originally commented by boushwa (May 1, 2016):

Update: I only get this error when I place items in the chest the shopkeeper is linked to. If the chest is empty, the normal empty GUI opens upon shift-clicking the NPC which allows me to edit name, type, delete.
If I put even just one item in the chest though, the error shows up in console and shift-clicking the shopkeeper opens up a normal villager GUI with normal villager trades.

commented

Originally commented by blablubbabc (May 1, 2016):

[at]boushwa:
Could you please attach your config file? I assume you might have modified the zero-currency-item to AIR in the config and shopkeeper can't handle that currently.

        Edited May 1, 2016
commented

Originally commented by blablubbabc (May 1, 2016):

[at]boushwa:
If you want to specify custom costs for a trade, take a look at the 'trading' player shopkeeper type.
I will try to fix this in the next update, so that it keeps working regardless of what you set in the config.

        Edited May 1, 2016
commented

Originally commented by blablubbabc (May 1, 2016):

Check out v1.72: The zero cost items should now work even if set to AIR.

commented

Originally commented by boushwa (May 1, 2016):

[at]blablubbabc:
I do believe that's what happened. I began playing with it not realizing I needed to have a set currency and I ended up removing it altogether. I deleted my config and and let a new one populate and it seemed to fix the issue now that a currency is applied.
I was under the impression we could set the currency to anything via the shopkeeper itself like we do with admin shops. But now I know. So, this is now a non-issue.
Thanks!

commented

Originally closed by blablubbabc (May 2, 2016)