ItemJoin

ItemJoin

157k Downloads

Items not changed on world change!

Joopie123 opened this issue ยท 13 comments

commented

Hello,

Since the support for CustomJoinItems was dropped, i`am using your plugin. But i found (i think) a issue. I setted clear-on-world and clear-on-world-change to true, but when i go to another world, i still get the same items.
config

Item config:
items

World 1:
world1

World 2:
world2

The compass is working, because it is by bought item worlds, but the second item of world 2 isnt showing up, and the old items from world 1 arent working. I think the solution is very simple, but i can`t find it. Can you please help me?

commented

First, Please make sure you are using ItemJoin 2.8. v2.7 I had forgot to re-add support for it back into.

Also where it says :

world-list: #// This is the list of worlds that have custom items on join. //#

  • world
  • world_nether

Please make sure the world you are switching to that you want your items cleared on join/world changed is specified on there. ItemJoin is TOTALLY disabled from any worlds not specified under world-list. If you want items for that world they can be defined later but if they are undefined nothing will happen.

Basically if you want world 2 to not have the items when you switch to it. Define world 2 under world-list. Items will not be given since there is no specific section defined for world 2.

Hopefully this helps I quickly read your post, its really late, I am so exhausted and I just wanted to see if I can give some help before I go to sleep lol.

EDIT: ( this is also why I use Multiverse-Inventories. I never have to worry about items from one world transferring to another, but on some occasions I do like to use ItemJoin with shared world inventories . ).

commented

Wait... Are you trying to get the items from world 1 to work on world 2?? If so you would have to copy the items from world 1 that you defined and paste them then rename the 2nd world 1 to world 2.

Sorry I am a little confused by your post lol.

commented

Hello RockinChaos,
Yes, it's a bit difficult to explain. I've 1 item that always in the inventory, the compass. World 1 haves 3 items as you can see on the pictures. But when i teleport to world 2, i still get the same items. The compass is working right. The other 2 items aren't working, but should not appear in that world. I should have in world 2 an compass and an crafting table, but the old items from world 1 doesn't dissapear and players don't get a crafting table. All the worlds are loaded correctly. Sorry for my bad English, i live in the Netherlands :).

