Octan Corp Posted January 14 Report Posted January 14 My mod:https://mods.vintagestory.at/heavyforlonarmor Mod that I have compatibility problems with:https://mods.vintagestory.at/show/mod/11264 The problem is that my and this mod ovverite the game file "game:worldproperties/block/metal.json" the problem is that spearexpansion has always load priority. my added metal stays in game and isnt causing errors but It no longer can be made becasue alloy recipes are gone. I tied patching it with compatibility lib patch structure, but it didnt rly worked. help plzz heres the patch file \assets\heavyforlonarmor\compatibility\spearexpantion\patches there is the patch itself. [ { "file": "game:worldproperties/block/metal.json", "op": "addmerge", "path": "/variants", "value": [{code: "temporalit", meltPoint: 1668, boilPoint: 3287, density: 4510, specificHeatCapacity: 0.54, elemental: false, tier: 4}], "dependsOn":[{ "modid": "spearexpantion" }] }, { "file": "game:worldproperties/block/metal.json", "op": "addmerge", "path": "/variants", "value": [{code: "ancientgold", meltPoint: 1020, boilPoint: 1040, density: 4510, specificHeatCapacity: 0.54, elemental: false, tier: 3}], "dependsOn": [{ "modid": "spearexpantion" }] }, { "file": "game:worldproperties/block/metal.json", "op": "addmerge", "path": "/variants", "value": [{code: "hardmeteor", meltPoint: 1020, boilPoint: 1040, density: 4510, specificHeatCapacity: 0.54, elemental: false, tier: 3}], "dependsOn": [{ "modid": "spearexpantion" }] } ]
Solution The Insanity God Posted January 14 Solution Report Posted January 14 For as far as I can see your alloy recipe works just fine even with that other mod (though you are lacking a language string for material-ancientgold) Your real problem lies elsewhere, namely in the combustibleProps that are required to exist and have a melting point that is reachable with existing fuel sources for it to show up as moldable, which disappears once you add "spearexpantion". The reason why this happens is because both your mod and "spearexpantion" put patches inside the game domain folder with the same name (meaning the files themselves end up overriding each other). This is why you never put anything inside the game domain folder unless absolutely necessary. Simply move the patch files from "assets/game/patches" into "assets/heavyforlonarmor/patches" and prefix the target file with "game:" (some already have this) and problem is solved. 2
Brady_The Posted January 14 Report Posted January 14 (edited) Well, that solution was surprisingly (and might I add disappointingly) easy. This is btw an interesting side effect of the ModMaker. I can only assume that we will see more of this in the future. Edited January 14 by Brady_The
The Insanity God Posted January 14 Report Posted January 14 1 hour ago, Brady_The said: Well, that solution was surprisingly (and might I add disappointingly) easy. This is btw an interesting side effect of the ModMaker. I can only assume that we will see more of this in the future. Wait the modmaker puts stuff in game domain folder? I'm surprised I haven't seen this one before then.
Brady_The Posted January 14 Report Posted January 14 (edited) 1 hour ago, The Insanity God said: Wait the modmaker puts stuff in game domain folder? I'm surprised I haven't seen this one before then. Don't mind me, I am just an AI hallucinating things. The ModMaker doesn't do that, but it generates the same file names. So if people use the ModMaker and put patches into the game domain (because that's what you do if you refuse to go through the wiki tutorials to understand the finer details of modding VS) you'll get those results. Hm, I wonder if those domain issues are mentioned anywhere on the wiki. I might have to take a look. Edited January 14 by Brady_The 1
Octan Corp Posted January 14 Author Report Posted January 14 rly thanks for the solution i will try it soon cause now its a lil bit turbulent. By th way i didnt use modmaker XD i didnt know it even existed I just looked at what other mods are doing and just figuring things out by reverse engineering stuff 1
Spoonail Posted January 14 Report Posted January 14 (edited) The JSON Patching page on the wiki states ModMaker uses the `game` domain by default: https://wiki.vintagestory.at/index.php/Modding%3AJSON_Patching > By default, when you generate a mod using ModMaker 3000™, the folder structure will use game as the domain, and use the same file name as the vanilla JSON file. This can lead to mod conflicts. But I tested ModMaker in VS1.21.6, 1.20.12, and 1.19.8, and could not reproduce the issue. It might have been the case in versions older than 1.19. Edited January 14 by Spoonail 2
Brady_The Posted January 14 Report Posted January 14 (edited) 2 hours ago, Octan Corp said: I just looked at what other mods are doing and just figuring things out by reverse engineering stuff That's how you do it! I personally would go ahead and move all patches into the heavyforlonarmor domain. This happened once. It can happen again if somebody else is using ModMaker created patches to modify something you change too. All but the first three of your patches fit the ModMaker naming pattern. Edited https://wiki.vintagestory.at/Modding:JSON_Patching#File_Path_and_Name_Considerations to reflect current implementations. Edited January 14 by Brady_The 1
Octan Corp Posted January 18 Author Report Posted January 18 I finnaly had the time to implement the fix. it worked like a charm. rly rly thanks for helping me ya all vs community is by far the best and most helpfull one ive encountered in games by far. this is one of one the reasons I made this mod it the first place to be part of it tyyyy 2
Recommended Posts