Frepo Posted January 31, 2023 Report Posted January 31, 2023 (edited) On to the next problem that's been bugging me for ages. Trying to add a new non-placeable liquid (just like eg. tannin). Copied the weaktanninportion.json, made my own texture, formatted the json to my adhesiveportion.json, and thought that would be just about it. But oh neeeeooow... the game crashes during server startup. Log files complaining about "can't create itemstack without a collectible!" and " send ServerAssets failed". Dunno what that's all about... yet. Spoiler { code: "adhesiveportion", class: "ItemLiquidPortion", matterState: "liquid", attributes: { handbook: { ignoreCreativeInvStacks: true }, waterTightContainerProps: { containable: true, itemsPerLitre: 100, texture: { base: "liquid/adhesive" }, allowSpill: true, whenSpilled: { action: "DropContents", stack: { type: "item", code: "adhesiveportion" } } } }, shape: { base: "game:item/liquid" }, texture: { base: "liquid/adhesive" }, creativeinventoryStacks: [ { tabs: ["general", "liquids"], stacks: [ { type: "block", code: "game:woodbucket", attributes: { ucontents: [ { type:"item", code: "adhesiveportion", makefull: true } ] } } ] } ], maxstacksize: 5000, materialDensity: 200, guiTransform: { translation: { x: 0, y: 1, z: 0 }, rotation: { x: 123, y: -33, z: -13 }, origin: { x: 0.5, y: 0, z: 0.5 }, scale: 1.4 }, fpHandTransform: { translation: { x: 0, y: 0, z: 0 }, rotation: { x: 25, y: 157, z: -5 } }, tpHandTransform: { translation: { x: -1.5, y: -1, z: -1.4 } } } client-crash.txt Edited January 31, 2023 by Frepo
Frepo Posted January 31, 2023 Author Report Posted January 31, 2023 (edited) UPDATE ON RECENT EVENTS IN THIS MYSTERY Changed "game:woodbucket" to just "woodbucket". The game doesn't crash anymore, but gets stuck in an infinte loading screeen at end of server startup. This removed the critical error "send ServerAssets failed", but gave me instead[Warning] Failed resolving a blocks blockdrop or smeltedstack with code fregtech:woodbucket in Creative inventory stack of Item fregtech:adhesiveportion and[Error] System.NullReferenceException: The object reference has not been set to an instance of an object. makes sense in a way, cuz there is no fregtech woodbucket, just vanilla woodbucket. Edited January 31, 2023 by Frepo
Frepo Posted January 31, 2023 Author Report Posted January 31, 2023 (edited) THE SOLUTION Turns out you need your own bucket to go with the liquid to explicitly specify your modid in creativeinventoryStacks. Edited February 2, 2023 by Frepo
DArkHekRoMaNT Posted February 1, 2023 Report Posted February 1, 2023 (edited) 16 hours ago, Frepo said: THE SOLUTION Turns out you need your own bucket to go with the liquid. Try explicitly specifying your modid in creativeinventoryStacks (fregtech:adhesiveportion instead of adhesiveportion). As last resort, try putting the liquid json in assets/game instead of assets/fregtech. You definitely do not need to create a second bucket for this Edited February 1, 2023 by DArkHekRoMaNT
Frepo Posted February 2, 2023 Author Report Posted February 2, 2023 Hey! That worked! Thanks man! I didn't know adding your modId was a thing, I always thought it was supposed to be left empty when using own assets, and "game:" for using vanilla assets. Thanks again man.
Recommended Posts