-------- Oorspronkelijk bericht --------
Van: RockinChaos [email protected]
Datum: 02-04-2016 09:15 (GMT+01:00)
Aan: RockinChaos/ItemJoin [email protected]
Cc: Joopie123 [email protected]
Onderwerp: Re: [RockinChaos/ItemJoin] Items not changed on world change! (#27)

Wait... Are you trying to get the items from world 1 to work on world 2?? If so you would have to copy the items from world 1 that you defined and paste them then rename the 2nd world 1 to world 2.

Sorry I am a little confused by your post lol.


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub:
#27 (comment)

commented

So did this solution not work for you? :

First, Please make sure you are using ItemJoin 2.8. v2.7 I had forgot to re-add support for it back into.

Also where it says :

world-list: #// This is the list of worlds that have custom items on join. //#

world
world_nether

Please make sure the world you are switching to that you want your items cleared on join/world changed is specified on there. ItemJoin is TOTALLY disabled from any worlds not specified under world-list. If you want items for that world they can be defined later but if they are undefined nothing will happen.

Basically if you want world 2 to not have the items when you switch to it. Define world 2 under world-list. Items will not be given since there is no specific section defined for world 2.

Hopefully this helps I quickly read your post, its really late, I am so exhausted and I just wanted to see if I can give some help before I go to sleep lol.

EDIT: ( this is also why I use Multiverse-Inventories. I never have to worry about items from one world transferring to another, but on some occasions I do like to use ItemJoin with shared world inventories . ).

commented

I updated the server to 1.9.2 today, and i don`t get errors, but the plugin is still not working on world change (same problem).

commented

Hello RockinChaos,

All your solutions didn`t work, but i looked to the console and i see this errors:

[16:51:46 ERROR]: [ItemJoin] Plugin ItemJoin v2.8 has failed to register events for class me.RockinChaos.itemjoin.Listeners.Mainhand because org/bukkit/event/player/PlayerSwapHandItemsEvent does not exist.
[16:51:46 ERROR]: [ItemJoin] Plugin ItemJoin v2.8 has failed to register events for class me.RockinChaos.itemjoin.Listeners.Offhand because org/bukkit/event/player/PlayerSwapHandItemsEvent does not exist.

Maybe this is the problem?
I looked to multiverse-inventories, but it`s very outdated. I updated your plugin to the latest version.

commented

Ah I see you were using and outdated spigot 1.9 when you were getting those errors.. Yeah those commits were never made to the original version of spigot 1.9 so they added it later and that's when I added offhand support to ItemJoin.

Multiverse inventories is very outdated but still works, but on its jenkins page its updated! http://ci.onarandombox.com/job/Multiverse-Inventories/.

Can you please post your config, items, and enlang.yml into pastebin.com and send me the links? This will help me with debugging your problem.

commented

Hello,

Sorry for my late comment, i`am bussy with school etc. I have installed multiverse-inventories, but now i get nothing in world 2. Here are the configs you requested:

[http://pastebin.com/4sK0R6K7]
[http://pastebin.com/tkxdK32z]
[http://pastebin.com/DxDHWi49]

Should i delete multiverse-inventories?

commented

Is the name of world 2, creative or world? If not either, you are not suppose to get items because that world is not defined to receive items. I see you have all your world's specified but only 2 are defined to receive items.

commented

Yes, sorry i don`t said that. world is world 1 and creative is world 2.

commented

I also get now every thime this warn messages on world change:
[21:40:27 WARN]: [ItemJoin] Task #597 for ItemJoin v2.8 generated an exception
java.lang.NullPointerException
at me.RockinChaos.itemjoin.Listeners.JoinItem.ChangedWorld.setWorldChangedItems(ChangedWorld.java:58) ~[?:?]
at me.RockinChaos.itemjoin.Listeners.JoinItem.ChangedWorld$1.run(ChangedWorld.java:48) ~[?:?]
at org.bukkit.craftbukkit.v1_9_R1.scheduler.CraftTask.run(CraftTask.java:71) ~[spigot-1.9.2.jar:git-Spigot-1480adb-8b61cc5]
at org.bukkit.craftbukkit.v1_9_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:350) [spigot-1.9.2.jar:git-Spigot-1480adb-8b61cc5]
at net.minecraft.server.v1_9_R1.MinecraftServer.D(MinecraftServer.java:729) [spigot-1.9.2.jar:git-Spigot-1480adb-8b61cc5]
at net.minecraft.server.v1_9_R1.DedicatedServer.D(DedicatedServer.java:400) [spigot-1.9.2.jar:git-Spigot-1480adb-8b61cc5]
at net.minecraft.server.v1_9_R1.MinecraftServer.C(MinecraftServer.java:660) [spigot-1.9.2.jar:git-Spigot-1480adb-8b61cc5]
at net.minecraft.server.v1_9_R1.MinecraftServer.run(MinecraftServer.java:559) [spigot-1.9.2.jar:git-Spigot-1480adb-8b61cc5]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_72]

commented

Oh.. my.. god.. I AM SO SORRY! I'm so stupid!! I forgot to have you add the give-on-modifiers... Add:

  give-on-modifiers:
    - 'respawn'
    - 'world-changed'

to each of your items to get them on world changed and respawn. You can remove respawn if you don't want it on respawn.

  give-on-modifiers:
    - 'world-changed'

I have also applied these for you to your items.yml if you would rather use this:
http://pastebin.com/i911NHs5

This is explained a bit better on the documentations page if you want to look at it. Its towards the bottom of the page. http://dev.bukkit.org/bukkit-plugins/itemjoin/pages/documentation/

I'm so sorry... I sometimes over-look the simplest things lol.

As for the error code this is nothing to be concerned about. It is not preventing anything I have fixed this in a snapshot version so it no longer displays that error.

And finally for the clear on world changed. I derped and accidentally added a Join event handler to it. I have added clear on world changed handler to it now and it will clear on world changed. I should have this version uploaded soon but in the meantime at least you can use the give-on-modifiers.

commented

Thank you so much! Its now working 100%! Iam now writing a good review on Spigot!