Started by
DerexXD
on
Topic category: Help with Minecraft modding (Java Edition)
I need someone to help me make a simple artifact using the curios API. Someone here made a plugin for it but I'm not sure where to go after installing it.
For reference, curios is the widely used API that allows you to put rings and stuff on you in inventory slots. You find it in many modpacks.
Not a single soul knows it. Or if they know they just doesn't want to help. Asked around the community many times, they doesn't even seems like that they care about the question.
The stuff is that you have to make your own slots but idk how the hell should we do that if its read only to me when I've installed the API also there is just no proper help about this.
https://github.com/TheIllusiveC4/Curios/wiki/How-to-Use:-Developers
https://github.com/TheIllusiveC4/Curios/wiki/Frequently-Used-Slots
More info here on the mcreator website:
https://mcreator.net/forum/69321/info-curios
After adding it as an API, you need to register the curio slot types in the InterModEnqueue event. Then after registering the slot type, you need to add your item to the tag called as your slot type. The tag must be in the curios namespace.
And after that, your item can be worn, but if you need additional functionality, you will need to either add ICurio as a capability, or just implement ICurioItem on your item.
All of this, of course, is custom-coded. I can help you with implementing this, or you can try to do it yourself.
Curio documentation
I understand what you're saying but I'm kinda a novice so where would you find the event in code
I can do the rest from there as I get what you're saying
Yeah I would really like help just registering the item
holy (beep) I figured it out on my own
What did you do? How did you figure it out? Can you walk me through it?
how
Wait bro how
Tell me
Man please a lot of us need help on how to make a curios item, could you explain us how you did it ?
It was all on the curios wiki you just add it to the intermodqueue event and stuff and registering types is really easy too
But where do you find that event???
I found out how to do this, so I'll contribute to this thread!
Note: This is the way I do it, it may be wrong or weird but it works for me, so I hope it works for you.
First you need to register a Curios slot (This is assuming you've already added Curios as a dependency through the workspace settings, whether manually or with a plugin). This is the slot in the Curios inventory where you'll put your custom curios. To register a Curios slot you need to create a new custom code element.
Then, once the element is made, there are a few things you need to import, these are for the Curios API and IMC messages. Put these at the top of the element:
If you're using a custom slot (explained below), you'll need an extra line:
After you've got those done, you need to put this listener (Correct me if it's not a listener, I'm new to Java) between the first @SubscribeEvent line and the main element class (public ElementName() {})
Then, inside this listener (Again, correct me if it's not a listener), you can put the IMC (InterModComms) message. You can choose a preset (Frequently Used Slots) or make your own slot, which requires a little more work.
Curios Preset IMC message (For Head slot):
If you want to change the preset, change HEAD (between SlotTypePreset and getMessgeBuilder() ) to what preset you want to use in Frequently Used Slots, make sure it's all in uppercase.
Curios Custom slot IMC message:
The identifier of the slot is determined by what you put in the string after SlotTypeMessage. This is the identifier you'll use, but to set a visible name, you'll have to go to the "Localization" tab in your MCreator workspace, and create a new entry with the key being "curios.identifier.identifierName", with identifierName being the string you put in the IMC message.
Once you've done this (you can put multiple if you want more slots) you can mark an item as an accessory, which you can find the tutorial for here. (The data folder is in MCreatorWorkspaces\yourMod\src\main\resources\data)
I really hoped this helped someone, and if this worked for you, let me know!