#mod_development

1 messages ยท Page 498 of 1

austere quest
#

Hey man! Did you find any list of working mods for 41.61mp ?

atomic oyster
#

There are mods that work well but the process of installing them via hosting requires some tinkering on where to place files

weary matrix
#

Any clue how to add new key bindings to this screen?

#

I found the place where they are defined, it's in lua/shared/keyBinding.lua but not sure how to add to it

#

oh but the keyBinding table is global so I can just add to it ๐Ÿ˜…

austere quest
#

Any link to guides regarding mods intallation for Dedicated Servers? Dont wanna be asking here things that pybly where asnwered already

drifting ore
#

Do none of the death sound mods work?

#

trying MGS death sounds and it was just silent

mint sphinx
#

how would you make a Moveable object there split it self op in (x/y) parts?

dim geode
#

good modding idea, being able to change global time settings for a time lapse. could make for interesting youtube content. thought this might be a thing in the cheatmenu mod but i wanted to throw this here and hear feedback about it

dim geode
#

maybe you can with debug mode as well

slow rock
#

is there a mod to change sudden panic sound when u suddenly find zeds in a corner

#

thing kills my ears

willow estuary
slow rock
mint sphinx
slow rock
#

ah

weary matrix
#

so I found out how to add new keybinding to option menu, but when I try to change the keybinding for my new key, it keeps the old one. I guess this has to do with my Lua getting reloading when saving the options. So how do I save custom mod data? AFAIK getModData etc is not available until you actually start a game?

#

damn but that wouldn't solve my issue, mmm

brittle jewel
#

@weary matrix I think this is all I have for it in defecation. It's added after 'Zoom out'. I can change the keys without issue. I don't have this in a function or anything, it's just ran always when my mod is loaded.

--Menu keybind code
--We need to use the global keyBinding table, this stores all our binding values
local index = nil -- index will be the position we want to insert into the table
for i, b in ipairs(keyBinding) do
    --we need to find the index of the item we want to insert after
    if b.value == "Zoom out" then
        index = i
        break
    end
end

if index then --use index from above
    table.insert(keyBinding, index+1, {value = "DefecationStatus", key = 51})
    table.insert(keyBinding, index+2, {value = "DefecationStatus2", key = 52})

    local oldCreate = MainOptions.create

    function MainOptions:create()
        oldCreate(self)
    end
end
quasi geode
#

heh. that code looks familiar.

#

still working in newer builds?

brittle jewel
#

Yep! I knew I copied it from somewhere long ago.

#

Persists after game is quit, or even if the mod is unloaded/reloaded.

quasi geode
#

probably there XD

#

its probably populated to a few different mods now though

#

orgm's version


-- Setup hotkey bindings
-- We need to use the global keyBinding table, this stores all our binding values
local index = nil -- index will be the position we want to insert into the table
for i,b in ipairs(keyBinding) do
    if b.value == "Equip/Unequip Stab weapon" then
        index = i -- found the index, set it and break from the loop
        break
    end
end

if index then
    -- we got a index, first lets insert our new entries
    table.insert(keyBinding, index+1, {value = "Equip/Unequip Pistol", key = 5})
    table.insert(keyBinding, index+2, {value = "Equip/Unequip Rifle", key = 6})
    table.insert(keyBinding, index+3, {value = "Equip/Unequip Shotgun", key = 7})
    table.insert(keyBinding, index+4, {value = "Reload Any Magazine", key = Keyboard.KEY_G })
    table.insert(keyBinding, index+5, {value = "Select Fire Toggle", key = Keyboard.KEY_Z })
    table.insert(keyBinding, index+6, {value = "Firearm Inspection Window", key = Keyboard.KEY_U })

end
#

lol

brittle jewel
#

Ah, that's where I got it from.

#

Probably not the best mod to be taking code from...

#

Err, still not exact. I'm not sure exactly where I got it from. It looks like a condensed version of yours. I don't think I modified much, but I've had it in there for years now.

quasi geode
#

ya i wrote that forum tutorial in 2018

#

seen it in a few mods though, so its been around a bit now XD

mint sphinx
#

by any chance have you work with moveable object ? like 2 tiles tables and how to make them ? ^^

weary matrix
#

@brittle jewel ah thanks, are you able to change the key binding in option menu with that code?

#

Hello @quasi geode ๐Ÿ˜‰

dim geode
#

any reason why my modsa rent showing up when I select them and try to host a server?

#

all of them are 41.6 updated

weary matrix
#

