Norby007 Posted October 7, 2023 Share Posted October 7, 2023 table.insert(ProceduralDistributions["list"]["BurgerKitchenFridge"].items, "mod.newobject"); table.insert(ProceduralDistributions["list"]["BurgerKitchenFridge"].items, 2); "BurgerKitchenFridge" -> Is there a list of these locations that can be used? In particular I am looking for the locations used for the Theater counters, crates, shelves, fridge, and freezers. Thank you! -Norby Link to comment Share on other sites More sharing options...
Norby007 Posted October 14, 2023 Author Share Posted October 14, 2023 No real list, but I found a the lists in the file ProceduralDistributions.lua in PZ's folder here... \ProjectZomboid\media\lua\server\Items each list item looks like this: PizzaKitchenButcher = { rolls = 4, items = { "KitchenKnife", 6, "MeatCleaver", 4, "Pepperoni", 50, "Pepperoni", 20, "Pepperoni", 20, "Pepperoni", 10, "Pepperoni", 10, "Twine", 10, }, junk = { rolls = 1, items = { "Apron_White", 20, "CuttingBoardPlastic", 100, } } }, In this example: PizzaKitchenButcher is the name and I believe that the number afterwards is a percentage. So to make this work in your mod, you would add this line in your shared items directory. table.insert(ProceduralDistributions["list"]["PizzaKitchenButcher"].items, "Base.Sausage"); table.insert(ProceduralDistributions["list"]["PizzaKitchenButcher"].items, 10); and then it would spawn sausages in the pizza kitchens... Took me a while to understand this... My big question now, is how to add a room counter location. In the Distribution file are the locations but the theatre counters only have cleaning supplies and I want to add a distribution list like "TheatreSnacks" so they are added to the counters. Is there a way to do this in a mod by adding code to a distributions file in shared directory? theatre = { counter = { procedural = true, procList = { {name="StoreCounterCleaning", min=0, max=99, forceForTiles="location_shop_accessories_01_0;location_shop_accessories_01_1;location_shop_accessories_01_2;location_shop_accessories_01_3;location_shop_accessories_01_20;location_shop_accessories_01_21;location_shop_accessories_01_22;location_shop_accessories_01_23;fixtures_sinks_01_0;fixtures_sinks_01_1;fixtures_sinks_01_2;fixtures_sinks_01_3;fixtures_sinks_01_4;fixtures_sinks_01_5;fixtures_sinks_01_6;fixtures_sinks_01_7;fixtures_sinks_01_8;fixtures_sinks_01_9;fixtures_sinks_01_10;fixtures_sinks_01_11;fixtures_sinks_01_16;fixtures_sinks_01_17;fixtures_sinks_01_18;fixtures_sinks_01_19"}, } } }, Link to comment Share on other sites More sharing options...
Norby007 Posted October 15, 2023 Author Share Posted October 15, 2023 I tried something like this but it did not work. table.insert(SuburbsDistributions["theatre"]["counter"].procList, name="TheatreSnacks"); table.insert(SuburbsDistributions["theatre"]["counter"].procList, min=0); table.insert(SuburbsDistributions["theatre"]["counter"].procList, max=99); table.insert(SuburbsDistributions["theatre"]["counter"].procList, weightChance=60); Link to comment Share on other sites More sharing options...
excon Posted October 18, 2023 Share Posted October 18, 2023 Link to comment Share on other sites More sharing options...
Norby007 Posted October 18, 2023 Author Share Posted October 18, 2023 2 hours ago, excon said: Thank you for your response. I have seen this and it explains a lot except how to add the TheaterSnacks list into the theatre counters list. I built a work around but it's not using the tables. I just force feed the counters in the theater and made some user settable options to lower or increase the amounts. example, this code will add the Fountain Cup into the theatresnacks list. table.insert(ProceduralDistributions["list"]["TheatreSnacks"].items, "FunctionalAppliances.FAFountainCup"); table.insert(ProceduralDistributions["list"]["TheatreSnacks"].items, 10); But if you go into the distributions file in project zomboid, the theatresnacks list is never used. I suspect it was supposed to be added to the theatre tables in the distribution file. theatre = { counter = { procedural = true, procList = { {name="StoreCounterCleaning", min=0, max=99, forceForTiles="location_shop_accessories_01_0;location_shop_accessories_01_1;location_shop_accessories_01_2;location_shop_accessories_01_3;location_shop_accessories_01_20;location_shop_accessories_01_21;location_shop_accessories_01_22;location_shop_accessories_01_23;fixtures_sinks_01_0;fixtures_sinks_01_1;fixtures_sinks_01_2;fixtures_sinks_01_3;fixtures_sinks_01_4;fixtures_sinks_01_5;fixtures_sinks_01_6;fixtures_sinks_01_7;fixtures_sinks_01_8;fixtures_sinks_01_9;fixtures_sinks_01_10;fixtures_sinks_01_11;fixtures_sinks_01_16;fixtures_sinks_01_17;fixtures_sinks_01_18;fixtures_sinks_01_19"}, } } }, theatrekitchen = { isShop = true, counter = { procedural = true, procList = { {name="StoreCounterCleaning", min=0, max=99, forceForTiles="location_shop_accessories_01_0;location_shop_accessories_01_1;location_shop_accessories_01_2;location_shop_accessories_01_3;location_shop_accessories_01_20;location_shop_accessories_01_21;location_shop_accessories_01_22;location_shop_accessories_01_23;fixtures_sinks_01_0;fixtures_sinks_01_1;fixtures_sinks_01_2;fixtures_sinks_01_3;fixtures_sinks_01_4;fixtures_sinks_01_5;fixtures_sinks_01_6;fixtures_sinks_01_7;fixtures_sinks_01_8;fixtures_sinks_01_9;fixtures_sinks_01_10;fixtures_sinks_01_11;fixtures_sinks_01_16;fixtures_sinks_01_17;fixtures_sinks_01_18;fixtures_sinks_01_19"}, } }, crate = { procedural = true, procList = { {name="CratePopcorn", min=0, max=99, weightChance=100}, {name="CrateSodaBottles", min=0, max=99, weightChance=40}, {name="CrateSodaCans", min=0, max=99, weightChance=60}, } }, freezer = { procedural = true, procList = { {name="TheatreKitchenFreezer", min=0, max=99}, } }, fridge = { rolls = 1, items = { } }, metal_shelves = { procedural = true, procList = { {name="CratePopcorn", min=0, max=99, weightChance=100}, {name="CrateSodaBottles", min=0, max=99, weightChance=40}, {name="CrateSodaCans", min=0, max=99, weightChance=60}, } }, }, theatrestorage = { crate = { procedural = true, procList = { {name="CratePopcorn", min=0, max=99, weightChance=100}, {name="CrateSodaBottles", min=0, max=99, weightChance=40}, {name="CrateSodaCans", min=0, max=99, weightChance=60}, } }, }, My guess is this is a mistake or missed opportunity. I do not know how to insert {name="TheatreSnacks", min=0, max=99}, into the existing distribution table from a mod... so close yet so far... 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