Topic category: Help with Minecraft modding (Java Edition)
I have a mod called Essentia that I am currently working on, and my main problem is these Pot Holders I have created. They are meant to serve as a conversion chart to convert a most recently downgraded ingot to the same version as the Pot Holder it is made out of. I know how to do that, but I have a question. I have a button that is labeled as "Convert To Next Rank," and I have an input and output slot to place the downgraded ingot in, and for the output to give the outcome upgraded ingot. My only problem is that in the procedure, Im not sure how to make it so that only if there is actually an ingot in the slot, that it will grant me the upgraded version, and not just giving me the upgraded version when the button is clicked when nothing was in the input slot to be cleared to begin with. Can Someone please help? i can clarify any way!
There is a procedure called "get item in slot []". All you have to do is test if the item in the specified slot is equal to iron ingot, or gold ingot, etc.
where can I find this procedure? what category?
Well I found it, But i still haven't the slightest clure of where I could use this though!
IF: (get item in slot [slot number of GUI slot]) = (item you want to test for)
The red "=" block can be found in the logic section
The (item you want to test for) block is in the Minecraft Components section. Just double-click it and select the item.
awesome! thanks for the help!
now! If i could just acquire your help for one last thing! I want to make it so that when I convert these downgraded items, that they convert to more than just one ingot. For example, If i were to convert one fragment once, it would put the upgraded ingot in the output slot right? but when I click it a second time, the fragment disapears but the upgraded ingot in the output stays at a constant 1 ingot, (not increasing). This is now my main focus problem
The procedure I have came up with is: [(Get Number Of Items From [Slot 1] of block at x y z if it has inventory) + 1]
Output slot is 1 BTW
[(Then Jeblin Ingot) In (slot 1) of the currently open GUI of Event/Target Entity]
Hard to figure out what I did wrong.....
Could you post a screenshot of your procedure? I think I need a visual to better understand your problem
I also dont know how to make it check for a specific item. Im making a gui where you place one specific item in and throw any other item in the other two slots, then you press a button to convert it into a bar. How do I do that?
I also dont know how to make it check for a specific item. Im making a gui where you place one specific item in and throw any other item in the other two slots, then you press a button to convert it into a bar. How do I do that?