Bring Enchanting Table UI with a command?

Hey guys! Had a quick question. How could I go about giving certain players access to a command that would allow them to bring up the enchanting table UI? I am trying to get rid of the enchanting table block (for RP reasons) and I cannot for the life of me figure out how to make that happen. I know how to give only certain people the permission to do that, since I run with LuckPerms, but don't know how to actually get a command that can do that. Any help would be greatly appreciated!
93 Replies
Admincraft Meta
Admincraft Meta10mo ago
Thanks for asking your question!
Make sure to provide as much helpful information as possible such as logs/what you tried and what your exact issue is
Make sure to mark solved when issue is solved!!!
/close !close !solved !answered
Requested by divinusdx#0
Jenkins
Jenkins10mo ago
@Divinus I can make a custom plugin that does that for free However you'll have to wait for me to be available You can use Skript and do it yourself though if you want
Divinus
DivinusOP10mo ago
I must admit I tried to use skript, and while I do have experience in coding python, I don't have that much experience, especially when it comes to integrating it with the minecraft environment. So I felt quite a bit over my head on that.
Jenkins
Jenkins10mo ago
Uhm, Skript is not Python lol
Divinus
DivinusOP10mo ago
I moreso meant I have some coding experience. While it may not be python, the concept of it is relatively the same. My apologies for that.
Jenkins
Jenkins9mo ago
Hey, do you still need this? I'm free today
sweatkroket
sweatkroket9mo ago
Learn java I have experience in python and js Even though java is a lot different its doable
Divinus
DivinusOP9mo ago
Yes absolutely! Sorry, it's 6am here now. I was asleep! I am still looking on how to do this!
DemGlizzys1
DemGlizzys19mo ago
Someone said they would do it for free?
Divinus
DivinusOP9mo ago
Never heard back from them! They probably got busy
Snow Kit
Snow Kit9mo ago
@Divinus Does the enchantment table need to be functional? Should it return certain enchantments? What level should it act like?
Divinus
DivinusOP9mo ago
Yes it would need to be functional! I would want it to act pretty much exactly as if you interacted with an actual enchanting table, gui and all. It would act as a max level (No bookcases needed) but still have the random change functionality of an enchanting table does. My goal for this is to lock the permission of this enchanting table command behind a permissions group that would be unlocked through doing a quest.
Snow Kit
Snow Kit9mo ago
so the issue is, minecraft is hardcoded to always check the blocks around the "enchantment table" to get the bookshelf levels and paper doesn't allow you to override it you can override the enchantments minecraft came up with and use your own number of bookshelfs, but it would require using nms
Jenkins
Jenkins9mo ago
Sorry I was busy lol I was installing Linux I just got everything I need ready Let me configure my stuff so you are completely right lmao i'd need to use nms
Snow Kit
Snow Kit9mo ago
yeah, I had the paper code pulled up for how it's actually implemented
No description
Jenkins
Jenkins9mo ago
VSC??? horror... fucking horror.
Snow Kit
Snow Kit9mo ago
too lazy to open paper in idea mind you, you'd only need nms for EnchantmentHelper and maybe EnchantmentMenu#getEnchantmentList paper does have plugin dev tools for working with nms without obfuscation now at least but it would just need to be manually updated for different versions of the game
Divinus
DivinusOP9mo ago
I'm glad you guys know what you're referring to. xD If they need to be around bookcases I'm completely fine with that if it makes it easier to do! I have no problem with making it easier
Snow Kit
Snow Kit9mo ago
If they need to be near bookshelves, it should be like 10 lines at most
Divinus
DivinusOP9mo ago
I'm definitely down for that.
QarthO
QarthO9mo ago
@Snow Kit u dont need any nms
Snow Kit
Snow Kit9mo ago
Not all enchantments are given at a bookshelf level of 0 To generate a random enchantment, you’d need to use nms
QarthO
QarthO9mo ago
you can set the levels of hte butons so u can make the bottom button lvl 30
Snow Kit
Snow Kit9mo ago
Yes, but you can’t generate new enchantments that would be actually given at that bookshelf level For example, you’d never get silk touch without bookshelves afaik
QarthO
QarthO9mo ago
you could just create a lvl 30 enchant at spawn, and then have it use that as the enchantment block location when opening the enchantment view
Snow Kit
Snow Kit9mo ago
If the game lets that work, could’ve sworn there is a range limit tho
QarthO
QarthO9mo ago
just tested it, it works fine yeah so, u'd just want an admin command where u set the master enchantment table location then whenever someone uses the /openenchant command it'll use that location as the location also, surprisingly if the block of the enchantment table is unloaded, it'll still work, (im guessing it loads the chunks into memory to then grab the enchantmenttable + bookshelves) tbh, u could even have the player set their own enchantment tables location, so the player gets to control the levels would also require the player to have a lvl 30 enchantment table setup in order to get the lvl 30 enchants
Divinus
DivinusOP9mo ago
So basically it would just be referencing the location of the block location when using the command?
QarthO
QarthO9mo ago
Only the first time. Ya
Divinus
DivinusOP9mo ago
Okay! Awesome Hey guys! I think I misunderstood this, were you guys making this? If so, could i snag it?
Snow Kit
Snow Kit9mo ago
I didn't write anything, unsure about @Jenkins or @QarthO
Divinus
DivinusOP8mo ago
Darn. Thought that was what was happening.
QarthO
QarthO8mo ago
I can write you one will be able to do it tomorrow since i got no plans this weekend
Divinus
DivinusOP8mo ago
I would love you forever. ❤️ Hey! Was just curious if there was an update on this? Thank you! ❤️
Jenkins
Jenkins8mo ago
Hey, I'm sorry I just keep about forgetting about this lol I'll try to do it but it seems tricky to do because of how Minecraft handles enchanting tables
QarthO
QarthO8mo ago
ty for pinging me, completely forgot about it. I threw something ugly together but it is working. I plan on adding a lot more features and polishing it Currently a player can do "/enchant" and it will open up an enchantment table UI However that enchant table ui is only as if the enchanting table had no bookshelfs Although, I made it so an admin can create an enchantment table, and then set that as the enchantment table the command uses. Basically you'll be able to create a lvl 30 enchanting table at spawn. then do "/enchanter set" (while looking at it) and it will set the enchanting table. Now whenever anyone does the command it'll be a lvl 30 enchanting table (or whatever lvl that enchanting u set is)
Divinus
DivinusOP8mo ago
Oh that is perfect!
QarthO
QarthO8mo ago
https://github.com/QarthO/qRemoteEnchanting/actions/runs/9365718725 if you have a github account you can login, then you should be able to download the dev build that was made
GitHub
fix ci · QarthO/qRemoteEnchanting@223e4dd
Use your enchanter wirelessly via a command or item! - fix ci · QarthO/qRemoteEnchanting@223e4dd
QarthO
QarthO8mo ago
I'd recommend testing it first to make sure it works. I'll keep working on it today and tomorrow. Theres still some missing messages, and config stuff. but the core functionality should work i also want to make it so that players can link their own enchanting table (if a server doesnt want to give a default of 30) make sure u give
qremoteenchanting.group.player
qremoteenchanting.group.player
permission if u want players to be able to do /enchant Also in the config there is a "aliases" section you can use to do whatever aliases u want
Divinus
DivinusOP8mo ago
This is awesome! Thank you so much!
QarthO
QarthO8mo ago
its very ugly... but just wanted to get something out real quick since i completely forgot
Divinus
DivinusOP8mo ago
Haha listen there is no worries from me. We're still in beta so this is the perfect time to test it out
QarthO
QarthO8mo ago
👍 expect a much more polished version out tomorrow
Divinus
DivinusOP8mo ago
You got it boss! Hey! Just checking in! There is no rush to this at all, just inquiring! 😄
QarthO
QarthO8mo ago
no worries! havent gotten much time to work on it, but still planning on doing more work with it tonite were you able to play around with the dev build at all?
Divinus
DivinusOP8mo ago
I have not, I was planning on doing so this weekend!
QarthO
QarthO8mo ago
well lucky for u, im travelling tomorrow and i'll haveseveral hours with just my laptop and nothing to do so there will def be a much better build out tomorrow
Divinus
DivinusOP8mo ago
Ohhhh those weekends are the worst though I'm so sorry😭Hopefully you get to at least have some time to relax.
QarthO
QarthO8mo ago
I actually don’t mind it, nice to do nothing
Divinus
DivinusOP8mo ago
So, I have gone to tinker with the build atm, and it's currently not functional at all. Using /enchanter set pulls up unknown command, and the plugin does not populate in the /plugins command. We are running 1.20.4, if that is relevant to the situation! 😄
QarthO
QarthO8mo ago
what paper build are you using? if i had to blindly guess its because its setup for java 21 on for paper 1.20.6 any reason ur using 1.20.4 still?
Divinus
DivinusOP8mo ago
Mostly because 1.20.4 was the most recent stable build when we started the process and a lot of our plugins fit better with 1.20.4 at the moment.
QarthO
QarthO8mo ago
let me know wat paper build (or purpur or pufferfish or whatever ur using) and ill make sure it'll work with that version also i'd recommend updating to 1.20.6 when u can, pretty much all the standard plugins have supported 1.20.6 now since its been out for a month now
Divinus
DivinusOP8mo ago
We are currently on pufferfish 1.20.4! But we do plan on going to 1.20.6 in the future I apologize for that
QarthO
QarthO8mo ago
no worries
QarthO
QarthO8mo ago
@Divinus https://github.com/QarthO/qRemoteEnchanting/actions/runs/9431832414 new build can download here. I also changed the permissions needed to use it to directly use the /enchanter: "q.enchanter.use"
GitHub
updated messages · QarthO/qRemoteEnchanting@d0eea62
Use your enchanter wirelessly via a command or item! - updated messages · QarthO/qRemoteEnchanting@d0eea62
QarthO
QarthO8mo ago
@Divinus ok actually just pushed out another build, you now should be able modify the messages in the messages.yml now, and u can change the chat prefix if u want, then u can just do /enchanter reload messages to reload it (or u can just do /enchanter reload and it'll reload the config and messages... haven't implemented reloading the enchanters.yml file yet)
Divinus
DivinusOP8mo ago
You are the best ❤️ Hmm... Put in the new build and running into the same issue.
QarthO
QarthO8mo ago
Can you share your logs? Maybe it’s spitting out some errors on startup And share your pufferfish build number. I tried on puffefish 1.20.4 build #51 and working perfectly. Logs will help out a lot Just upload your latest.log to mclogs im dumb, i figured out the issue, i was testing on pufferfish 1.20.4, but was still testing with java 21. since i compiled the jar with java 21 it was working for me, i compiled it with java 17 now, it should work this time i promise @Divinus
Divinus
DivinusOP8mo ago
Bahah, love it! I'll check once I'm off work 🙂
Divinus
DivinusOP8mo ago
No description
Divinus
DivinusOP8mo ago
No description
Divinus
DivinusOP8mo ago
I apologize, I forgot my dev made it back to paper
ProGamingDk
ProGamingDk8mo ago
thats a java version error yeah the plugin is still compiled for java 21
QarthO
QarthO8mo ago
try now, also headsup i redid the set command, just follow the tab complete, however didnt fully setup the player/personal ones. So you’ll get a no worky message If the default is broken, just go back to the actions run before i the commit where i redid it @Divinus
Divinus
DivinusOP8mo ago
I apologize for the late response. It's been a super busy week. But I am here now. xD
QarthO
QarthO8mo ago
ur good, im out of traveling, so only have free time for like 20min here and there, so not been doing much work on it. lmk if its working for ya
Divinus
DivinusOP7mo ago
Alright going to go ahead and download this and give it a shot! Unfortunately it still didn't work. Not sure why honestly. I apologize for the delay we're releasing tomorrow and it's been very hectic
QarthO
QarthO7mo ago
How about you share your logs lmao can’t help at all if u don’t share any info
Divinus
DivinusOP7mo ago
I apologize. How can I go about sharing my logs! 😄 And should this log be when the server has or does not have the plugin installed
QarthO
QarthO7mo ago
Stop the server put the plugin in the server Start the server Run the command Share the latest.log file by uploading it to mclogs and sharing the link And tell me what isn’t “working”
QarthO
QarthO7mo ago
mclo.gs - Paste, share & analyse your Minecraft logs
Easily paste your Minecraft logs to share and analyse them.
QarthO
QarthO7mo ago
https://github.com/QarthO/qRemoteEnchanting/actions/runs/9480589278#artifacts And make sure using the jar from the most recent actions, not an old one
GitHub
ci fix · QarthO/qRemoteEnchanting@87bb670
Use your enchanter wirelessly via a command or item! - ci fix · QarthO/qRemoteEnchanting@87bb670
QarthO
QarthO7mo ago
Also I haven’t tested it in 1.21, so I have no clue if it still works there
Divinus
DivinusOP7mo ago
Yeah we're not 1.21, and won't be for a while. We're running 1.20.4 rn probably will til we can get to 1.21 with all our plugins. Also, realized I was using the old .jar. Restarted with new. Will update you as soon as it runs
QarthO
QarthO7mo ago
Why are u atleast not on 1.20.6? Makes no sense to launch a server on 1.20.4 when 1.21 just released
Divinus
DivinusOP7mo ago
Honestly that's a great question. Our dev suggested we go to 1.20.4 since we were on 1.20.2 when we first started our beta a month ago. I'm not sure why we didn't go to 1.20.6. Also, it appears to be working! Got the /enchanter set and did /ench and it brought up the GUI. testing with some more things
QarthO
QarthO7mo ago
You will need to make sure u give ur players a permission in order to use it I can’t remember I’m on my phone
Divinus
DivinusOP7mo ago
Absolutely, I got the permission you sent earlier and will begin to implement it!
QarthO
QarthO7mo ago
But yeah, it just seems really not smart to release a server on 1.20.4 Well I think I changed the permission ^ This was it
Divinus
DivinusOP7mo ago
Awesome. Thank you so much for this btw. You are a lifesaver. Sorry I was so difficult to work with, I'm new to the server industry and still learning things
QarthO
QarthO7mo ago
You should really speak with your dev tho. Saving an extra hour of dev work by choosing to not update the plugins just so ur players can’t play on new stuff is a really good way to make sure ur players aren’t interested 1.21 added a lot of fun stuff like crafter and trials chamber. people will be upset if they can’t play with them 1.21 has been out long enough all the big plugins have already update and support it
Divinus
DivinusOP7mo ago
I will speak with them!
Divinus
DivinusOP7mo ago
Okay so, spoke with them.
No description
Divinus
DivinusOP7mo ago
Was also wondering. Is there any way I can edit the amount of times someone can enchant in a IRL day? Or is that something I can add through permissions?
QarthO
QarthO7mo ago
1.20.4 - 1.21 has massive differences. It’s not minimal I could set this up for you
Divinus
DivinusOP7mo ago
I'd love that! Would i need to tell you how many times I'd want it or would it be customizable?
QarthO
QarthO7mo ago
I’ll customize it
Divinus
DivinusOP7mo ago
Well to 1.21 yeah I definitely agree. Idk about 20.4 to 20.6 though. I am not a master at that
QarthO
QarthO7mo ago
Yeah, well every player in a survival server will be asking about the 1.21 changes so that’s the only relevant thing here. Pointless to compare 2 older versions
Divinus
DivinusOP7mo ago
Well we're doing an RP server, so nobody's asked about 1.21 yet for us. So at least that's good! Was also gonna follow up with this! 😄 We were wanting 20 times a day to be max per person.

Did you find this page helpful?