@quasi geode Oh my, it seems whenever you press a key on main screen, Lua gets reloaded (like I have a print statement at global scope in a mod, and it prints the string for every key press

#

I just hope it's not the same in game ๐Ÿ˜‚

brittle jewel
#

@weary matrix Yep I can change it with the menu options. 51 is comma by default and I tested by setting it to a numpad button. It saves after quitting the game, or even after deactivating and re-activating the mod.

weary matrix
#

@brittle jewel nice. I don't like to be hooking stuff in pz though, but I think I found a way without the hooking part

brittle jewel
#

Yeah, that's definitely never safe. I copied it years ago and never touched it again lol.

weary matrix
#

If I succeed I guess I'll add it to community API

quasi geode
#

lol i cant vouch for the behavior anymore i havent run it since b40

#

and reloading every keypress seems excessive ๐Ÿคจ

weary matrix
#

it is

#

not sure why it's happening

#

guess I should report it

#

also I should report the bug about the keyboard going crazy sometimes but it's hard to explain the bug, I'm tired of this one. Basically more than 50% of my character death are due to this bug

#

like you get too many zombies around you, you can escape by going left, so you press left, but the character is going the opposite direction, until you release the left key

agile swallow
#

Hey guys, I was wondering how do you turn on the sound visualization debug mode. I have debug mode enabled I just can't seem to find it.

mint sphinx
drifting ore
#

Do yall think some of the bigger mods like hydrocraft will add 3d models?

keen creek
#

i added several new locations, for some reason though both on my mini map and my map they dont show up at all, any idea how to fix?

mint sphinx
weary matrix
#

@mint sphinx to avoid this they would have to build the crafting window from a new thread but not sure you have access to threads from pzLua

weary matrix
hollow shadow
#

@weary matrix hey you got any idea what could be causing this error with my mod?

#

Callframe at: lower
function: sort -- file: crucibleCore.lua line # 59
function: @stdlib.lua -- file: null line # 52
function: @stdlib.lua -- file: null line # 63
function: sort -- file: crucibleCore.lua line # 64
function: getItems -- file: crucibleCore.lua line # 59
function: makeWindow -- file: crucibleMain.lua line # 174
function: worldobjects -- file: ISUICheatMenu.lua line # 488
function: onMouseUp -- file: ISContextMenu.lua line # 90

LOG : General , 1639593831099> 1639593831099 znet: ZNetFriends::OnPersonaStateChange
LOG : General , 1639593832902> Item -> Radio item = Radio.CDplayer
ERROR: General , 1639593832952> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: missing argument #1 to 'lower' at KahluaUtil.getArg line:380.
ERROR: General , 1639593832952> DebugLogStream.printException> Stack trace:

drifting ore
#

Would it be possible to make a workaround patch for guns not attracting zombies?
I dont know about modding zomboid, just barotrauma.
But could you have each gun shot call attractor like a silent car horn or something? Something we know does attract zombie in multiplayer right now.

agile swallow
#

Wait gunshots don't attract zombies right now?

hollow shadow
#

no xD

agile swallow
#

Bruh

hollow shadow
#

i already got aiming 5

weary matrix
#

@hollow shadow can you show line 59 of crucibleCode.lua please?

drifting ore
#

ya its just rambo right now

agile swallow
#

I was wondering why the whole mall wasn't getting alerted when my friend and I re-enacted dawn of the dead at the big louisville mall.

hollow shadow
drifting ore
#

cheatmenu works
just dont spawn 3d entities like zeds or cars. It will crash your server

hollow shadow
teal forum
#

Do you guys have problems too with Apocalypse Wheelz in MP ?

weary matrix
#

@hollow shadow which version of zomboid?

teal forum
#

(In 41.61)

hollow shadow
#

^^

weary matrix
#

@hollow shadow do you have the code somewhere I can see it?

hollow shadow
#

yeah ill try to dig it up

weary matrix
#

@hollow shadow you're not calling any function/method called lower() right?

hollow shadow
weary matrix
#

@hollow shadow mmm you do have some calls to string.lower() in there

hollow shadow
#

W hat

weary matrix
#

@hollow shadow Exception thrown java.lang.RuntimeException: missing argument #1 to 'lower'

#

I guess your call to getDisplayName() is not working properly?

#

or maybe you're calling it on an object that doesn't have it?

#

@hollow shadow try to do something like this:

crucibleCore.sort(function (a, b) print("DEBUG",a:getDisplayName(),b:getDisplayName()); return string.lower(a:getDisplayName()) < string.lower(b:getDisplayName()) end)```
hollow shadow
#

ok

weary matrix
#

if everything looks fine, then also try to print the type of a and b

hollow shadow
#

._.

#

i did put the debug in my oncreate.lua

mint sphinx
weary matrix
#

@mint sphinx yeah it is ๐Ÿ˜ฆ

weary matrix
hollow shadow
weary matrix
#

in your console.txt

#

%USERPROFILE%\Zomboid\console.txt

hollow shadow
#

yeah what do i search

weary matrix
#

@hollow shadow the lines you added to oncreate(), there should be DEBUG in the lines

hollow shadow
#

Hmm only vanilla debugs in there

weary matrix
#

@hollow shadow why did you move the lines to oncreate? What I gave you was not working?

hollow shadow
#

OH

#

Wait

#

I fixed it....

#

So

weary matrix
#

๐Ÿ˜„

hollow shadow
#

DOnt have an item that has 5.5 capacity

#

gmae doesnt like dat

#

5 or 6 is ok

#

co i need your help again

#

How do i make it so only specific items are allowed in my container

#

I saw the keyring has "Onlyacceptcategory"

#

but i think its coded to only work for keyring

#

Im making a toolbelt and everything that is considered a tool should be able to fit inside it.

#

but i want to make it balanced so people dont put metal sheets or 20 ammoboxes in it

keen creek
#

anybody able to help?

hollow shadow
weary matrix
#

@hollow shadow try to call setOnlyAcceptCategory on your container

weary matrix
hollow shadow
weary matrix
#

oh

hollow shadow
weary matrix
#

I think so

hollow shadow
#

._.

#

I dont know how to do any coding ,_,

weary matrix
#

but I have no idea really, but at least ItemContainer has a method setOnlyAcceptCategory

drifting ore
#

Im having trouble itelling if guns are just really quiet to zeds or if they are just deaf to most things

winter bolt
#

if its a method you can call then you might just be able to set the variable in the item script

#

maybe try "OnlyAcceptCategory"?

hollow shadow
weary matrix
#

@hollow shadow oh ok so yes try it in script

hollow shadow
#

but didnt work

hollow shadow
keen creek
#

any idea why after adding new map locations the map would just be white and nothing would show on it?

drifting ore
winter bolt
#

like specifically "OnlyAcceptCategory" or did you do this

#

maybe try removing the "set"

weary matrix
#

@hollow shadow yeah WITHOUT the set as suggested by @winter bolt

hollow shadow
winter bolt
#

ohh

#

hmm

weary matrix
#

@hollow shadow what category did you put?

hollow shadow
#

Tool

winter bolt
#

the code wouldnt be difficult assuming the method that co posted is correct, i'm just gonna check how to grab an item in a lua file

drifting ore
#

So for Authentic Z mod, it appears some of the bags use the 3d model when you wear them on the back. But you are unable to place them even though they look exactly like the bags you can place.

Any idea if I can remove the bags that do not have 3d models associated with them?

weary matrix
#

@hollow shadow so Tool is a DisplayCategory, not a category unfortunately

#
    {
        DisplayCategory = Security,
        Weight  =   0,
        Type    =   Key,
        DisplayName =   House Key,
        Icon    =   Key1,
        MetalValue = 5,
        WorldStaticModel = Key,
    }
hollow shadow
#

wait so i cant actually use this to get only tools in it?

weary matrix
#

@hollow shadow problem is most tool have a category "Normal"

hollow shadow
#

;-;

#

most items prolly

winter bolt
#

you can change the categories easily

weary matrix
#

like this for example:

    {
        DisplayCategory = Tool,
        Weight  =   0.2,
        Type    =   Normal,
        DisplayName =   Paint Brush,
        Icon    =   Paintbrush,
        StaticModel = PaintBrush,
        WorldStaticModel = PaintBrush_Ground,
    }
hollow shadow
winter bolt
#

the item tweaker mod lets you do it without overwriting them

hollow shadow
#

And i would have to create a new category and idk if that works

winter bolt
#

wait shit yeah idk if you can change the actual category itself

hollow shadow
winter bolt
#

i can just send you the code you'd need to put in

#

worth a try

hollow shadow
#

yeah theres no tool category

north condor
#

Is there a mod that adds more clothing items?

winter bolt
#

im working on one but its not released

north condor
#

Ohhh neat!

#

Do you know if they work with MP?

winter bolt
#

yeah everything that adds new items works fine

#

or clothes at least

north condor
#

So just another question about modding MP, as long as mod adds new items (Guns, cloth, cars etc) it's p safe to use? As long as they dont overwrite vanilla items

winter bolt
#

it depends on the gun mod but i think some of them work?

#

britas does

north condor
#

Oh no was just an example

#

Not a real fan of guns in this game lol

winter bolt
#

stuff that overwrites items is probably fine too

weary matrix
#

@hollow shadow @winter bolt there's also a keyword like AcceptItemFunction but not sure how to use it

weary matrix
#

a keyword that should be accepted in a script file

#

not sure what you're supposed to use as argument though

winter bolt
#

hmm

#

not sure but it might accept the like

#

tags for tools

hollow shadow
#

it would be cool if it was somehow possible to make it check for display category instead of type

winter bolt
#

i was thinking it might be for these but i doubt it

#

hmm

#

@hollow shadow what kind of tools were you wanting it to only accept?

hollow shadow
winter bolt
#

theres an attachment type just for hammers here

#

idk how attach types work

hollow shadow
#

i already made custom attachments for cordless drill and nailgun for the toolbelt back slot

#

but i want some items to go directly into the toolbelt becouse i wont spend 20 hours adjusting attachment points lmao

#

i would have to make like 30 attachment points

winter bolt
#

lmao

hollow shadow
#

i also did one for walkie talkie on the front of the belt

drifting ore
#

@hollow shadow testing in game it seems some guns do make sound just at a reduced range.
Shooting a 50BMG from Bitas mod still alerted zeds just at about the range of yelling.

hollow shadow
winter bolt
#

there might not be an easy way to do it

#

that looks cool lol

weary matrix
#

@hollow shadow mmm so you are adding the container yourself as a script item right?

hollow shadow
hollow shadow
winter bolt
#

well the category thing does work but probably not for display ones

drifting ore
#

I stand by my idea that guns just have heavily reduced sound range

winter bolt
#

they do

#

they halved the shotguns

weary matrix
#

@hollow shadow so it should be possible to add to your container the keyword AcceptItemFunction with a Lua function that will be called to do the checking on the item

weary matrix
#

cause in ItemContainer there's a method isItemAllowed() that use the value AcceptItemFunction to call a Lua function to decide whether the item has to be accepted or not

winter bolt
#

i might have an idea how to make that workbut i have no idea how to add a method to an item

weary matrix
#

it has to be a global Lua function I think

#

@hollow shadow give me a few minute to try something

winter bolt
#

i'm assuming AcceptItemFunction is the name of the method you can use that'll check the item and return true or false?

drifting ore
#

@hollow shadow so the Brita Mod is the one that is messing with the gun sounds?

winter bolt
drifting ore
#

yes

#

well with no mods on I have hear gun shots, then if I turn mods on, I hear everything but the gun shot.

I had a silencer mod installed by mistake at one point and figured that was what removed the sound entirely

winter bolt
#

oh thats what you meant

drifting ore
#

I figure delete everything out of the workshop folder and delete the .acf file or whatever it is under workshop then reinstall them all

weary matrix
#

@hollow shadow what's the name of your mod?

#

I need it to write the function

hollow shadow
weary matrix
#

to avoid conflicts with other mods

hollow shadow
#

i use TW

drifting ore
#

Also damn, i think i cant use ammo craft because all its shitty bullet piece boxes are drowning out the spawns for actual ammunition.
there are just TOO MANY boxes of "pistol primers", im drowning.

weary matrix
#

@hollow shadow so your mod ID is TheWorkshop no space?

hollow shadow
#

module TW

#

1 sec

drifting ore
hollow shadow
#

id=TheWorkshop

weary matrix
#

ok

drifting ore
# hollow shadow "The Workshop"

oh, that workshop.
Did you recently make scrap weapons dependant upon it? I dont think i needed The Workshop to run it before.

drifting ore
#

any particular reason?

hollow shadow
#

I made it so i can make Tools / recources that are needed for all 3 mods

#

otherwise i would have to add them multiple times across all 3 mods

weary matrix
#

@hollow shadow so try to add this in a Lua file in your mod media/lua/client/TheWorkshop/TheWorkshop.lua

TheWorkshop = {}
TheWorkshop.AcceptItemFunction = function(inventoryItem)
    return inventoryItem:getScriptItem():getDisplayCategory() == "Tool"
end

And then, add this in the script definition of your item container: AcceptItemFunction = TheWorkshop.AcceptItemFunction,

drifting ore
hollow shadow
hollow shadow
drifting ore
#

You have a discord? I feel like in that case everyone there just wants you to make as many cool mods as possible.

hollow shadow
drifting ore
#

I guess if i want scrap weapons i should check out The Workshop then. Im just a tad weary about over bloating my mod folder is all.

weary matrix
drifting ore
#

Ok back to modding.
Is there a quick garbage patch that could be made to make guns attract?
Like spawning a silent car horn whenever a gun is fired.

hollow shadow
#

Dont worry. I wont try to copy hydrocraft. especialy not on terms of quality xD

drifting ore
#

lol. Make muzzle flashes emit a sound of some kind that draws in zeds. xD

winter bolt
#

i was gonna get around to it but i might just whip one up quickly

hollow shadow
drifting ore
winter bolt
#

idk whats up with gun mods tbh

#

all they did was change the radius in the vanilla weapon scripts im pretty sure

drifting ore
#

Ya shooting again, guns for sure make some sound, just not much.

winter bolt
#

they lowered the actual numbers so i dont think they did anything fucky with radiuses themselves

#

melee weapons are fine

drifting ore
#

I got no idea how to mod this game but i guess i must try.
I shall replace muzzle flashes and make them emit sound, kek

winter bolt
#

which gun mods do you mean?

drifting ore
#

i have yet to find a single gun mod that attracts properly

winter bolt
#

hmm

#

ive seen people say that britas are pretty quiet normally but idk

drifting ore
#

like i said, the loudest ive tested just now was the 50-bmg and it was equivalent to yelling.

winter bolt
#

hmm

drifting ore
#

9mm SMGs are about the same as the sound of walking.

winter bolt
#

maybe try opening the mod files and seeing what the radius on it is set to?

hollow shadow
weary matrix
#

@hollow shadow can you upload your console.txt pease?

#

haha

#

mmm

winter bolt
#

"Object tried to call nil in AcceptItemFunction" uh oh

hollow shadow
#

it also didnt allow any items inside it

winter bolt
#

well thats a step in the right direction i guess lol

#

if the function call didnt work then it returned false i guess which means you're 1 step closer

weary matrix
#

@hollow shadow so it's a good news, it means the function was called at least, now we need to figure out how to make it not crash ๐Ÿ˜„

#

give me a few seconds

#

@hollow shadow so try this please:

TheWorkshop = {}
TheWorkshop.AcceptItemFunction = function(inventoryItem)

    if not inventoryItem.getScriptItem then
        print("DEBUG: TheWorkshop: getScriptItem is nil")
        return false
    end

    if not inventoryItem:getScriptItem().getDisplayCategory then
        print("DEBUG: TheWorkshop: getDisplayCategory is nil")
        return false
    end

    return inventoryItem:getScriptItem():getDisplayCategory() == "Tool"
end
drifting ore
#

Wow i am very surprised nobody has made a Browning 50-bmg machine gun yet.

winter bolt
#

lua god ๐Ÿ˜ณ

hollow shadow
#

@weary matrix No error but i also cant put anything inside

#

script is still the same right?

weary matrix
#

yeah same file

timid thorn
#

How difficult would persistent characters be to implement, kinda like going to sleep in rust when you log off a dedicated? that way if you leave a tV on or something and a zombie breaks in, you could be in trouble. PVP, preventing loot Despawning / hiding by logging off with the good stuff.

weary matrix
hollow shadow
winter bolt
#

im not like experienced though so i dont really know lol

drifting ore
#

@winter bolt no doesn't look like the values were lowered at all in Brita's or Arsenal. But we concluded that already.
They must have tried to modify the base game guns by putting a flat modifier over every firearm somehow?
I got no clue

winter bolt
weary matrix
#

@hollow shadow mmm mind to send me your mod?

#

so I can try it, will be easier for troubleshooting

hollow shadow
#

ok

drifting ore
hollow shadow
#

Is it possible to have multiple oncreate functions on a recipe?

silk thistle
#

so, is there like an absolute correct tutorial for enabling mods on servers after installing them via steam workshop? and i was told this can work mid save, as long as I back the save up

silk thistle
#

oop

hollow shadow
keen creek
#

what new map locations work together in mp?

hollow shadow
#

("Base.LeadPipe/Base.ScrapMetal") doesnt seem to work. how do i make it pick one of the 2?

keen creek
#

im not having mismatch issues

winter bolt
# hollow shadow
player:getInventory():AddItem(items[math.random(1, 2)])```
i cant really test it but something like this i think?
#

i dont really know much lua

hollow shadow
lofty yacht
#

Has anyone had any luck getting Autostar Trailers and/or Yacht Club working? Would love to be able to boat up to Louisville

hollow shadow
lofty yacht
#

I just realized it's not autostars and it's autotsar's lol

winter bolt
hollow shadow
scenic pawn
#

Does anyone know how to grab the data that players have on their maps? Like where the file that stores that data is?

hollow shadow
#

i dont have those on my keyboard i think

winter bolt
hollow shadow
#

ยฐยฐยฐ

#

ยงยงยง

winter bolt
hollow shadow
#

๐Ÿฅฒ

winter bolt
#

its this i think

hollow shadow
#

Oh yeah

#

its next to backspace for me

#
    player:getInventory():AddItem("MetalBar/Base.ScrapMetal")
    player:getInventory():AddItem("Base.Screws=2")
    player:getInventory():AddItem("Base.Screws/Base.EngineParts")
    player:getInventory():AddItem(items[math.random(1, 2)])
    player:getInventory():AddItem("Base.ScrapMetal")
end```
winter bolt
#

instead of doing the slashes to seperate them you do like

#

you make a list like this with the items you want randomised, with commas seperating each item

#

local items = ["Base.LeadPipe", "Base.ScrapMetal"];

#

then when you add the item you'll type the name of the list you want to pick an item from and then do the math.random thing and the second number will be the length of that list
player:getInventory():AddItem(items[math.random(1, 2)])

#

idk if that math.random thing works in pz since i just looked up a lua thing lol

#

so instead of player:getInventory():AddItem("Base.Screws/Base.EngineParts")

#

you'd do local randomItems1 = {"Base.Screws", "Base.EngineParts"}; player:getInventory():AddItem(randomItems1[math.random(1, 2)])

#

i think

#

you can add even more items to the random pool if you wanted too

#

lol i hope this works or i'll look really stupid

#

oops i used the wrong symbols

silk thistle
#

is there a list of mods that specifically work for b41 multiplayer that have added guns and such?

pure kraken
#

the lack of cargo pants in this game and modding community is disturbing

willow estuary
hollow shadow
#

1 and 2

winter bolt
#

ok so when you call math.random it asks you for 2 numbers which are just the range of numbers you want to randomise

#

so if you put in 1 and 2 it'll give you either 1 or 2

hollow shadow
#

ok thx

winter bolt
#

which the thing i posted then uses to grab an item from the list

#

oh also i updated the code because i messed up the symbols

hollow shadow
#

i mean

#

do i have to do a different name instead of "randomItems1" for each function?

#

or does it only work in that specific function

winter bolt
#

for "MetalBar" and "Base.ScrapMetal" you'll want to pretty much copy randomitems1 and call it something like randomItems2 and replace the item names in that list

#

you'll want to add a new list for each of the "choices" that you want the game to pick from when you do the recipe

hollow shadow
#
    local randomItems1 = {"Base.EngineParts"};
    player:getInventory():AddItem(randomItems1[math.random(0, 1)])
    local randomItems2 = {"Base.MetalBar"};
    player:getInventory():AddItem(randomItems2[math.random(0, 1)])```
#

now it gives me either engine parts or nothing

#

and a pipe or nothing

winter bolt
#

i think so but i'm not sure how the game handles it when you try to add nothing

#

try it and if it gives you an error then i can try to make a function you can use that you can just paste into your code and use

silk thistle
#

does anyone know any popular multiplayer mods then?

warped belfry
#

Hi guys, having issues with my PZ vehicle mod, trying to make my own, at first the car was invisible, but now i can see it's wheels, any idea what is causing this?
I had fixed the wheels by freezing transforms on Maya but didn't do anything for the actual car

#

this is the vehicle editor for it

drifting ore
#

So Authentic Z i believe has the old Tote Bag model attached to zombie spawns that are not placeable.

Is there a way to remove that old Tote bag model and replace it with the 3d one?

winter bolt
hollow shadow
# winter bolt alright if that gives you an error i've made a thing you can use that might work
function: DeconstructMotor_OnCreate -- file: TW_Oncreate.lua line # 22
Callframe at: PerformMakeItem
function: perform -- file: ISCraftAction.lua line # 58

LOG  : General     , 1639602528655> Object tried to call nil in DeconstructMotor_OnCreate
ERROR: General     , 1639602528655> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: Object tried to call nil in DeconstructMotor_OnCreate at KahluaUtil.fail line:82.
ERROR: General     , 1639602528655> DebugLogStream.printException> Stack trace:
java.lang.RuntimeException: Object tried to call nil in DeconstructMotor_OnCreate
    at se.krka.kahlua.vm.KahluaUtil.fail(KahluaUtil.java:82)function: DeconstructMotor_OnCreate -- file: TW_Oncreate.lua line # 22
Callframe at: PerformMakeItem
function: perform -- file: ISCraftAction.lua line # 58

LOG  : General     , 1639602528655> Object tried to call nil in DeconstructMotor_OnCreate
ERROR: General     , 1639602528655> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: Object tried to call nil in DeconstructMotor_OnCreate at KahluaUtil.fail line:82.
ERROR: General     , 1639602528655> DebugLogStream.printException> Stack trace:
java.lang.RuntimeException: Object tried to call nil in DeconstructMotor_OnCreate
    at se.krka.kahlua.vm.KahluaUtil.fail(KahluaUtil.java:82)```
#

It gave me nothing ;-;

winter bolt
#

ah yeah it's messing up because its trying to add a null item

#

try this out maybe?

#

i cant test it myself but it should work

#

are all of these recipe functions in the same script?

#

or are they all in like seperate .lua files

hollow shadow
#

uh

#
    local randomItems1 = {"Base.EngineParts"};
    player:getInventory():AddItem(randomItems1[math.random(0, 1)])
    local randomItems2 = {"Base.MetalBar"};
    player:getInventory():AddItem(randomItems2[math.random(0, 1)])
    player:getInventory():AddItem("Base.ScrapMetal=2")
    player:getInventory():AddItem("Base.Screws=2")
end
#

This is in a lua

winter bolt
#

hmm

#

are you able to put all of the recipe functions into the same file?

hollow shadow
#

recipe Disassemble Motor
    {

        Motor,
        keep MetalWorkbench,

        NoBrokenItems            : False,
        AllowDestroyedItem      : true,
        Result                   : MetalParts=5,
        Time                     : 200.0,
        Sound                     : BreakingWeapon,
        OnGiveXP                 : Give10MWXP,
        Category                 : Scrapping,
        OnCreate                : DeconstructMotor_OnCreate,
        AnimNode                 : Disassemble,
        SkillRequired            : Mechanics=2,
        Prop1                    : Screwdriver,
        Prop2                    : Source=1,
        CanBeDoneFromFloor      : TRUE,
        NeedToBeLearn: false,
    }  

#

this is part of the script

winter bolt
#

yeah do that then

hollow shadow
winter bolt
#

i'm just trying to make sure you wont have to copy paste the function into multiple files lol

#

ok try adding this to your code and using it instead

#
    local result = math.random(rangeMin, rangeMax)
    if result == 0 then return
    
    player:getInventory():AddItem(items[result])
    
end```
opal wind
#

hey guys im doing my first mod on PZ here, but i never published on steam before, how do i do it?

winter bolt
winter bolt
winter bolt
#

you'll place your mod's folder into the Contents/Mods folder in your new template and then when you open the game you should be able to see a workshop upload tab on the main menu

winter bolt
# hollow shadow

oh also i should explain that when you call my new function if you set the first number to 0 it'll mean theres a chance it'll give the player nothing but if you pass in another number then it'll always give the player something

#

so it works like how you were trying to use it before but hopefully without the error

opal wind
#

each mode is a code like 2644254485 then inside the mod folder is

winter bolt
#

when you upload to the workshop it'll generate one and add it to the file automatically

#

oh thats what you mean

#

yeah once you've uploaded it to the workshop it'll do that for you

opal wind
#

but how do i set comments, pictures and such on steam? this is so strange

winter bolt
#

do you have the mod itself like set up and working fine?

opal wind
#

i tought i had to upload first on steam so then it would appear ingame

opal wind
#

now i need to separate it to make my mod (sorry my english)

winter bolt
#

ah its okay

opal wind
#

ok so after i got all my files ready, i have to manually put on some folder, then i enter the game, then only after that it will be on steam?

#

im totally lost tbh lol

winter bolt
#

yeah if you go to Users/Zomboid/Workshop there's a mod template that you can copy and paste

#

that'll be the folder that contains the stuff you'll upload to the workshop

opal wind
#

i found that, so i put my mod there inside a folder like WizMod -> mod -> mod files ?

winter bolt
#

yeah

opal wind
#

then what?

winter bolt
#

then you should be able to open up that text file and then you can change what your mod will be called on the workshop and stuff like that

#

you'll also replace preview.png with the main image you want to appear on the workshop

#

once you've uploaded to the workshop you can add other images to the page and change the description

#

sorry if i'm not explaining well lol

#

this part of this video might be able to explain it better

opal wind
#

nah you are lol, sorry i do know how to do the mod, the only part i was not sure was how to upload on steam

#

thanks!

#

i will check the video i still dont understand how steam create the mod page thou

#

im editing my poster rn ๐Ÿ˜„

winter bolt
glass rampart
#

hey, for example if i have lots of similar stuff i want to spawn in one certain place, can i create an array or an object to loop over them all and place in that certain distribution place? well i mean i know you can do that but sadly not good with lua, any mod that use this method? or all just plainly write each and every item zilion of times?

winter bolt
opal wind
winter bolt
opal wind
#

thanks man

#

i will try to upload later after i get done with the mod and let you know if it works ๐Ÿ˜„

#

will be another trading mod but i will try to balance it

#

lol

glass rampart
winter bolt
#

i can write an example thing if you want

glass rampart
#

that would be cool, coz this does not work for some reason

winter bolt
#

what do you have rn?

glass rampart
#

local function insertTable(t1, t2)
    local n = #t1
    for i=1,#t2 do 
        t1[n+i] = t2[i]
    end
end

local bb_Botles_1 = {
    "Base.HookedWaterBottleEmptyYellow",10, -- 1
    "Base.HookedWaterBottleEmptyRed",10,
    "Base.HookedWaterBottleEmptyPurple",10,
    "Base.HookedWaterBottleEmptyOrange",10,
    "Base.HookedWaterBottleEmptyGreen",10,
 }
#
 -- new distribution (b41.51+)
insertTable(ProceduralDistributions["list"]["GigamartBottles"].items, bb_Botles_1) -- grocery shelves / gigamart shelves  / generalstore```
#

and this how i called it

#

well its just a part of the code

fresh flume
#

Is it possible to add a custom entry to your item definition, for use in scripts?

scenic pawn
#

Is there a mod that allows me to attach a first aid kit to my backpack?

winter bolt
#

i dont know much about lua but it should hopefully work

#

you should be able to pass in "bb_Botles_1" as the 2nd parameter and for the first parameter do "GigamartBottles"

glass rampart
#

ty, ill try that now

#

btw stupid question, can i update lua or game some how from debug, with out restarting it each time?

winter bolt
#

i think if you press f11 theres a button to reload lua but i'm not really sure how it works

glass rampart
#

i see, okay ill go try that fn

winter bolt
#

lol i might actually try using this function myself honestly

#

my item distribution file is a mess

zealous wing
#

I just think it'd be neat if we could have tool racks, or walls of guns. ๐Ÿ˜„

winter bolt
glass rampart
winter bolt
#

uh oh

hollow shadow
glass rampart
#

looking for em rn

winter bolt
hollow shadow
#

well either way it gives me nothing now xD

#

the function doesnt seem to work

winter bolt
#

also since lua counts from 1 in lists those two at the top mean that it'll only ever spawn engine parts or nothing, and never scrap metal

hollow shadow
#

AddRandomItemToInventory({"Base.Metalbar", "Base.ScrapMetal"}, 0, 2)

dusty sun
#

May I ask a question here about loading MP mods in my server? I think I'm doing everything correctly but it's still not working

hollow shadow
#

Here you used 2 items tho :I

winter bolt
dusty sun
#

Oh thank you

winter bolt
#

if you set the minimum number to 0 and the maximum to 1 then scrap metal will get cut out

winter bolt
#

yeah lua is weird lol

hollow shadow
#

so the 0 is for the enghine parts and 1 is for the scrapmetal

#

but how do i make it random?

winter bolt
#

nah 1 is engine parts and 2 is scrap metal

#

ok so

hollow shadow
#

if i do 1, 1 then it gives me 1 of both?

winter bolt
#

math.random takes in a minimum number and a maximum number, which are the ones you put into my function. it'll pick a random number between those two numbers you put in

#

so if you put in a 1 and 2 it'll choose engine parts or scrap metal

hollow shadow
#

Oh.l.

#

i didnt change your function lmao

winter bolt
#

oh wait hold on i need to look up something lmao

#

yeah ok i didnt screw it up

winter bolt
#

the two numbers are the end are the minimum and the maximum that the random number generator will choose

#

but i've added a check that makes it so that if the random number ends up being 0 then it wont give the player an item

#

so if you want the player to recieve a random item then you'll want the first number to be 1

#

but if you want them to possibly recieve no item then the first number should be 0

glass rampart
#

can't find those errors, will try to restart it once again,

but i have a question about your fn

    for index, value in ipairs(items) do
         table.insert(ProceduralDistributions.list[container].items, value);
    end
end```
#

argument items and ipairs items is different from [].items right?

#

and the 2cnd argument is value?

winter bolt
#

yeah the argument "items" is just the list of items you put in

#

[].items is the actual list of items in the distribution file

glass rampart
#

insertTable(["GigamartBottles"], bb_Botles_1)

#

and i should call it like this right?

winter bolt
#

nah you'll wanna get rid of the [] around "GigamartBottles"

glass rampart
#

oh dammit

#

ill try that one again

glass rampart
winter bolt
#

my first successful lua code lmfao

glass rampart
#

xD

#

well it would be nice to also add if/else statement and throw an error it there is no such distribution

#

to prevent code from dying if there is mistake

#

but i am already glad it is working! ๐Ÿ™‚

winter bolt
#

i keep getting an error when i test it but i dont know why

glass rampart
#

yeah that will help to find such distribution errors

#

and btw, if there will be if/else statement you can publicly add this fn to some distro optimisation

#

coz i see lots of mods just manually type each and every line

#

for example mods of theMadmanAndre and most of other ppl

#

with this it will be easier to find bugs and update distri

winter bolt
#

yeah

fierce leaf
#

@weary matrix im having issues with your out the window mod

weary matrix
glass rampart
#

how do you think, will this work?

    for index, value in ipairs(items) do

        if not container then
            return print('ERROR: procedure distributions not found!')
          end
          if not container then
            return print('ERROR: cant add '..value..' to procedure '..container)
        end
         table.insert(ProceduralDistributions.list[container].items, value);
    end
end```
#

i mean if statement

winter bolt
#

no that will check if the container name you just entered is nil i think

#

i just made something but i need to test it

#

oh sweet i dont get an error now

#

i dont know what i did but

glass rampart
#

heh

winter bolt
#

nevermind :(

glass rampart
#

error?

winter bolt
#

i wrote an if statement wrong lmao

#

lua is weird

glass rampart
#

yeah i know

#

but then what if i add variable local data = ProceduralDistributions.list and then check if not data[container] then?

hollow shadow
#
 function AddRandomItemToInventory(items, rangeMin, rangeMax)
    local result = math.random(rangeMin, rangeMax)
    if result == 0 then return
    
    player:getInventory():AddItem(items[result])
    
end

function DeconstructMotor_OnCreate(items, result, player)
    AddRandomItemToInventory({"Base.EngineParts", "Base.ScrapMetal"}, 0, 1)
    AddRandomItemToInventory({"Base.Metalbar", "Base.ScrapMetal"}, 0, 1)
    player:getInventory():AddItem("Base.ScrapMetal=2")
    player:getInventory():AddItem("Base.Screws=2")
end
winter bolt
#

OH

#

I KNOW WHY LMAO

hollow shadow
winter bolt
#

i forgot to close a fucking if statement lmao

winter bolt
hollow shadow
#

function AddRandomItemToInventory(items, rangeMin, rangeMax)
    local result = math.random(rangeMin, rangeMax)
    if result == 0 then return
    
    player:getInventory():AddItem(items[result])
    end
end
#

like dat?

winter bolt
#

nah right after "return"

#
    local result = math.random(rangeMin, rangeMax)
    if result == 0 then return end
    
    player:getInventory():AddItem(items[result])
    
end```
glass rampart
winter bolt
#

yeah

#

i keep getting an error

glass rampart
#

and what about this one?```function insertTable(container, items)
local data = ProceduralDistributions.list

for index, value in ipairs(items) do

    if not data then
        return print('ERROR: procedure distributions not found!')
      end
      if not data[container] then
        return print('ERROR: cant add '..value..' to procedure '..container)
    end
     table.insert(ProceduralDistributions.list[container].items, value);
end

end```

#

i added variable, now i should check if it is in dist list no?

#

edited it a bit.. will go to try

hollow shadow
winter bolt
#

tf

hollow shadow
#

 function DeconstructMotor_OnCreate(items, result, player)
    AddRandomItemToInventory({"Base.EngineParts", "Base.ScrapMetal"}, 0, 1)
    AddRandomItemToInventory({"Base.Metalbar", "Base.ScrapMetal"}, 0, 1)
    player:getInventory():AddItem("Base.ScrapMetal=2")
    player:getInventory():AddItem("Base.Screws=2")
end```
winter bolt
#

wait so whats wrong with it now?

hollow shadow
winter bolt
#

i think your last 2 lines might be breaking it?

hollow shadow
#

no such function " DeconstructMotor_OnCreate"

winter bolt
#

oh tf

#

like i think the =2 "Base.Screws=2" is breaking it maybe?

hollow shadow
#

ill remove them

hollow shadow
winter bolt
#

i'm beginning to think my code isn't reliable

opal wind
#

hey so i have to put my mod inside a folder call 'mod' then put this folder inside another folder with my mod name right?

#

but on this workshop page the modTemplate is inside another mod folder inside another ModTemplate folder :/

#

it should be Workshop -> ModName -> mod -> mod files ?

#

or like Workshop -> ModTemplate -> Content -> mod -> ModTemplate -> then my mod? this is super confusing why steam sucks so much ๐Ÿ˜ฆ

winter bolt
#

@glass rampart yeah i'm not smart enough to make this work lmfao

glass rampart
#

well it seams my piece of "artwork" is not working as well xD

wet osprey
#

hey sorry to bother, where is the list of all the item names?

glass rampart
#

@weary matrix sorry to ping you, and if you are not busy, would you mind helping us a bit with lua code... ?

weary matrix
#

@glass rampart sure

glass rampart
#

so we have a fn here and we want to add if/else statement but its a bit hard do so for ๐Ÿ˜ฆ

#
    for index, value in ipairs(items) do
         table.insert(ProceduralDistributions.list[container].items, value);
    end
end```
#

the point of fn is to receive obj with elements and well add them to distr

winter bolt
#

mine is erroring without the if statement lmao

glass rampart
#

i tried this sh*t but it does not work ```function insertTable(container, items)
local data = ProceduralDistributions.list

for index, value in ipairs(items) do

    if not data then
        return print('ERROR: procedure distributions not found!')
      end
      if not data[container] then
        return print('ERROR: cant add '..value..' to procedure '..container)
    end
     table.insert(ProceduralDistributions.list[container].items, value);
end

end```

#

it would be nice to receive an error when there is no such distr path or no item like that and proceed to add another items with out breaking

#

and @winter bolt was the one who wrote loop

weary matrix
#

@glass rampart mmm does the code work but show no errors in console.txt?

glass rampart
#

the one with if else?

#

oh in lua its just if...

weary matrix
#

I don;t see any else in there ๐Ÿ˜…

glass rampart
#

yes i just used to JS xD

#

well the one with "if" yes does not show any errors

#

i added incorrect path

#

but still it is no errors

weary matrix
#

@glass rampart I don't know much about distribution, is it a function that is called from a script .txt file?

glass rampart
#

lua

winter bolt
#

its a lua table

#

this is almost definitely not worth the time i'm spending trying to fix it lmao

glass rampart
#

function insertTable(container, items)
    local data = ProceduralDistributions.list

    for index, value in ipairs(items) do

        if not data then
            return print('ERROR: procedure distributions not found!')
          end
          if not data[container] then
            return print('ERROR: cant add '..value..' to procedure '..container)
        end
         table.insert(ProceduralDistributions.list[container].items, value);
    end
end

local bb_Botles_1 = {
    "Base.HookedWaterBottleEmptyYellow",100, -- 1
    "Base.HookedWaterBottleEmptyRed",100,
    "Base.HookedWaterBottleEmptyPurple",100,
    "Base.HookedWaterBottleEmptyOrange",100,
    "Base.HookedWaterBottleEmptyGreen",100,
 }

 -- new distribution (b41.51+)
insertTable("GigamartBottles", bb_Botles_1) -- grocery shelves / gigamart shelves  / generalstore
insertTable("GigamartPots", bb_Botles_01);   -- housewarestore
insertTable("GigamartPo", bb_Botles_01);   -- housewarestore
#

well it is some thing like this

#

last line should be incorrect

#

but items still spawning and no errors

weary matrix
#

the code you show looks fine and should print something to the console, but in some case, the prints won't happen. For example when you create a script item, if you add something like AcceptItemFunction = someLuaFunction then the prints won't go to console

glass rampart
#

and yes there is more arrays i just delete them to show general idea

weary matrix
#

@glass rampart the prints are just for you in case you forgot something right?

glass rampart
#

yeah

#

just to be easier to fix stuff

#

and find errors in case

#

i wanted them in log

weary matrix
#

@glass rampart so in that case try to replace print with error

winter bolt
#

for some reason when i use that exact same function it gives me a nil error

glass rampart
#

with error?

winter bolt
weary matrix
#

ah damn

winter bolt
#

it doesnt give me any idea what its calling thats nil

weary matrix
#

mmm maybe you could move the first check out of the function?

winter bolt
#

i dont have a check in mine

#

this is all i have and its giving me a nil error lol

#

the container name isnt wrong either

weary matrix
#

@glass rampart @winter bolt I mean for: ProceduralDistributions.list, you can check it from outside the function right?

winter bolt
#

yeah

#

adding stuff without the function works fine though

#

i'm just gonna shelve the function on my end i guess

#

it works for kayn but not for me for some reason lol

brittle jewel
#

Is it the comma after the 5? Shouldn't that either not be there, or have something after it?

weary matrix
#

@glass rampart @winter bolt if the prints are not showed to console and error() is not defined, it probably means your code is run from a special context, not sure how to address this ๐Ÿ˜ฆ

winter bolt
glass rampart
#

hmm

weary matrix
#

@glass rampart and also you don't need to check it for each iteration of the loop, just once before entering the loop would be ok

#

but that's another issue ๐Ÿ˜…

glass rampart
#

hah

#

well i dont import require 'Items/SuburbsDistributions' require 'Items/ProceduralDistributions' im my lua

winter bolt
#

oh yeah sidenote does PZ let you use lua's math.random?

glass rampart
#

not sure if i need it?

winter bolt
#

or does it have its own random function

drifting ore
#

Anyone know how to remove the tote bag that does not have the 3d Model associated with it so it can NOT be placed on the ground? I am pretty sure I know which mod is doing it

weary matrix
#

@winter bolt don't know but you have ZombRand

jovial summit
#

Hey anyone got a clue as to where the generator logic is located?

weary matrix
jovial summit
#

Much appreciated!

warped belfry
#

Anyone know why my vehicle mod is skipping gears?

#

went from 1st to 5th, are the ratios off?

jovial summit
#

Anyway to make this file more comprehensible? I'm using Notepad++

late hound
jovial summit
#

What's an IDE?

late hound
jovial summit
#

Fair enough

pearl prism
weary matrix
#

this will allow you to decompile the game

#

should be way easier

#

@late hound have you tried it btw? I also rename symbols like var1 var2 etc with names based on the types

haughty yoke
#

can someone please make a mod to replace the 2d log icon in the fireplace with the 3d version

#

even just a flat version of the 3d model would be better

worthy snow
#

any mod that makes guns less ear-rupturingly loud?

stray yacht
#

Anyone able to tell me what Log "EXITDEBUG: IngameState.exit 11" means when trying to start a local server with my mod? Better yet, know where I can find definitions for the exit codes?

opal wind
#

ok so i manage to upload my mod on workshop and test it in-game, now each time i Update my mod on the workshop, people that already subscribed to my mod will have to sub again or each time i update my mod it update to everybody that is subed?

opal wind
#

congratz man

#

im trying to finish my first mod too haha

warped belfry
#

i hope it's going well!

opal wind
#

i need to know that question i just posted

#

like when i update my mod on workshop, people who already subed it need to re-sub?

warped belfry
#

no resubbing

opal wind
#

thats convinient

warped belfry
#

best to test first before uploading to workshop tho, its easier

opal wind
#

oh man, modding this game is easier than minecraft and the sims 4 for sure, im loving it

warped belfry
#

it is!

opal wind
#

lua was made by a brazilian like me

#

๐Ÿ˜„

#

looks like im going to have to make a 3rd discord server soon lmao

weary matrix
#

Let's say I want to add an item like Grass Cuttings how would I change the "Cut Grass" action to give the character grass cuttings?

opal wind
warped belfry
#

works both ways i guess

opal wind
#

you mean like putting on the mod folder directlly? doesnt steam need to generate that number code folder first?

#

i did test like that before but inside another pre-existent mod folder lol

warped belfry
opal wind
#

ah i see

warped belfry
#

then enable it

#

debug mode too

#

great stuff

#

vehicle editor is cool

opal wind
#

i guess, but testing after updating the workshop i can just hit 'continue' on my testing world

#

any way is fine

#

did you make your car on blender?

#

oh vehicle editor? its a model tool or code tool?

#

my mod is not a car mod thou, this first mod im doing will be a trade mod, to trade before uselss stuff like jewels for money then buy some stuff

#

i will also add support child-mods for lots of other mods

#

got suport for USCM armory and antique armory mods already

#

they will be expensive thou lol i dont want to make it much OP

warped belfry
warped belfry
jovial summit
#

You know what maybe modding isn't for me

opal wind
#

harra you know how to open those .X files from armor/cloth models?

#

cars are .fbx i can import to blender but not sure about .x lol

weary matrix
#

@opal wind you have to convert them

#

there are online converters, but not 100% reliable

opal wind
#

did you try? it convert to .fbx or what? thanks!

drifting ore
#

Can anyone help identify which mod this duffel bag in the 2d is? For the life of me I cant figure it out

weary matrix
#

Any clue how to remove snow from a square?

willow estuary
#

I think soul filcher, and maybe other people, hit dead ends with that?

weary matrix
#

@opal wind I managed to convert some item from X to FBX, maybe a screwdriver or something I'm not sure

#

@willow estuary you mean about removing snow?

willow estuary
#

Yeah, but who knows? Anything might be possible.

weary matrix
#

has to be, but I was surprised to see there's no snow tiles, even when looking with chunk debugger

#

@willow estuary in IsoCell I can see private class SnowGrid

#

doesn't look good indeed

#

and all IsoCell attributes related to snow are private too ๐Ÿ˜ฆ

#

I guess only a JavaMod could do it ๐Ÿ˜…

agile coral
#

@weary matrix If it's an overlay like trash, you can do this

#
object:getSquare():transmitRemoveItemFromSquare(object);
object:getSquare():getObjects():remove(object);
weary matrix
#

@agile coral are you sure it's an object?

#

i can't see it with chunk debugger

agile coral
#

It's how they handle ashes and trash overlays, but I'm not positive. I've never made it to winter lol

#

But since most world items are considered objects, it's probably safe to assume the snow buildup would be one too

weary matrix
#

@agile coral any clue how can I inspect hashes for example?

#

and can I remove objects / tiles with debug mode?

abstract raptor
#

so, I used to be able to get whole ass songs to play with the recipe sound thing

#

now it doesn't work at all

#

any ideas? :S

weary matrix
#

@agile coral first is hashes, second is snow

agile coral
weary matrix
#

@agile coral yes probably, my problem is I want to remove snow, not ashes ๐Ÿ˜…

dark solar
agile coral
#

Hmm, can you check if rain puddles also set the diamondFloor flag?

#

That may be an easy way to check if it's snow, since nothing seems to explicitly mark it as such

weary matrix
#

@dark solar why?

dark solar
weary matrix
#

ah ok, no worries ๐Ÿ˜‚

#

@agile coral let me check

fallen oxide
#

yo you guys are veterans could u possibly help me with something real quick?

#

its about saving my world correctly not losing any player built items and loot in need of workshop updates / fixes by removing map bin files and restarting my server to implement mod removing correctly

weary matrix
fallen oxide
#

ive done so but people arent responding to my query sorry dude

#

guess its maybe because of the time right now

weary matrix
#

@agile coral mm I have flag diamondFloor set even for wooden floor inside a house

#

@fallen oxide well here is about modding the game, your question has nothing to do with that ๐Ÿคทโ€โ™‚๏ธ

#

modding as in creating mods

weary matrix
agile coral
#

@weary matrix Hmm, yeah I'm not finding a way to tell a snow-covered tile from any other tile. Might have to look through the java files

undone crag
#

Hey how should Lua things be coded for multiplayer? I don't get it.

agile coral
#

I believe so? It was with the ISClearAshes timed action

#

There are certain commands that send updates to the server, like object:transmitModData()

weary matrix
undone crag
#

Aye aye sir

#

I want to avoid spamming the bandwidth with commands that are networked also.

#

Maybe I will wait for multiplayer documentation of how it works.

weary matrix
#

or check other mods

undone crag
#

:\

ruby urchin
#

not sure if a docs for multiplayer will be created, you just need know about client-server concepts

undone crag
#

I want to also know when data is sent to the server and when to the client though. Like instead of frequently updating moddata on a client, if each time that happens it's networked, I should update a lua table which is more infrequently used to change moddata to send it to the other players.

#

And which functions only happen on the client and need things to be done to make it happen on other clients.

weary matrix
#

@undone crag well in my Spear Traps mod I use getModData to store info in the trap about spikes etc, I don't have to do anything special for others to see the spikes

#

or maybe I'm wrong, not sure I actually checked from another player perspective, but no one complained about it so far so not sure

undone crag
#

I don't want to experiment or read the Java to find out how it works though :d

weary matrix
#

@undone crag well I wouldn't get into modding pz then ๐Ÿ˜‚

undone crag
#

:|

agile coral
#

Yeah, that's the state of PZ modding right now

undone crag
#

I only have so much time to do things until I have to devote time to surviving the heat death of the universe.

agile coral
#

I usually just search the files in the PZ /media/ folder for whatever thing I want to do to see how the dev team did it

undone crag
#

Oh yeah that's a thought. The Lua may have been updated, and the base game Lua will be working with multiplayer. So I can see that.

ruby urchin
#

In another game that working with lua, they use TriggerServerEvent and TriggerClientEvent for client/server, I don't even have a server but you could try pass variables back and forth with
//Client

triggerEvent("OnSomething", "Something")

//Server

Events.OnSomething.Add(function(text) 
  print(text)
end)

no idea if it works

agile coral
#

@undone crag You could also check out Events.OnClientCommand and Events.OnServerCommand to log which events are fired while playing

undone crag
#

:o

brittle nacelle
#

hi y'all, which mod is the door reinforcement mod?

weary matrix
#

@agile coral oh I made a mod to do this, but I still have to implements all the settings before publishing

#

it's usable though

#

by default I'm not showing the events that trigger too frequently but they can be enabled if needed

random ruin
#

hello, are mods available for 41.61?

dark solar
#

yea

dusk pawn
#

I dont know if this goes here but theres a mod that isnt updated to the latest branch i was wondering what would it take for someone to maybe look at it and update the mod itself ?

mint sphinx
weary matrix
#

@mint sphinx no, what for? ๐Ÿ˜‚

#

at the moment my days are like 36h then 12h sleep ๐Ÿ˜‚

hollow shadow
#

lua gods dont need sleep i guess

weary matrix
#

loool

#

@hollow shadow I'm a Lua god now? ๐Ÿคฃ

hollow shadow
#

yes

#

u helpeded me alot :3

weary matrix
#

๐Ÿ˜„

drifting ore
#

can anyone help me check if any mods of mine are interfering with oven? base burned down 2X now because of invisible food that's in oven

weary matrix
mint sphinx
weary matrix
#

๐Ÿคฃ

quiet kiln
#

The mods not yet updated to the MP build are only incompatible with the MP mode or with the build as a whole? Because I don't plan on playing MP, only SP.

warped belfry
#

I played SP on the MP build fine with vehicle mods and a weapon mod, worked fine

hexed arrow
#

very dumb question but in which language is the code written ?

#

btw which language is useful for modding? im starting to learn coding in my free time^^

nimble spoke
nimble spoke
torpid briar
#

Did britas weapon mack get an update yet

reef lichen
#

@late hound Hey, I saw few hours earlier that you updated the mod. I got a friend whoโ€™s hosting a dedicated server with it having issues trying to force the server to update itself. Heโ€™s tried the copy and paste method and it doesnโ€™t seem to change anything.

late hound
#

@reef lichen This is the wrong channel for this, head to #mod_support

reef lichen
#

Ah right my bad

undone crag
austere vortex
#

uhuh

warped belfry
#

Anyone know what shader allows blood on a vehicle, my blood doesn't appear, only rust and damage

teal forum
#

Someone could tell me how to manually put a mod into "another" version ? I have an issue on my server, telling me server and mod version are different... although it was updated the 14th of december ๐Ÿ˜‚

brittle jewel
teal forum
#

Thanks !

#

Sorry for posting in the wrong place, my bad

paper tartan
#

any1 knows which file controls TV channels and gaining skills/boredom reduction etc? is RADIO_SAVE file important?

#

or what do these values mean re radio?

#

DaysSinceStart = 7
LvObfuscation = false
93200,1,1,none,-1
98000,1,1,none,-1
101200,1,1,none,-1
89400,1,1,none,-1
200,1,1,none,-1
201,1,1,none,-1
203,1,1,none,-1
204,1,1,none,-1
205,1,1,none,-1
91200,1,1,none,-1
107600,1,1,none,-1
95000,1,1,none,-1
88800,1,1,GEN-816867,-1

sour island
#

Is that SoulFilchers's new mod? ๐Ÿค”

#

Anyone familiar with sounds in game, specifically emitters, know why the host would be able to hear looped sounds but the clients can not?

#

My dirty solution would just be to task a handler to repeat it

#

But I can imagine that'd cause issues

drifting ore
#

like in vanilla ?

#

i couldnt get the eris minimap to work. came here to see if theres something minimap that actually works. just for vanilla

willow estuary
drifting ore
#

how do i activate it

late hound
#

HIT M

drifting ore
#

nothing happens

shadow dust
#

Are you on the mp beta

fair frost
#

You joke about Federal Agents outside your house, mine are actually outside and preparing to perform no-knock warrant. We are not the same

fair frost
#

(he's been stockpiling weapons with out permit)

#

Anyway
Agency to yet receive coverage
ATF
FBI
US Customs
DEA
USMS

worldly coral
#

Does the B41 mods work for B41 Multiplayer?

vivid zenith
#

does anyone know a mod that lets you tie shirts/jackets around your waist?

balmy prism
# fair frost

Oh god oh fuck. Look ATF I no longer have any of those forced reset triggers. Thatโ€™s silly. I lost them in a crazy boating accident.

#

What? No those online posts I made about how your agency should be dismantled was simply a joke.

fair frost
#

Fair argument
however it so happens that we are already flooding funny tear gas that may or may not be flameable

balmy prism
#

Are those plates level four?

#

You better hope they are

fair frost
#

Perhaps...

quiet kite
#

hide your dogs

fair frost
#

Anyway
I like my suspects medium rare

#

yeets in flare

#

The Tear gas catches on fire, its February 93 all over again

balmy prism
#

You fool. Iโ€™ve laced my yard with these little doohickeys called โ€œtoe poppersโ€. Yes, they are indeed 7.62x51 rounds that may or may not go off if you step on them.

glass rampart
#

hm... was it always wearing bulletproof vest will make all funnypacks (including vanilla) to become invisible?

winter bolt
#

yeah it probably hides everything that goes in that slot to avoid clipping

glass rampart
#

well just did some testing, and no it does not, there is problems with certain few things at that, oh well and vanilla funnypacks as well

#

but it sort of strange, i think it was not like this before

fast yacht
#

hey gamers, does anyone knows anything about map in eerie country mod? i wish i had a map or be able to use those i can find on gas stations, but i cant use them, is this not yet a feature or im doing something wrong?

ebon peak
#

why are mods not working with multiplayer? when i try to host with mods it says "servers workshop item is different version" or something

sick yew
#

Right, your thoughts on another town across the river from Riverside?

#

Both towns would be connected by a bridge

brittle jewel
drifting ore
#

man, I'm really, really hoping mod authors don't start leaving in droves because of dumb folks not understanding how to update their server mods...

#

people are crapping on Hyzo again for his Firearms B41 update today. "ur update broke MP" no, no it did not

#

so frustrating.

deft marsh
#

Would it be wrong to ask for modders willing to help with our server?

sweet tide
#

anyone know if britas and the additional mods for it work with mp?

tulip bluff
#

After taking a quick look into the files it seems the quality of crafted spears maxes out at only level 3 carpentry? Can anyone tell me if that is correct?

willow estuary
willow estuary
drifting ore
#

In a way I'm hoping that more creators just start disabling comments on their workshop pages

deft marsh
#

would definitely pay. We host one of the most popular servers (dont want to advertise it here) and are looking for someone to help with creating a community center complete with a library, kitchen, lounge, pond and garden. Have many ideas for additional mods and want to minimize our mods by creating a server pack. (with consent of authors ofcourse.) Pm me if interested

drifting ore
#

Comments are very useful for players to find recent info about updates and such, but lately they're just turning into a "pitch" fest from folks who don't entirely know what they're doing (no offense to them of course, but it's very disheartening to see mod authors say things like "maybe it's best if I don't update for a while")

drifting ore
#

I like Brita's too, it's very well executed, but it's a bit too "much" for me if that makes sense

stiff scaffold
#

tbf its also very frustrating when you get things to work and the next day something updates and it all falls apart

willow estuary
stiff scaffold
#

i wish there was a way to stop steam from auto updating mods

fair frost
#

Does anyone know how the lights effect on cop car lightbar is created
How does the game know which part of the brush is suppose to light up
Is it hardcoded ?
I'm asking because i wonder is it possible script specific part of the brush/texture to light up when turning on els, allowing to create slicktop/unmarked cars

drifting ore
willow estuary
drifting ore
#

blame should be placed appropriately, and in a lot of cases it's being turned toward the content creator erroneously

nimble spoke
stiff scaffold
#

iirc the only way to stop steam from updating mods is making a non steam server, no?

sweet tide
drifting ore
stiff scaffold
#

im using it on our server rn

brittle jewel
#

@stiff scaffold It's easy enough to just copy files to the dedicated server and then unsubscribe from the mod

sweet tide
stiff scaffold
#

i guess? i never bothered trying

nimble spoke
stiff scaffold
#

i just left it at "extremely rare"

sweet tide
#

what about bullets do they kill other players?

willow estuary
stiff scaffold
sweet tide
#

i mean for britas

stiff scaffold
#

only conflict there is with brita's weapon pack/arsenal's gunfighter mod is the melee option

#

it uses the same key as the map key

#

which you can just

#

rebind lol

sweet tide
#

oh yeah

#

did u do that in settings or the mod config?

stiff scaffold
#

i rebinded the map key to something else

#

besides that

#

it works v well

sweet tide
#

are the loot spawns broken?

stiff scaffold
#

no

sweet tide
#

ive never tried britas

#

oh nice

stiff scaffold
#

they spawn accordingly

sweet tide
#

finding the ammo be like

stiff scaffold
#

anyhow

sweet tide
#

britas mod defo looks awesome

stiff scaffold
#

is theres a mod that enables emergency vehicles lightbar effects?

stiff scaffold
#

thanks

sweet tide
#

i dont see why that wouldnt work with mp

#

its the same vehicles

stiff scaffold
#

you never know

#

people assumed the same when it came to brita's weapons and armor mods

sweet tide
#

its dif for weapons

tulip bluff
stiff scaffold
sweet tide
#

yeah exactly

stiff scaffold
#

nothing weapon related was mentioned in the patch notes

#

like any changes in core mechanics

sweet tide
#

well you can shoot players with weapons

#

they might break or cause conflicts

#

like the map conflict

stiff scaffold
#

that'd cause conflict if you tried to shoot other players

#

brita's weapons didnt even work to begin with

#

gave errors whenever one tried to shoot

#

regardless of the target

#

it was weird but its fixed

sweet tide
#

mussy btw

stiff scaffold
#

so thats great

sweet tide
#

i would read the comments first one that mod

#

may be overall broken before mp

stiff scaffold
#

lol

left plank
#

wow, modding is.... quiet???

sweet tide
#

best part of the game too

#

imagine if we didnt have mods

willow estuary
# left plank wow, modding is.... quiet???

Things are slowly getting back to a nice, stable situation, as is normal when there's big changes that cause upheaval and confusion. Dawg bless all the people who have been helping with teh return to normalcy!

sweet tide
tired finch
#

oh alr

sweet tide
#

anyone know any good clothing mods that add more overall clothing items?

#

that are lootable

left plank
#

this is typically a channel for modders btw

#

they discuss mods they're working on, and share progress and troubleshoot how to make mods. It's not really much of a #pz_b42_chat environment

sweet tide
#

was gonna say some people were complaining about mod discussion in #pz_b42_chat

#

not now but earlier

willow estuary
willow estuary
sweet tide
#

i dont understand why some people hate mods

#

they add really good features, and some fix the vanilla game

#

would be cool to have a mod questions channel

left plank
#

it would honestly make it more difficult to troubleshoot imo

sweet tide
#

well you keep questions for the mod in questions, like what it includes and does it work and anything more technical in support

#

just an idea though

willow estuary
timid thorn
#

Does anyone know how the base voip works, the settings let you pick a minimum and maximum voip range but how does that translate in game. How is the minimum 10 blocks and the maximum 300 blocks with one voice setting? ๐Ÿค”

timber furnace
#

using britas weapon pack in multiplayer, how do you access mod options? i see it in build 41, but not the multiplayer beta

dark solar
timber furnace
#

ok thnks

winter bolt
#

self plug

sweet tide
#

name?

winter bolt
#

i mean its not out so

flat edge
#

Does the survivor mod still work that adds npcs

pine latch
#

is there any mod that lets you make car parts stronger? Like reinforce them

worldly olive
#

Hi!
Does somebody knows which event could I use to run the code to change the profession cost after somebody dies in the MP and wants to create a new character?
The thing is that I change the cost of the professions using the OnGameBoot but if somebody dies and tries to create a new character the cost is vanilla again.

loud nymph
#

How do you know if you have mods installed correctly on your multiplayer server? I added the mods in using the mod option in the settings when creating the server.

quasi geode
worldly olive
#

@tame mulch @willow estuary will check that!! thank you!
@quasi geode sorry, didn't understand the latest part, you mean to remove the original functions? the thing is that I would like to not overwrite the vanilla functions because that would lead to overwriting whatever other modders added to an specific profession.
Let's say, Aiteron with Better Lockpicking adds a trait to Burglar, I just change the cost to Burglar but I do not overwrite it to keep compatible

tame mulch
quasi geode
#

sorry, my short explaination was for 'the bottom of that file' Blair directed too

worldly olive
#

Oooooh

quasi geode
#

better lockpicking uses the profession framework doesnt it?

worldly olive
#

Haven't checked the url yet, was first reading the comment haha

quasi geode
#

might just be easier to use the PF, since it handles the respawn stuff and compatibility between mods

tame mulch
worldly olive
#

Thanks! will read the github Blair sent and study it a little bit!
If I don't get it I will ping you!! thank you a lot

dark solar
drifting ore
#

my bad

dark solar
#

no problem

sleek socket
#

heyah, anyone know how to add louisville to a MP server as a spawn option?

willow estuary
#

People have been being so dang polite about this new mod_support channel business and guiding people to the correct channels, it's really nice. ๐Ÿ™‚

#

Pat_Bren would be proud of all of you!

grizzled tinsel
#

Question:
I'm looking for a way to visually look at the current "Room Definitions" for the latest build of project zomboid. Does anyone know a good way to get a visual view of these? Can I use WorldEd?

karmic tree
#

Does PamboS's Zombie Loot work on MP? We tried and it seems not to tick any of the percentages...

sharp crystal
#

Hello. Is it possible to combine all eris minimap plugins into one mod? Would it work pls?

willow estuary
willow estuary
grizzled grove
hollow shadow
#

How does the new distribution work

grizzled grove
granite shell
#

can anyone help, the Tsar's Common Library mod doesn't work