Soren Posted July 22, 2023 Share Posted July 22, 2023 (edited) Solved! I need some help. I've followed tutorial videos to get this far. The mod loads without error but no drops seem to be occurring. Any guidance would be awesome. Thanks! Please note I have the item drop set at 100 to test only, attempted at 1 same result. This is the item.txt (SVFlares.txt) is as follows: [spoiler][code]/** Temporary replacement for "Keycards" **/ module SupplyFlares { imports { Base } /* */ /* Items */ /* */ item FlareBrown { Type = Normal, DisplayName = Brown Supply Flare, Icon = FlareBrown, Weight = 0.1, } }[/code][/spoiler] The Lua(SVFlares.lua) file is as follows: [spoiler][code]Distributions = Distributions or {}; local distributionTable = { -- ===================== -- Room List (A-Z) -- ===================== all = { inventoryfemale = { rolls = 1, items = { "SupplyFlares.FlareBrown", 100, } }, inventorymale = { rolls = 1, items = { "SupplyFlares.FlareBrown", 100, } }, } } table.insert(Distributions, 1, distributionTable); --for mod compat: SuburbsDistributions = distributionTable;[/code][/spoiler] EDIT: The simplest code that worked for me was the following. This gave a 10 percent drop rate of the item on zomboid's. require 'Items/Distributions' table.insert(SuburbsDistributions["all"]["inventorymale"].items, "SupplyFlares.FlareBlue") table.insert(SuburbsDistributions["all"]["inventorymale"].items, 10) table.insert(SuburbsDistributions["all"]["inventoryfemale"].items, "SupplyFlares.FlareBlue") table.insert(SuburbsDistributions["all"]["inventoryfemale"].items, 10) Edited July 25, 2023 by Soren Link to comment Share on other sites More sharing options...
Hugo Qwerty Posted July 25, 2023 Share Posted July 25, 2023 This might help: https://steamcommunity.com/sharedfiles/filedetails/?id=2609939329 Soren 1 Link to comment Share on other sites More sharing options...
Soren Posted July 25, 2023 Author Share Posted July 25, 2023 2 minutes ago, Hugo Qwerty said: This might help: https://steamcommunity.com/sharedfiles/filedetails/?id=2609939329 I will look into this and see if it helps. Thank you. 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