AaronG85 Posted October 8 Share Posted October 8 Is there an XML way of adding a new item (Raw Gold) that can be smelted in a forge to create a new item (Gold Bar)? Link to comment Share on other sites More sharing options...
zztong Posted October 8 Share Posted October 8 You can make it all functional with XML, but to support appearances (icon pictures and 3D assets) you either need to either use existing game assets or make them, put them where the game can find them, and then have XML refer to them. I suggest finding an existing modlet similar to what you want and explore its contents. Also, look to the game's items.xml and recipes.xml files. 1 Link to comment Share on other sites More sharing options...
BFT2020 Posted October 8 Share Posted October 8 Here is an example where I created two new ingots for someone https://github.com/BFT2020/A21LeadBrassIngots.git 1 Link to comment Share on other sites More sharing options...
AaronG85 Posted October 9 Author Share Posted October 9 11 hours ago, BFT2020 said: Here is an example where I created two new ingots for someone https://github.com/BFT2020/A21LeadBrassIngots.git This worked perfectly my items to be able to be crafted using brass and clay but is there a way to add an additional forged type (like clay, brass, lead) so you have to smelt a new ingrediant to create a new item? Link to comment Share on other sites More sharing options...
zztong Posted October 9 Share Posted October 9 30 minutes ago, AaronG85 said: This worked perfectly my items to be able to be crafted using brass and clay but is there a way to add an additional forged type (like clay, brass, lead) so you have to smelt a new ingrediant to create a new item? This is beyond what I've look at or tried to do. I suspect messing with the forge's capabilities will involve getting to know the UI XML files and then probably code. I'm sure there are others here who know for sure, but if you get no answer then I'd be asking folks on GuppyCur's discord. 1 Link to comment Share on other sites More sharing options...
Cranberry Monster Posted October 10 Share Posted October 10 Everything I know about adding smeltable stuff came from Meancloud's Mining: Not sure if the mod's been updated for A21, but the basics should still apply. Basically, you'll want to first check out windows.xml in the XUi subfolder. This is where you add your new materials to the accepted forge materials, and add the additional slots to display them. Next, you'll need entries for your new ores and such in materials.xml. Then, in items.xml, you need both a "resource" and "unit_" for each of your ores. If I remember correctly, resource is the form used outside of the forge, unit_ is the stuff stored inside it. In recipes.xml, you'll need <wildcard_forge_category> recipes for each of your new ores, which I believe lets you smelt them into the forge, and a second set of recipes to run the smelted materials back out of the forge again. Plus, you'll put the recipes that actually uses the ores there, too. And finally, you add your actual sources of ore in blocks.xml. Hope that gets you started. Like I said, see what's going on in MeanCloud's Mining and it should all fall into place. 2 Link to comment Share on other sites More sharing options...
BFT2020 Posted October 12 Share Posted October 12 On 10/10/2023 at 7:31 PM, Cranberry Monster said: Not sure if the mod's been updated for A21, but the basics should still apply. Basically, you'll want to first check out windows.xml in the XUi subfolder. This is where you add your new materials to the accepted forge materials It's that easy? I was trying to figure out how to add the new materials to the forge and never done that portion before, glad someone was able to help the OP. I never thought to look inside the XUi subfolders. I was looking in all the xml files in the main config folder seeing how they add material types to forges 1 Link to comment Share on other sites More sharing options...
AaronG85 Posted October 13 Author Share Posted October 13 On 10/11/2023 at 10:31 AM, Cranberry Monster said: Everything I know about adding smeltable stuff came from Meancloud's Mining: Not sure if the mod's been updated for A21, but the basics should still apply. Basically, you'll want to first check out windows.xml in the XUi subfolder. This is where you add your new materials to the accepted forge materials, and add the additional slots to display them. Next, you'll need entries for your new ores and such in materials.xml. Then, in items.xml, you need both a "resource" and "unit_" for each of your ores. If I remember correctly, resource is the form used outside of the forge, unit_ is the stuff stored inside it. In recipes.xml, you'll need <wildcard_forge_category> recipes for each of your new ores, which I believe lets you smelt them into the forge, and a second set of recipes to run the smelted materials back out of the forge again. Plus, you'll put the recipes that actually uses the ores there, too. And finally, you add your actual sources of ore in blocks.xml. Hope that gets you started. Like I said, see what's going on in MeanCloud's Mining and it should all fall into place. This worked 100% and i now have a working custom forge with smelting custom items, thanks so much 2 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now