deathmarine / DiabloDrops

Bukkit plugin that adjusts the mob dropping mechanics to include regularly dropped enchanted items that could be commonly found in Diablo.
http://dev.bukkit.org/bukkit-plugins/diablodrops/
GNU General Public License v3.0
17 stars 19 forks source link

Giving a specified custom item gives a random item instead. #71

Closed ncorns closed 11 years ago

ncorns commented 11 years ago

According to the version history:

Syntax is now: "/dd custom customitemname"

im running 2.4.483 and "/dd custom Death Sword" gives me a random item still.

On the off chance that the space was causing an issue, i renamed the item to Death_Sword and reloaded the config, and did: "/dd custom Death_Sword" but still a random item received.

ncorns commented 11 years ago

Just to confirm this isn't working in the latest build either (Version 2.4 Build #505)

Zarkiel7 commented 11 years ago

Please do fix/add this, i too would like it to work.

ToppleTheNun commented 11 years ago

Testing it right now.

ToppleTheNun commented 11 years ago

Just tested it with default configuration.

"/dd give ToppleTheNun" gives me a random item. "/dd custom Death Sword" gives me the custom item Death Sword. "/dd custom Death Sword p:ToppleTheNun" gives me the custom item Death Sword.

ncorns commented 11 years ago

I dont understand, i just copied your text above "/dd custom Death Sword" and pasted it in MC, and it states "You have been given a DiabloDrops item" but its not the death sword....

Is there a debug mode or possibly a problem with permissions? Is it possible that because you only have 2x items in Custom.yml that you think it works and it was purely coincidence you got the item you wanted?

Have you tried using the command "/dd custom Death Sword" 8 times and received 8 death swords in a row? If you only have 2 items in your Custom.yml then the chances of you receiving your death sword are high giving the impression there is no bug...

ToppleTheNun commented 11 years ago

Can you give me a copy of your Custom.yml for me to test with?

ncorns commented 11 years ago

No problem! - here you go: http://pastebin.com/csek63Fx

ncorns commented 11 years ago

How did you get on with testing the config? Im assuming my config loads ok in game as the items do drop.

ToppleTheNun commented 11 years ago

Custom items aren't being given because your custom items aren't loading.

ncorns commented 11 years ago

My custom items are dropping from mobs in game? How can this happen if the custom.yml is not loading?

On 11 Feb 2013, at 00:47, Richard Harrah notifications@github.com wrote:

Custom items aren't being given because your custom items aren't loading.

— Reply to this email directly or view it on GitHub..

ToppleTheNun commented 11 years ago

Run a "/dd debug" in-game and PasteBin what it says.

I mistakenly put the same answer here that I put on the BukkitDev page in response to another question.

ncorns commented 11 years ago

http://pastebin.com/yBgVaV9Y

ncorns commented 11 years ago

Still no joy? anything else i can try?

ncorns commented 11 years ago

I could be wrong, but shouldnt line 338 in DiabloDropCommand.java be

if (name.equals(""))

instead of:

if (s.equals(""))

otherwise the item name will always be appended with a " " from: name = name + " " + s;

ncorns commented 11 years ago

I've just made the change above locally, recompiled and it now works every time for me so that does seem to be the issue. I managed to give myself 10x death swords in a row, and then 10 pick axes in a row and then repeat the same test 2-3 times without a single problem...

This will also be an issue for the "tiers" section too, line 561

ToppleTheNun commented 11 years ago

Alright. Thanks for letting us know. We appreciate it!