Plugin category: Misc Minecraft version: 1.8 Suggested name: SlotChanger What I want: A command to change the slot of the argumented player using this code, that I found on the internet. Code: event.getPlayer().getInventory().setHeldItemSlot(4); It will force the argument player to change their slot to the slot argument. Source I would want it made since I have no idea about Java as a whole. I would learn, but I am more a skript person and you cannot change slots on that. Ideas for commands: - /slot <online player> <slot (0-8 or if you convert it, 1-9)> (click? true/false)* Ideas for permissions: - changeslot.* When I'd like it by: Anytime. Maybe it's hard or easy, I have no idea :c * This is tricky, see in comments.
@daniel363 Still want to know the code behind it, because as far as I can tell this is some heavy NMS stuff.
@timtower Maybe they opened a book GUI? I don't know if that is possible, but maybe they want to create a illusion.
@daniel363 That is the thing: the server can't tell the client to open something without doing some very tricky stuff. And I don't believe that every GUI is supported. I did find out that it is signed books only that can do this.
@timtower Well that makes sense since the book is signed. If it isn't possible to do the click thing unless you do tricky (and laggy?) stuff, I would just want to a command to change the players slot then. Will edit in my main post, hopefully, someone will take interest :c
@daniel363 You showed that it was possible to open booms. Just keep it inthe request if that is what you want. Tricky does not mean laggy, not for this at least. And that I don't know how does not mean that nobody knows it.
I have been looking into this. This is very heavy NMS, which not a lot of Bukkit/Spigot developers know NMS code. And if you wanted to change minecraft version, then the plugin would have to be updated before that. Possibly, not super laggy, but hard for most developers that I have come across
Sorry if I sound like a nagger but thanks anyway. I edited the post back but added a disclaimer that using the click thing is tricky and is not needed. Hopefully someone will make hopefully a simple plugin to change a players slot.
@daniel363 Link: https://www.dropbox.com/s/wcxacp3d3a6o7o6/SlotChanger.jar?dl=0 Didn't manage to do the force click option but just thought you may as well have something to use until someone manages to get that working. Messages are customizable and color codes are supported. (config.yml) If there's any issues let me know.
@daniel363 Here you go. Link: https://www.dropbox.com/s/j054geaoxdkrxf0/SlotChanger.jar?dl=0 Don't know why i thought the console shouldn't be able to it!