#mod_development

1 messages ยท Page 199 of 1

urban wind
#

?

#

because it reduces the chance by 60%?

#

wait no it wouldn't, because you're decreasing the chance it hits rather than hits

#

ok yup that makes sense

#

anyone know where they're pulling the RNG generator?

#

is it inbuilt to lua or java or are they using another source?

sour island
#

it's just math next and math random

urban wind
#

ok I'll dig into a little later...Thanks again @sour island @bronze yoke ๐Ÿ˜€

jovial mortar
#

Can someone make a wheelchair mod which bounds you to a wheelchair and you cant drive or go up stairs or climb over fences. Just feels like a cool challange. Idk if it's even possible to make but would like to see it lol

mellow frigate
fringe heart
#

who knows where the code of the map with notes is located? I want to create a mod that spawns a container in a random place and marks it on the map

random finch
#

I can set sandbox options for loot tables that just work aside from zeds. This is an example mod to track what that issue is. It has sandbox options for what items should be added to the general zed inventorymale and inventoryfemale tables.

These 2 items in the pic are set in my sandbox options and appear in LootZed but neither of them will spawn.

Here is a snippet: https://hst.sh/nuvaninebi.lua

Also, if it matters, I am testing on a server.

shrewd sable
#

i'm trying to add a second language to the mod i'm making (learning how to...) and i don't know why it doesn't work.
I've added files under media\lua\shared\Translate\ES
Can anyone point me a decent tutorial or something? couldn't find anything not from 2014 xD

weak sierra
drifting ore
#

is there a way to make code not work if mod dependancies are not present? my mod doesn't strictly require them to work but i don't want them to function at all without them

bronze yoke
#
local activatedMods = getActivatedMods()

if activatedMods:contains("DependencyModID") then

end
#

if the dependent code is in a separate file from other code you could use an early return to be a bit cleaner

drifting ore
#

so that code prevents the rest of the file from being run? very nice thank you!

#

thank you both

bronze yoke
#

if you want to prevent the rest of the file you'd use then return end at the end of the if statement (this won't work inside a function as it'll just exit the function instead of the file)

#

otherwise you put the code you only want to run if the mod is present between the then and end

urban wind
#

Any big brainers ๐Ÿง  want to help to help me burn some corpses???
(IN-GAME, PLEASE LEAVE ME ALONE FBI)

Trying to use

    
    {
        Type                =    Drainable,
        DisplayName            =    Aluminium Strip Sparker,
        UseDelta             =     1.0,
        DisplayCategory        =     Survival,
        Weight                =    0.11,
        Icon                =    ZJStripSparker,
        cantBeConsolided     =     TRUE,
        WorldStaticModel     =     Battery,
        Tags                 =     StartFire; Lighter,
        ReplaceOnDeplete    =     Base.Battery,
        UseWhileEquipped    =    TRUE,
        StaticModel         =   Zippo,
        ActivatedItem        =    TRUE,
}

To burn a corpse, but it throws me an error

LOG : General , 1695971729421> ERROR: Missing translation "IGUI_ItemCat_Survival".

Anyone got any idea wtf's going on?

raven zinc
#

What if I?

urban wind
raven zinc
#

There's more coming

urban wind
lean reef
#

My test character just starved to death while I was testing stuff and it scared the shit out of me

#

That aside, does anyone know what the anchor booleans do for UI elements?

#

I feel like I should know what they do but am having trouble figuring it out

blissful salmon
#

I try to execute code after the following function from ISInventoryTransferAction.lua is called.
function ISInventoryTransferAction:transferItem(item)
My approach is the following
`
SoulMod.ISInventoryTransferAction.transferItem_orig = ISInventoryTransferAction.transferItem
function SoulMod.ISInventoryTransferAction:transferItem(item)
SoulMod.ISInventoryTransferAction:transferItem_orig(item)

-- code goes here

end
ISInventoryTransferAction.transferItem = SoulMod.ISInventoryTransferAction.transferItem
I get the following error
function: transferItem -- file: ISInventoryTransferAction.lua line # 444 | Vanilla
Line 444 --> if self:isAlreadyTransferred(item) then
Error --> attempted index: items of non-table: null.
`
I think something happens with the self variable. When make this call with dot-functions instead of colon-functions I works without problems.

As for my knowledge in LUA goes the following is the same (or maybe not):

function ISInventoryTransferAction:transferItem(item) function ISInventoryTransferAction.transferItem(self, item)

Can someone give me a hint? Or is there a better way?

shrewd sable
#

Hello everyone! I've started modding a couple of days ago and for now i created some items(weapons) and made translation to a second language but i'm missing something with a recipe. The problem is that i can make it require hammer or axe but not saw or canopener for example... Any thing am i missing? Thanks!

In the example basically i want players to turn a stop sign into the weapon i've created, but i want them to need saw for the process

keep [Recipe.GetItemTypes.Base.Saw doesn't work, keep Saw doesn't work, keep Saw/GardenSaw doesn't work, keep Base.Saw doesn't work, i've tested multiple ways, but doesn't work

recipe Create stop sign weapon
{
Moveables.street_decoration_01_0/Moveables.street_decoration_01_1/Moveables.street_decoration_01_2/Moveables.street_decoration_01_3,
keep [Recipe.GetItemTypes.Base.Saw],

    Result:StopSign,
    Sound:Sawing,
    Time:200.0,
    Prop1:Saw,
    AnimNode:SawLog,       
}
verbal yew
#

keep [Recipe.GetItemTypes.Saw]

#

keep [It'sFunctionInLua]

#
function Recipe.GetItemTypes.Saw(scriptItems)
    scriptItems:addAll(getScriptManager():getItemsTag("Saw"))
end```
#

return scriptItems like all items with tag "Saw"

shrewd sable
#

It works with Hammer, not with Saw ๐Ÿ˜…

verbal yew
#

wtf...

verbal yew
shrewd sable
#

Not in my script, really

grizzled fable
#

it is possible to create a mod to add an admin command to spawn an item to a specific coordinates?

verbal yew
shrewd sable
hollow current
#

Still need help regarding this by the way!

uneven nova
#

omg I finally finished my Hoshino from Blue Archive outfit mod for Zomboid yay!!

plucky nova
#

i was wondering if it was possible to make a mod that allows zombies to use weapons, but in a way more simple way
my idea was to have it only be visual (at least for now) and just replace the attachment points for "stuck" weapons in zombies to be their hands instead of their bodies, so it looks like they are holding them

#

mainly, i was just wondering how difficult that would actually be.
i mean, im pretty sure Authentic Zeds did it before on a few zombies, but id like to do that on the vanilla zombies too. i just have to figure out how

tardy wren
plucky nova
tardy wren
#

Well... Then likely yes

plucky nova
#

well, would you have any idea how to go about doing this?

#

because no other mod ive seen has done this yet

tardy wren
#

Hmm, no, not really

#

I haven't touched zombies yet

#

I think you can modify the attachment points for weapons stuck in zombies

#

Or have them be part of their outfit

plucky nova
#

i just need to figure out how to do it...

tardy wren
#

you have the docs, right?

plucky nova
#

actually no

#

what docs?

tardy wren
plucky nova
#

alright then, im gonna have to check this out

#

thanks

#

im assuming im gonna have to decompile these files and edit them somehow

#

oh god, im really not all that great with coding lol

pulsar rock
#

Hey hi, is there a way to edit existing UI elements through LUA?

#

I'd like to make some changes to the visuals of the skill overview, for example.

plucky nova
#

i think you should ask the creator of that mod about it

pulsar rock
#

I see

#

Thanks for the heads-up

#

I'm trying to find where this menu is created, if you have any idea:

plucky nova
#

no, sorry, i dont know anything about ui, but as i said, i think you should talk to the mod creator about this

neon bronze
pulsar rock
#

I can find the ISHealthPanel, but no link to the Skills/Temperature/Protections/Info tabs.

neon bronze
#

Think its in the player stats folder

dark wedge
bronze yoke
shrewd sable
#

My mod is very simple, still makes the game load slow and i have to wait on "this is how you die" as i click and nothing happens, i have to let the screen fade alone so i can join the game. Anyone knows why it takes so long for 2 items and recipes? No code yet

pulsar rock
#

Have you compared with and without the mod?

#

Is it the only mod enabled?

#

Have you checked logs?

shrewd sable
#

Yes, obly thing i've seen related to my mod is a "base imports itself" error. Removed th import and still slow. It's like the click to continue screen is behind the "this is how yo died" and until it fades you just can't click. The message doesn't appear

#

But i got another weird thing... I've created a recipe that allows to require a hammer but doesn't work with a saw

#

I'm about to suffer a stroke trying to understand what's going on... I'm not new to game dev, but the randomness of this problem is driving me mad

tiny wolf
#

Hello everybody โญ
I would like to make computers in project Zomboid lootable with loot inside.
Do someone knows how to do this ?
Use TileZ to edit the existing computer tiles ?
Use a script to transform this tile on a game start ?
Please let me know ๐Ÿ™‚

shrewd sable
#

overwrite the computer item making it be a container? i'm not sure but i think it's the way, just create a new container with computer script and make a placeable object (i'm telling you this as if i know how to do it xD)

#

Can anyone explain me this please? Why saw is not required? It works with the hammer and axe but not with saws and canopener for example... Tried different ways like Base.Saw, Saw/GardenSaw, etc. For me it's totally random, am i missing something?

tranquil kindle
shrewd sable
#

i don't mind at this point if it's consumed or not, as it never appear on the list. The reference to saw is broken somehow and i don't understand why

tranquil kindle
#

Its used in vanila, it should work with any saw/hammer that is added by other mods that are tagged properly.

shrewd sable
#

if i do keep [Recipe.GetItemTypes.Saw], it will not work...

#

Saw is like an item that doesn't exist... Why? i don't know but i'm finding this the second day of modding

#

any example with hammer works, any example with saws or other tools (some of them) not

#

didn't touch any original script or files from the game so... Why is this happening? xD

tranquil kindle
#

recipe Create shovel
{
Plank,
keep [Recipe.GetItemTypes.Saw],
keep [Recipe.GetItemTypes.Hammer],
Result:Shovel,
Time:100,
}
can you try this?

shrewd sable
#

also the game is starting pretty slow with just 2 recipes and items... i don't understand Let me try this

tranquil kindle
#

remember " , " as it will break the recipe

#

if its missing, aswell as big or small letters do matter aswell.

shrewd sable
#

doing the keep [Recipe.GetItemTypes.Hammer], accepts all kinds of hammer, but it's ignoring the F* saw ๐Ÿ˜ญ

#

And that's the result, as you can see it just ignores saws

shrewd sable
#

Would be funny if it wouldn't be taking all my patience ๐Ÿ˜„

tranquil kindle
#

Do you use any other mods?

shrewd sable
#

no, i'm testing only with mine

#

but maybe i should delete them all in case they're cause some conflict

tranquil kindle
#

i just used that code and it works

shrewd sable
#

interesting

#

i've deleted all and write only that, just for checking

tranquil kindle
#

Do you perhaps override saws in your mod aswell?

shrewd sable
#

nope i just use them as a tool to craft weapons from urban props, like a stop sign xD

#

i don't plan to change any vanilla stuff, just require them to craft my recipes to get my items, it's a very simple mod, nothing fancy

#

cause i'm trying to learn, specially why this is happening right now? xD

tranquil kindle
#

Just to be sure, you dont have your mod uploaded and subscribed and then changing things in your local files?

#

I remember i was trying to fix bug for a few hours only to realize i had my mod subbed on steam ,so changes in local files did not work untill i unsubbed

shrewd sable
#

so... i think i've somehow break the game, reinstall may help

#

ok, unsubbing xD

#

if that's the solution i owe you a beer

#

it's fucked up, going to reinstall

tranquil kindle
#

before that

#

See if any recipe that requires Saw works for you

shrewd sable
#

i checked and it doesn't

#

my recipe script only contains your code, and it shows the same, no saw required so i'm reinstalling

#

but i'm gonna make sure it removes all the files before reinstall

abstract raptor
#

asking for a fren -- is there a way to add our own shader to the game similar to water for a different tile?

bronze yoke
#

you can add your own shaders, but i don't know anything about tiles, so i can't promise you can do anything with them specifically

#

but there is modded shader support for models at least

abstract raptor
#

Yeah, what's the process like for adding my own shader?

shrewd sable
#

ok, reinstalled, checked without mods and some recipes required saw,ok all fine.
Added my mod tested and it's the same, so it's 100% my mod (good to know)
Without mods, after fresh reinstall the game still makes me wait until the "this is how your died" screen fades, as clicking doesn't do anything...
WTF did i write to mess it all up? Gonna be more careful ๐Ÿ˜ฌ

bronze yoke
#

you just need to drop a fragment and vertex shader in the shaders folder with matching names

#

GLSL shaders

abstract raptor
#

Interesting. So for instance

#

lets say I got a lava tile.

#

I wanna do exactly the same thing as the water shader, and draw it on top of the lava tile

#

but with different shader more optimized for that lava look

bronze yoke
# bronze yoke

just had a quick look and it looks like only vehicle shaders have _static versions, so it's probably specific to vehicles

#

the limitation would be if tiles let you set a shader for them, i have no idea

#

but i do know that custom shaders will be loaded by the game, basically

abstract raptor
#

Hmm yeah I'm doing lots of searchin' but I can't find where the logic of it being applied to just the blends_natural_02 tiles

tiny wolf
#

and by editing which file ?

shrewd sable
#

Not sure, but try to find the computer if here: https://pzwiki.net/wiki/Appliances#Communication I've checked and the computer isn't implemented so you can write you own instance of a container, with the computer sprite, there's a variation with the screen turned on, so you can develop a whole system on that

shrewd sable
#

ok After a reinstall and some tests it all works fine. Thanks!
The game still makes me wait until "this is how you die" screen fades on the first play don't know why

#

Is there any way to refer to a broken tool? I wanted to use an axe with 0 durability as an ingredient for a recipe but can't find how

fast galleon
abstract raptor
fast galleon
#

water tiles, those are set as IsoWater type

IsoFlagType.water

Update:
I forgot water is abnormal. Besides the water flag, the game also uses the IsoWaterGeometry which disables normal sprite rendering for "blends_natural_02" among other things.

abstract raptor
#

You think you're being helpful, but what I'm saying is I can't find the code that STATES that, where it's decided in lua, if it is. It doesn't seem to be, no indication. Just cuz it says IsoWater doesn't automagically make the logic for things that are water to be water, the code probably assigns that value somewhere and that's what I can't find.

bronze yoke
#

i would doubt it would be in lua, rendering stuff is generally totally locked off

abstract raptor
#

yeah that was my worry.

#

Look, I was responding off of your energy -- typically just posting something that's crossed out without explanation could be misconstrued as sarcasm or something

covert carbon
#

I went back to working on a mod after a few weeks break

#

and the error bar isnt showing errors

#

but my mod isnt working

fast galleon
#

sorry for looking

abstract raptor
#

Oh it's a tileproperties thing

#

๐Ÿค” Which would mean, I'd need to set up a custom tile property somehow if I wanted to do the lava shader hmmmmmmmmMMMMm ๐Ÿค”

urban wind
#

sup people

covert carbon
#

yo

abstract raptor
#

actually I don't think it's set on tileproperties

#

I just opened up the blends_natural_02 tile properties and this is all it has

urban wind
#

Check it out, a survival/realism mod for making strip lighters

lean reef
#

I'm still dumb and can't seem to figure out what the anchor params do for UI Elements, does anyone know what they do?

#

I'm messing around with UI stuff and I feel like I should know what they do

bronze yoke
#

when the parent changes size, it will move along with that edge

lean reef
#

And the resize widget in the collapsablewindow class is anchored both the right and left, so does it stretch to both sides when that happens?

#

or well, when the edge changes

bronze yoke
#

yep! it stretches so that the gap between it and the edges stays the same as it was before

lean reef
#

Cool! Thank you! Using anchors seems like a far smarter way of doing things than the way I've been doing it lol

#

Ive just been constantly resizing things to the parent dimensions

#

I'm gonna have to keep doing that for some things, because I'm trying to render things that follow an element but are outside or stretch beyond that element, and I dont think there's a way to make a child able to ignore a parent's bounds so they have to not be parented

shrewd sable
#

Is there any way to insert a little wait/delay between steps in a recipe while being crafted? I would love to use different props and sounds during the crafting

sour island
shrewd sable
#

Awesome

sour island
#

Ty

lean reef
#

omg that looks excellent!

#

you're storing the deck's card order in its modData, right?

pulsar rock
#

Is this open source? Would love to learn from this tbh.

sour island
shrewd sable
#

why the sound loops when crafting a vanilla recipe but not when i'm crafting mine?

sour island
#

Still working on it, not ready for official release

lean reef
sour island
#

aw, thank you ๐Ÿ˜…

#

Incase you haven't looked at it recently, I redid the UI window to use textures rather than UI elements for each item

lean reef
#

Ooo, will do! Thanks for letting me know!

sour island
#

This was super satisfying to make

#

All using textures - it identifies which card or which spot inbetween cards is being moused over using math

#

Even supports scrolling - although seems like the name plate is in need of a tweak lol

pulsar rock
#

@sour island I'm wondering why you have some objects defined as globals, and some as locals? I'm not super familiar with LUA beyond scripting (I come from C++ & Python, for frame of reference). Example being gameNight - window.lua having gameNightWindow be global, while for example deckActionHandler in gameNight - deckActionHandler.lua is defined as local.

sour island
#

The UI in vanilla is global

#

I could probably make those local to make them more safe to use

pulsar rock
#

Ah, it's purely because you're subclassing?

sour island
#

But I honestly didn't want to shake out bugs with unforseen issues

pulsar rock
#

Gotcha, okay. Thanks for the insight!

sour island
#

np

pulsar rock
#

This is some dang impressive work.

sour island
#

TY, I hope it's easy to follow ๐Ÿ˜…

#

I'm hoping people pick it up and run with it to add various games

pulsar rock
#

I'm wondering what your development method is? Did you pre-plan this / make some architectural designs? Or did you just throw yourself at it?

sour island
#

A little bit of everything

#

I knew I wanted to make the vanilla game items supported - while also keeping it being a framework in mind

pulsar rock
#

I haven't taken a deep dive into the games yet, but are they properly scripted? Or are they "just" functional in a way that allows players to enforce the rules manually?

#

Like, are game rules tracked and enforced by the scripts, is basically my question.

sour island
#

The latter, it would be alot more work for myself, and anyone trying to build on it otherwise

pulsar rock
#

Fair enough

#

I figured

#

It'd be low key insane to program Catan / Monopoly in LUA tbh

sour island
#

It's basically tabletop simulator - I added hooks to allow for adding more functions to items like flipping pieces and such

pulsar rock
#

Very nice

sour island
#

The 3 add-ons I'm working on will also showcase how to make one's own add-on

#

Might have to pivot some mechanics to handle money better - as it would be a giant pile of items otherwise

#

I already have a mechanic for money with my shops mod

#

That's basically my workflow - build something with expansion in mind, then expand it lol

lean reef
sour island
#

I'm not sure if it can be local, might be worth a try

lean reef
pulsar rock
#

Looking at it, you grab textures based on the card names?

#

Or, well, items in a "deck"

sour island
pulsar rock
#

Definitely makes it simple for modders to add stuff tbh

sour island
#

The other game pieces are standard items outside of some script manipulation

#

Tedious copy pasting is something I try to avoid lol

pulsar rock
#

It seems, at its core, to create a new minigame you really only need a list of strings representing a standard deck, and then add it to the deck cataloger?

#

And then the textures, of course

sour island
#

Yes, for decks

#

Otherwise you just provide some item scripts, textures, and register the items for game pieces

#

Card games are much easier to implement

pulsar rock
#

Beyond this, you can add some additional logic for sound, special cards that can be rotated (and possibly have other actions?), and game boards?

sour island
#

Yes, cards are their own type of system but they can utilize the game piece systems

sand harbor
#

Is there any sort of event which lets you get and modify any sounds a player makes? (for instance, when a player generates sound check to see if they're swinging a weapon and reduce the amount of sound)

fast galleon
#

Actually, it probably would be best to make a derived custom one, you probably would need more than a few changes.

#

Or make it multi-stage.

shrewd sable
#

Well, thank you but as i'm starting i think i will let it for later. Or maybe i should jump into lua so i can start doing more complex stuff, where should i start?

lean reef
fast galleon
drifting ore
#

could somebody please help me with this?

shrewd sable
#

How do i refer to an item with 0 durability in a recipe?

fast galleon
shrewd sable
#

seems like you're not logged

drifting ore
#

maybe i will restart my steam

#

yup for some reason steam logged me out

#

thanks a lot

shrewd sable
#

I'm on the wiki checking yes, but didn't find the way to require a broken axe for a recipe instead of an axe with durability

#

i can allow broken items, but i want to allow only broken items

fast galleon
#

you could add a test function

shrewd sable
#

don't know how to add functions ><

fast galleon
shrewd sable
#

The thing is that i'm a bit lost on that, let me ask a couple of dumb questions first xD

I place the functions in files on the lua folder right? client/server/shared depending on something i ignore for now.
So then i can call those function through recipes?

fast galleon
#

that's right. That's where lua files go. You will need to make a global function with that name. Often those are added to the Recipe table, this means the lua file should be in the server folder.

shrewd sable
#

Ok thank you very much, i'm starting to understand. I know C# and i've been developing with Unity 6 years but i'm totally new to lua and modding this xD

#

I'll try some stuff tomorrow and see if i can start learning the way to communicate with Zomboid as i've done with Unity so i can create an awesome mod

#

tyvm

urban wind
#
    
    {
       EmptyLighter = 1, [Recipe.GetItemTypes.Petrol],
       Result:Lighter,
       Time:75.0,
       Category:Cooking, //Changed to "cooking" for test, should be "survival"
       StopOnWalk:false,
       StopOnRun:true,
       sound:EmptyPan, //want this to be "PourLiquidOnGround"
       AnimNode:Pour, //This is actually a weird animation for it, because it pours on the ground. Test for now, delete later.
       
    }```

Sound and animation aren't playing for this custom recipe...Straight copypastes from other recipes.....Any ideas?
urban wind
urban wind
#

anyone know how the update process works for a pre-existing steam item?

open drum
#

Hi everyone, anyone has a tips of advice on making "composter" thumpable ?

#

or a simple way to delete/prevent players from making them

#

I tried to find info on forum and finding a mod on steam

#

but I wasn't successful

verbal yew
#

god damn....
I want do thing with character invenory, like:
Inventory not show, but if u push "i" your character sit, take backpack on the ground, after this u can see your inventory

#

or like tarp, if u without backpack

lean reef
#

Does anyone know why the player character lua code, like traits and professions, is stored in the file labeled "NPC" ie non-player character?
I've been curious about this for a while now

#

oh wait

#

is it not?

#

have i been mistaken

#

No it is

#

MainCreationMethods.lua is where its at

#

It doesn't, like, change anything obviously, its just the folder name

#

im just curious

#

Also, I have a very vague memory of reading somewhere that instead of making a bunch of global variables for a mod, you should instead make one single global variable that's a table that you put all your other intended global variables into for optimization reasons/not cluttering the global variable pool
Is this, like, a real thing or is my brain making this up? Like should I be doing this?

topaz nebula
#

Anyone have any tips for getting into making mods

#

I know the bare minimum of programming and somewhat of how it works I just don't know how to apply it and how to use it in the game code

lean reef
#

I've only just gotten into modding, but the first and, in my opinion, most important part is having a strong idea of what you actually want to make

#

Once you've done that, look up tutorials for things that are close enough to your mod, like for example if you wanna make a new hat item, look up how to make zomboid hat mod and if you dont find anything try searching zomboid clothing mod, so on and so on

#

once you find the closest guide for your mod, follow it up until it no longer works for your idea and figure out why it doesn't work for your idea and dig deeper into more resources or references

#

By the time you've followed one guide, you probably have learned enough during that journey to find tools or resources for whatever else you need to work on

#

Obviously, it depends on your idea and the scope of that idea, this is just the path that I took (and the path I'm still currently taking lol)

#

if your idea has a really large scope, you may one to single out what you think is the easiest element or sub-idea of your main idea

#

https://youtu.be/-yrmCAwzTbY?si=jmIaFk0PcGog4z-h This tutorial specifically is what got me started on my path

1:11 Step 1 - Know your file locations
4:06 Step 2 - Storyboard your ideas out
9:03 Step 3 - Get your files from the game or other mods
11:47 Step 4 - Build your mod files
1:01:54 Step 5 - Create the textures (mislabeled in the video, oops)
1:19:45 Step 6 - Put your mod files in the right structure
1:30:37 Step 7 - Test your mod (please back up ...

โ–ถ Play video
#

it by no means teaches you everything you'll need to know for something really complicated, but it got me on the right path for understanding the basics of how zedscript and lua works and what keywords to search or look for

topaz nebula
#

Heard I appreciate it I don't know exactly what I wanna do but I know I wanna do a sort of crafting overhaul I think

#

Or something to emphasize the crafting in the game

lean reef
#

Well I'd certainly look into the recipe system then! The tutorial I posted actually goes into the basics of creating a recipe script as well as making a lua file to program more advanced recipe code!

#

Oh! Also I'd recommend downloading mods that work with similar concepts and looking through their file structure and code to get an idea of the solutions or ideas other people have found

topaz nebula
#

Oh sick I'll take a look into the video and I was just thinking about how I should mess around with some mods and possibly see if I could get inspiration on what I'd like to do

lean reef
#

I can't remember if the video goes into looking at other mods or if they just look at their own past mods, but if it doesn't you'll find mods you install from the workshop in your Steam folder under "steamapps\workshop\content\108600" and they'll be listed according to their workshop ID

bronze yoke
#

using one global instead of many is good, but you can just use none instead

#

keeping things completely local and modular makes things much less tangled and avoids both name conflicts and the performance cost of the global namespace

#

globals are slow, messy and there's almost never a reason to use them

#

only case i can think of is for functions referenced by scripts, they can't interact with modules so those functions do need to be global

lean reef
#

I suppose I should be looking more into lua modules! Thank you for the info!

bronze yoke
#

the basic idea is to put everything you want to be accessible in a local table, and then return the table at the end of the file

#

other files can use require(filename) to grab a reference to that table

lean reef
#

Fascinating! I've been wondering why I've been seeing return functions like that at the bottom of files but didn't know how to look up why!

bronze yoke
#

yeah, files are essentially functions and require grabs the return value

#

minor note is that pz has a custom implementation of require that doesn't support multiple return but that's niche

lean reef
#

I'm looking at an online thing explaining lua modules and it gives the example of:


function mymath.add(a,b)
   print(a+b)
end
-- Other stuff

return mymath
#

is the function mymath.add also local because its apart of a local table?

bronze yoke
#

yeah! it only exists as part of that table

lean reef
#

Alright great!

#

Now knowing this has probably saved me from a loooot of mistakes and optimization work in the future

bronze yoke
#

yeah, unfortunately the pz code never does this so it's something most modders don't learn until much later

lean reef
#

Yeah, my reference for what I've been working on was the "forageDefinitions" file and it stores its forageDefaultDefs table globally despite the fact that files that utilize it usually have to require forageDefinitions anyway for the functions to actually use those default defs

#

though I suppose I dont know enough about lua to say that for certain

bronze yoke
#

i often think about the utopia we would live in if lua defaulted variables to being local and instead had a global keyword

lean reef
#

Thank you for all the insights! I'll see if I can put them to good use!

tender scroll
#

Anyone know the media lua folder location for Plumbing sink to water barrel is?

blissful salmon
tropic hedge
#

Thank you, one last question. Do you know a method for retrieving a user/client ID?

open drum
#

still looking for a way to disable composter from server

#

there must be a easy way...

#

will deleting -- compost local compostOption = subMenu:addOption(getText("ContextMenu_Compost"), worldobjects, ISBuildMenu.onCompost, player, "camping_01_19"); local tooltip4 = ISBuildMenu.canBuild(5,4,0,0,0,2,compostOption, player); tooltip4:setName(getText("ContextMenu_Compost")); tooltip4.description = getText("Tooltip_craft_compostDesc") .. tooltip4.description; tooltip4:setTexture("camping_01_19"); ISBuildMenu.requireHammer(compostOption)

from ISBuildMenu.lua

#

do the trick?

verbal yew
hollow current
#

any idea how do you make an animation loop from a certain point instead from the beginning?

#

or keep the player stuck on the last frame of the animation

neon bronze
#

Not really unless you transition to a looping animation at the end?

hollow current
#

not really sure about that, this is about my first time messing with an animation file's xml, doing it blindly cause no guides xd

<?xml version="1.0" encoding="utf-8"?>
<animNode>
    <m_Name>KnockedOut</m_Name>
    <m_AnimName>Zombie_Death</m_AnimName>
    <!--<m_Looped>true</m_Looped>-->
    <m_SyncTrackingEnabled>false</m_SyncTrackingEnabled>
    <m_SpeedScale>0.70</m_SpeedScale>
    <!--<m_BlendTime>0.80</m_BlendTime>-->
    <m_Scalar></m_Scalar>
    <m_Scalar2></m_Scalar2>
    <m_SubStateBoneWeights>
        <boneName>Dummy01</boneName>
    </m_SubStateBoneWeights>
    <m_SubStateBoneWeights>
        <boneName>Translation_Data</boneName>
    </m_SubStateBoneWeights>
</animNode>```
#

the intended result is to have the player stuck on othe last frame of the Zombie_Death animation (i.e. stay laying on the floor)

nova socket
#

Bro, anyone ever managed to create a completely working IsoMannequin so far?

urban wind
open drum
#

since moving them makes them vulnarable to zombies thumping

#

would be happier if there was a way to make them thumpable though...

urban wind
open drum
urban wind
#

what errors are getting thrown?

open drum
#
    local compost = ISCompost:new(player, sprite);
    compost.modData["need:Base.Plank"] = "5";
    compost.modData["need:WURO_items.Composter"] = "1";
    compost.modData["need:Base.Nails"] = "200";
    compost.modData["need:WURO_items.Composter"] = "1";
    compost.modData["xp:Woodwork"] = 5;
    compost.player = player
    compost.notExterior = true;
    compost.completionSound = "BuildWoodenStructureMedium";
    getCell():setDrag(compost, player);
end```
#

as so, the problem is

#

it's not showing correctly on the game

#

still telling me it only need 5 planks, 4 nails, and level 2 carpentary

#

i guess the text is handled in some other place?

#

oh, it stops me from making the compost as it should

#

just shows its craftable

#

but not placeable

#

so i guess it only worked half way...

#

sorry the language is in korean

#

was too lazy to change to english just for screenshot ๐Ÿ˜›

#

with some research

#

i found that necessary material indication is handled in other snippet

#
    local compostOption = subMenu:addOption(getText("ContextMenu_Compost"), worldobjects, ISBuildMenu.onCompost, player, "camping_01_19");
    
local tooltip4 = ISBuildMenu.canBuild(5,4,0,0,0,2,compostOption, player);
\


    tooltip4:setName(getText("ContextMenu_Compost"));
    tooltip4.description = getText("Tooltip_craft_compostDesc") .. tooltip4.description;
    tooltip4:setTexture("camping_01_19");
    ISBuildMenu.requireHammer(compostOption)```
#

after canBuild(5,4,0,0,0,2)

#

i wonder if it is possible to manually change them by just typing "string" instead of those 0s or would that give off error...

mellow frigate
#

Hello there, has anyone an example of mod using looping sound ?

verbal yew
#

I don't know if it will fit. But the method for loop sound and stop it

verbal yew
# mellow frigate Thanx a lot.

if i'm not wrong, it's can be another way just

getSoundManager():PlayWorldSound("zReBL_crowbarSound", self.character:getCurrentSquare(), 1, 25, 2, true)

and loop = true

#

loop This parameter determines whether the sound will be looped. (Will play until the sound is turned off with Lua code)

verbal yew
#

Guys

#

how to get vehicle part near trunk?

mellow frigate
verbal yew
mellow frigate
verbal yew
mellow frigate
verbal yew
#
    local vehicle = playerObj:getVehicle();
    local trunkdoor = vehicle:getPartById("TrunkDoor");
    local trunkdoor2 = vehicle:getPartById("DoorRear");
    
    if not vehicle then return end
    
------ zRe FIX for Vanilla: -----------------------------------------
    if trunkdoor then
        if trunkdoor:getDoor():isLockBroken() then
            playerObj:Say(getText("IGUI_PlayerText_VehicleLockIsBroken"))
        return 
        end
     elseif trunkdoor2 then
        if trunkdoor2:getDoor():isLockBroken() then
            playerObj:Say(getText("IGUI_PlayerText_VehicleLockIsBroken"))
        return
        end
    end
---------------------------------------------------------------------

Why does it seem to me that the fix code looks like complete ass?

#

pz supports conditions like nand, nor?

fast galleon
#

move if not vehicle to before getPart

hollow current
fast galleon
#

there is also function to get closest part to interact with

verbal yew
#

it's button from inside vehicle on UI

#

turn on/off trunk door

#

on lock

verbal yew
fast galleon
#

lol, you can make it prettier by making it a loop or call another function

fast galleon
#

for _,i in ipairs{"a","b"} do

or

doSomething("a")
doSomething("b")

or

local parts = {}
table insert(parts,get("a"))
table insert(parts,get("b"))
verbal yew
#

massives... I never understood how to work with them...

fast galleon
#

I don't understand, did you mean something else? What exactly troubles you about your snippet?

verbal yew
fast galleon
verbal yew
#

I literally don't understand how to put this knowledge into practice. What value should be returned when, in fact, you are checking on parts of cars, and in the function only (PlayerObj)

fast galleon
#

hm, go wild

#

vanilla doesn't return anything so you can return anything you want without breaking anything

verbal yew
# fast galleon vanilla doesn't return anything so you can return anything you want without brea...

how hook that fix into vanilla func?

function ISVehicleMenu.onToggleTrunkLocked(playerObj)
    local vehicle = playerObj:getVehicle();
    if not vehicle then return end
------ zRe FIX for Vanilla: -----------------------------------------
    local trunkdoor = vehicle:getPartById("TrunkDoor");
    if trunkdoor then
        if trunkdoor:getDoor():isLockBroken() then
            playerObj:Say(getText("IGUI_PlayerText_VehicleLockIsBroken"))
            return 
        end
    end
    local trunkdoor2 = vehicle:getPartById("DoorRear");
    if trunkdoor2 then
        if trunkdoor2:getDoor():isLockBroken() then
            playerObj:Say(getText("IGUI_PlayerText_VehicleLockIsBroken"))
            return
        end
    end
---------------------------------------------------------------------
    sendClientCommand(playerObj, 'vehicle', 'setTrunkLocked', { locked = not vehicle:isTrunkLocked() });
end
fast galleon
#

I'm not at pc to check, but what is the main purpose of this, just to trigger the say lines? I thought door would stay locked in vanilla if the lock is broken.

verbal yew
#

button up this script:

function ISVehicleMenu.onToggleTrunkLocked(playerObj)
    local vehicle = playerObj:getVehicle();
    if not vehicle then return end
    sendClientCommand(playerObj, 'vehicle', 'setTrunkLocked', { locked = not vehicle:isTrunkLocked() });
end
#

Basically, there are no methods in the game to break the lock on the trunk door.

#

another door's - yep

#

When they are broken - the door widget turns yellow when some door cannot be closed (because the lock is broken)

#

standart doors have check for lock state:

function Commands.setDoorLocked(player, args)
    local vehicle = getVehicleById(args.vehicle)
    if vehicle then
        local part = vehicle:getPartById(args.part)
        if not part then
            noise('no such part '..tostring(args.part))
            return
        end
        if not part:getDoor() then
            noise('part ' .. args.part .. ' has no door')
            return
        end
        if not part:getDoor():isLockBroken() then
            part:getDoor():setLocked(args.locked)
        end
        --vehicle:toggleLockedDoor(part, player, args.locked)
        vehicle:transmitPartDoor(part)
    else
        noise('no such vehicle id='..tostring(args.vehicle))
    end
end
#

but not trunk:

function Commands.setTrunkLocked(player, args)
    local vehicle = player:getVehicle()
    if vehicle then
        vehicle:setTrunkLocked(args.locked)
    else
        noise('player not in vehicle')
    end
end
tired charm
#

Hi! I'm working on a small mod and I'm trying to differentiate zombie types I have in my mod by assigning them outfit.

Now, everything works completely fine in singleplayer (as I can easily set them and refresh them every hour to make sure all the outfits are correct) but this starts to give problems in MP, rightfully so, as I know nothing about networking. May I ask any of you kind souls to give me some advice on how to sync these? Zombie types and all of that syncs well as I'm testing on some already-working code (in private) but I can't manage to make outfits work together. Thank you.

mellow frigate
tired charm
# mellow frigate mp zombies changes ain't no small mod. maybe check other existing mods on the wo...

Yeah stressed stressed I'm working with CDDA Zomboids as a base code to learn about it really and get something to work. Zombie stats syncing works fine in MP (even if I still have some issues understanding some parts of it), outfits work fine in SP but I Just Need to get them to work to Sync in MP. As of now, stuff works fine but clients get different outfits while they should load the same (I have different outfits for different zombie types based on their stats and skills)

bronze yoke
#

for stfr we just change the outfits on the client, didn't seem possible from the server side

#

it sort of seems like it *should* cause issues but i've never heard anything come up from it, they started doing it before i started helping out so i wasn't part of the initital testing

verbal yew
# tired charm Hi! I'm working on a small mod and I'm trying to differentiate zombie types I ha...
SprintOutfits = {
    "ArmyCamoDesert",
    "ArmyServiceUniform",
    "ArmyCamoGreen",
    "ArmyInstructor",
    "ArmyServiceUniform"
}
JogOutfits = {
    "AuthenticClown",
    "AuthenticClownParty",
    "AuthenticClownObese",
    "AuthenticClownBarotrauma",
    "AuthenticClownMime",
    "AuthenticClownMime",
    "AuthenticClownPennywise",
    "AuthenticClownWrinkles"
}

TRektZombieAI = {}

function TRektZombieAI.isSprinter(zombie)
    local zombieOutfit = zombie:getOutfitName()
    for _, v in pairs(SprintOutfits) do
        if v == zombieOutfit then return true end
    end
    return false
end

function TRektZombieAI.isJogger(zombie)
    local zombieOutfit = zombie:getOutfitName()
    for _, v in pairs(JogOutfits) do
        if v == zombieOutfit then return true end
    end
    return false
end

function TRektZombieAI.onUpdate(zombie, apply)
    if not zombie or zombie:isDead() then
        return
    end
    if TRektZombieAI.isSprinter(zombie) then
        zombie:setWalkType("sprint1")
    elseif TRektZombieAI.isJogger(zombie) then
        zombie:setWalkType("sprint5")
    end
    
end
Events.OnZombieUpdate.Add(TRektZombieAI.onUpdate)

server side LUA, not remember mod

#

have sync in MP

#

The idea behind the code is to make all army zombie is running, but thereโ€™s a lot that can be crammed in here.

With this garbage, I made a burning zombie that does not take damage from burning.

#

I believe that it is possible to adapt Braven's code from Zomboss to make zombie juggernaut with big hp

#

Not just a zombie in some kind of heavy armor, but one that actually protects him from attacks

#
SprintOutfits = {
    "FireProof",
}

TRektZombieAI = {}

function TRektZombieAI.isSprinter(zombie)
    local zombieOutfit = zombie:getOutfitName()
    for _, v in pairs(SprintOutfits) do
        if v == zombieOutfit then return true end
    end
    return false
end

function TRektZombieAI.onUpdate(zombie, apply)
    if not zombie or zombie:isDead() then
        return
    end
    if TRektZombieAI.isSprinter(zombie) then
        zombie:setFireKillRate(0)
        zombie:setWalkType("sprint1") -- 1-5
        if not zombie:isOnFire() then
          zombie:setOnFire()
        end
end
Events.OnZombieUpdate.Add(TRektZombieAI.onUpdate)

For example

#

Not die from fire and burning :3

#

It can be done simpler, not through costumes, but through a GetModData(), with a chance.

#

like:

function zReBURNINGCHAOS.onUpdate(zombie, apply)
    local zReFLAG = zombie:getModData().zReBC_EXCLUDE
    if not zombie or zombie:isDead() or zombie:isCrawling() or zReFLAG == 1 then
        return
    end
    
    local chance = ZombRand(1, 100)
    if chance < 5 then
        zombie:setFireKillRate(0)
        zombie:setWalkType("sprint1") -- 1-5
        if not zombie:isOnFire() then
          zombie:setOnFire()
        end
        zombie:getModData().zReBC_EXCLUDE = 1
     else
        zombie:getModData().zReBC_EXCLUDE = 1
    end
end
Events.OnZombieUpdate.Add(zReBURNINGCHAOS.onUpdate)
#

I've always wondered why Random Zombie works through such a huge array of code...

#
function zReRandomZombies.onUpdate(zombie, apply)
    local zReFLAG = zombie:getModData().zReRZ_EXCLUDE
    if not zombie or zombie:isDead() or zombie:isCrawling() or zReFLAG == 1 then
        return
    end
    
    local chance = ZombRand(1, 100)
    if chance < 5 then
        zombie:setWalkType("sprint1") -- 1-5 slow1-3 sprint1-5
        zombie:getModData().zReRZ_EXCLUDE = 1
     elseif chance < 10
        zombie:setWalkType("sprint2") -- 1-5
        zombie:getModData().zReRZ_EXCLUDE = 1
     elseif chance < 15
      blablabla
    end
end
Events.OnZombieUpdate.Add(zReRandomZombies.onUpdate)

all code of Random Zombies in one func

azure rivet
#

Hello, can I make dynamic recipes using the "IconsForTexture" to make texture combinations?
Or do I have to make the item with each combination style to put together 2 items with different camouflages?

royal prairie
#

hi all, im trying to make a mod that adds a wearable mask, but doesn't show up in the hat section where it should allegedly go (while making character. i do have the option where i have access to all clothing while making character)... any ideas why that is? i should preface in saying it shows up in the mod list and is enabled

muted garnet
#

in the start function the flag is set to true so that the action cannot be performed again, but this flag is set only for the player who performs the action, and not for all players, please tell me how this can be fixed?

self.corpse:getModData().Autopsy = true
bronze yoke
#

if corpse is an isoboject just self.corpse:transmitModData()

bronze yoke
#

might still work, doesn't work for all subclasses but most

verbal yew
#

hmm....

#

looks like not for dead body

tired charm
bronze yoke
#

oh we used to use named iirc, i think the change to persistent was after the last time i touched things so i have no idea what the practical difference is

tired charm
#

@verbal yew Thank you a lot! It is indeed what I'm trying to work on right now and I must say your method is probably what would work best.
Currently your method revolves around "use whatever zombie distribution the server has done about outfit and then set zombie types on that", while mine works the other way around "take whatever zombie types the server has set and dress the zombies". Yours probably works better as it leaves outfit syncing to the server, I'll see what I can manage to do and let you know, thanks!

tired charm
#

As you do:
zombie:dressInPersistentOutfit(outfit)
zombie:resetModel()

While I do:
z:dressInNamedOutfit(outfitName)
z:reloadOutfit()

really no clue about the methods difference

#

Time to boot the second client and test I guess lol.

tired charm
#

I must say after testing I found no difference between

zombie:dressInPersistentOutfit(outfit)
zombie:resetModel()

and

z:dressInNamedOutfit(outfit)
z:reloadOutfit()

No clue.

shrewd sable
#

What do i have to take into account when creating a new movable object?
I've written a recipe and an item as result. Copying the structure of a mod that places stuff. Anything that i'm missing? does it have to be in a .pack file?
I can craft the item, but game doesn't let me place it, it tell me "Moveable not valid" and "Cannot create recipe for this movable object: X"

#

Does it need a "placing" recipe?

shrewd sable
#

tyvm

#

Well i'm using a tile from vanilla, but reading this will clarify stuff for sure

fast galleon
shrewd sable
#

I want to create a campfire with another sprite basically

#

tried to copy from original files but didn't find the campfire so... i don't know xD

fast galleon
#

campfires are a special case

shrewd sable
#

too complex to make a new instance with other settings?

fast galleon
#

if you're not adding new features it shouldn't be too complex

shrewd sable
#

i want to create a new campfire with other sprite variation (on/off) and if possible to adjust temperature. That way i can create a recipe that is cooked above certain heat only achievable(?) through this new campfire

#

and the recipe would require proximity to this movable object, so it's the only way to prepare some stuff

#

sounds factible?

#

good, so i'll keep researching ๐Ÿค“ Thanks!

#

Would be good to find the campfire to study it xD

fast galleon
shrewd sable
#

thanks

fast galleon
#

as for placing your item, you either need to make the sprite moveable or copy / use the build cursor of the campfire and make a different item for it.

shrewd sable
#

I've read all those scripts and more or less i understand the functions and the behaviours but now i don't know if i should call those functions from my own "campfire-oven" script, how many of them do i need for my item and how all of this work. I want to keep trying to learn but somehow it's frustating as i know how to do it all in Unity with C# and it's like going back in time 8 years pffff
Don't want to bother, but i have to ask for a little help so i can start propperly modding by myself

sour island
modern hamlet
#

Is it possible to change generator's range?

sour island
#

Generator's are pretty javasided as far as the isoObjects go - so probably not.

#

If you have decompiled code you can check the java file for IsoGenerator

#

Looks like the range is in java and not even as a field

#

it is +/-20 outside, and the building/lot it is on

modern hamlet
#

Thank you for answering in such detail

sour island
#

Np

#

power systems seem to be on the agenda for the devs, so you might get your wish

modern hamlet
#

Oh that would be great

fast galleon
fast galleon
fast galleon
#

Campfire uses global objects so that it can change data for all objects on the whole map even when they are not loaded.

Unfortunately most systems need you to overcome hardcoded code. Best you can do is hook or inherit with lua. Depending how many parts you need to change you will choose one or the other way.

For inheriting lua uses metatables, PZ has a shortcut called derive for lua classes.

radiant flame
#

I was driving around in my 1+ year old world earlier this week and trying to burglar a car. Every car I came to had 0% battery charge. Then i realized its 1993 and WHERE TEH FUK R MY JUMPER CABLES. I looked around. I couldn't find a mod for them. So here you go. I made one. ๐Ÿ˜„

https://www.youtube.com/watch?v=OwuG9AleQS4

Scott's Jumper Cables is a Mod for Project Zomboid.\

Park your vehicles front to front and connect the jumper cables. Start the engine and you're good to go!

Check out the mod here:
https://steamcommunity.com/sharedfiles/filedetails/?id=2990322197

Check my other zomboid mod "Point Blank" here:
https://youtu.be/bnbjy8FDgCo

#projectzomboid #mods

โ–ถ Play video
muted lynx
#

Anyone know of an extension for visual code that'd help out with coding in lua? Like snippets and stuff.

sour island
mellow frigate
# sour island

The Game in the Game thing got you pretty far ๐Ÿ˜„

sour island
#

It was a good idea to implement monopoly, I had to refactor the card system to allow for cards to share visuals/names but operate differently

#

Now people can use shared textures or names

#

So something like yugioh can just use the type colors

muted garnet
#

if I start executing a timed action and while the character is walking, that is, the action has not yet started, I can call the context menu again, and then, if I do not remove this context menu, start the action again if I try to call the context menu after the beginning of the action, then it will not appear as intended, but how can I implement it so that the context menu does not appear or it cannot be used more than once before the start of the action, while the character is walking?

fast galleon
# muted garnet if I start executing a timed action and while the character is walking, that is,...

There are 2 points where you always check if it's valid, first when they click and the other one during the action, action.isValid. There is also another one less used for when the actions is not added as first in line, it's action.isValidStart.


Another solution is to use luautils.walkAdj(playerObj, square, keepActions) on context click, when keepActions is false or nil then the actions queue is reset.

verbal yew
verbal yew
#

ัƒะดะฐะปะธ ะตั‘ ะฒ ะดั€ัƒะณะธั… ะผะตัั‚ะฐั…, ั‚ะพะปัŒะบะพ ะฟะพ ะพะบะพะฝั‡ะฐะฝะธัŽ ะดะตะนัั‚ะฒะธั (ะฟะตั€ั„ะพั€ะผ ะตัะปะธ ะฝะต ะพัˆะธะฑะฐัŽััŒ) ะฟะพะผะตะฝัะน ั‚ั€ัƒะฟัƒ ะฒัะบั€ั‹ั‚ะพัั‚ัŒ ะฝะฐ true

#

ะฟะพ ััƒั‚ะธ ะฟะพั„ะธะณ ะตัะปะธ ะผะตะฝัŽ ะฑัƒะดะตั‚ ะฒั‹ะทั‹ะฒะฐั‚ัŒัั ะฟะพะฒั‚ะพั€ะฝะพ, ะดะตะนัั‚ะฒะธะต ะฒะฐะปะธะดะฐั†ะธัŽ ะฝะต ะฟั€ะพะนะดั‘ั‚

drifting ore
#

can somebody figure out why this error pops up? the syntax is the same as vanilla

local shortbladefan = TraitFactory.addTrait("Shortbladefan", getText("UI_trait_aptshortblade"), 3, getText("UI_trait_aptshortbladedesc"), false);

local shortbluntfan = TraitFactory.addTrait("Shortbluntfan", getText("UI_trait_aptshortblunt"), 3, getText("UI_trait_aptshortbluntdesc"), false);
shortbluntfan:addXPBoost(Perks.SmallBlunt, 1)

--ERROR COMES FROM HERE
TraitFactory.setMutualExclusive("shortbladefan", "shortbluntfan");```

```lua
Caused by: java.lang.NullPointerException: Cannot read field "MutuallyExclusive" because the return value of "java.util.LinkedHashMap.get(Object)" is null
drifting ore
#

S? S what?

fast galleon
#

just a guess but check the S capitaization

drifting ore
#

in setMutualExclusive? thats the correct method according to documentation

neon bronze
#

He means in the names that you pass to setMutualExclusive

verbal yew
#

Short Short
short short

drifting ore
#

How about this, when i create this traits, if i try to add them to a profession, i get this error attempted index: getLabel of non-table: null

    local foresthike = TraitFactory.addTrait("foresthike", getText("UI_trait_foresthike"), 0, getText("UI_trait_foresthikedesc"), true);
    local forestwalk = TraitFactory.addTrait("forestwalk", getText("UI_trait_forestwalk"), 0, getText("UI_trait_forestwalkdesc"), true);

i have UI text as well

    UI_trait_foresthike = "Test1",
    UI_trait_foresthikedesc = "Test12",
    
    UI_trait_forestwalk = "Test123",
    UI_trait_forestwalkdesc = "Test12",
    
#

im not sure if im missing anything, the way i understand, it can't find my trait, but it should. the syntax is correct. it works with other traits but not this one

drifting ore
#

it doesnt point to anything sadly

function: onSelectProf -- file: CharacterCreationProfession.lua line # 540 | Vanilla
function: onMouseDown -- file: ISScrollingListBox.lua line # 491 | Vanilla

ERROR: General     , 1696249971911> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: attempted index: getLabel of non-table: null at KahluaThread.tableget line:1689.
ERROR: General     , 1696249971911> DebugLogStream.printException> Stack trace:
java.lang.RuntimeException: attempted index: getLabel of non-table: null
    at se.krka.kahlua.vm.KahluaThread.tableget(KahluaThread.java:1689)
    at se.krka.kahlua.vm.KahluaThread.luaMainloop(KahluaThread.java:641)
    at se.krka.kahlua.vm.KahluaThread.call(KahluaThread.java:163)
    at se.krka.kahlua.vm.KahluaThread.pcall(KahluaThread.java:1980)
    at se.krka.kahlua.vm.KahluaThread.pcallBoolean(KahluaThread.java:1924)
    at se.krka.kahlua.integration.LuaCaller.protectedCallBoolean(LuaCaller.java:104)
    at zombie.ui.UIElement.onMouseDown(UIElement.java:996)
    at zombie.ui.UIElement.onMouseDown(UIElement.java:959)
    at zombie.ui.UIElement.onMouseDown(UIElement.java:959)
    at zombie.ui.UIElement.onMouseDown(UIElement.java:959)
    at zombie.ui.UIManager.update(UIManager.java:755)
    at zombie.GameWindow.logic(GameWindow.java:262)
    at zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:71)
    at zombie.GameWindow.frameStep(GameWindow.java:765)
    at zombie.GameWindow.run_ez(GameWindow.java:681)
    at zombie.GameWindow.mainThread(GameWindow.java:495)
    at java.base/java.lang.Thread.run(Unknown Source)
LOG  : General     , 1696249971912> -----------------------------------------
STACK TRACE
sour island
#

The top of the error is what's wrong with it

#

My guess is you're missing something from the arguments in addTrait

#

Go back and compare it to how vanilla adds them

signal moat
#

Guys I have an idea ,to make a fan copy of Project zomboid in Unreal Engine 5 .Who is interested DM me

drifting ore
#

hey hoomans, do u know if there's any way to create hair models without blender?

fast galleon
verbal yew
#

TraitFactory.setMutualExclusive("Shortbladefan", "Shortbluntfan"); for u

#
require('NPCs/MainCreationMethods');

local function initzReBLTraits()

    local nimblefingers = TraitFactory.addTrait("nimblefingers", getText("UI_trait_nimblefingers"), 0, getText("UI_trait_nimblefingersDesc"), true);
        nimblefingers:addXPBoost(Perks.Lockpicking, 2)
        nimblefingers:getFreeRecipes():add("Lockpicking");
        nimblefingers:getFreeRecipes():add("Alarm check");
        nimblefingers:getFreeRecipes():add("Create BobbyPin");
        nimblefingers:getFreeRecipes():add("Create BobbyPin2");
    local nimblefingers2 = TraitFactory.addTrait("nimblefingers2", getText("UI_trait_nimblefingers"), 3, getText("UI_trait_nimblefingersDesc"), false);
        nimblefingers2:addXPBoost(Perks.Lockpicking, 2)
        nimblefingers2:getFreeRecipes():add("Lockpicking");
        nimblefingers2:getFreeRecipes():add("Alarm check");
        nimblefingers2:getFreeRecipes():add("Create BobbyPin");
        nimblefingers2:getFreeRecipes():add("Create BobbyPin2");

    TraitFactory.setMutualExclusive("nimblefingers", "nimblefingers2");
    
    local traitList = TraitFactory.getTraits()
    for i = 1, traitList:size() do
        local trait = traitList:get(i - 1)
        BaseGameCharacterDetails.SetTraitDescription(trait)
    end    
end

local function initzReBLProfession()

    local burglar = ProfessionFactory.addProfession("burglar", getText("UI_prof_Burglar"), "profession_burglar2", -4);
    burglar:addXPBoost(Perks.Nimble, 2)
    burglar:addXPBoost(Perks.Sneak, 2)
    burglar:addXPBoost(Perks.Lightfoot, 2)
    burglar:addFreeTrait("Burglar")
    burglar:addFreeTrait("nimblefingers");
    
    
    local profList = ProfessionFactory.getProfessions()
        for i = 1, profList:size() do
        local prof = profList:get(i - 1)
        BaseGameCharacterDetails.SetProfessionDescription(prof)
    end
    
end

Events.OnGameBoot.Add(initzReBLTraits);
Events.OnGameBoot.Add(initzReBLProfession);
Events.OnCreateLivingCharacter.Add(initzReBLProfession);
#

it's how structure for moded trait/profession look like

left river
#

does anyone know how to limit 'moderators' from accessing specific server commands?

rich void
#

Hello guys, 1_spiffowave real head scratcher here, if I could get some advice it would be greatly appreciated, I've really exhausted options and been struggling with grasping this for a good week..

I've been attempting to add some client-server communication to prevent a context option from being available if a flag is set to true, here is the relevant code.

Client Context triggers a function that is stored in the shared space

if TerritoryWarfareCapture.IsInProgress(controlPointID) then
        player:Say("A Territory War Event is in progress here.")
    elseif hasOwnFlagOnCorner then
        player:Say("We already control this territory")
    elseif playerFaction == winnerFaction then
        context:addOption("Start Territory War Event", worldObjects, function() startTerritoryWarEvent(controlPointID) end)
    else
        player:Say("It seems a little... too quiet here")
    end
 end

When the "startTerritoryWarEvent" is triggered we send the command to the server

function startTerritoryWarEvent(controlPointID)
  local args = {
    controlPointID = controlPointID,
    capturing = true -- Yes this is reduntant now
  }
  sendClientCommand("TerritoryWarfare", "CaptureStarted", args)
-- rest of the code

A timer completes and then we declare the winner

function declareWinner(controlPointID, winnerFaction)
  local args = {
      controlPointID = controlPointID,
      capturing = false -- Yes this is reduntant now
    }
  sendClientCommand("TerritoryWarfare", "CaptureCompleted", args)
-- rest of the code

This is the client command receiver which is running on the server side


-- Register server command receiver --server
function receiveClientCommandForTerritory(module, command, args)
  
    if module ~= "TerritoryWarfare" then return; end

    if command == "CaptureStarted" then
        sendServerCommand("TerritoryWarfare", "CaptureStarted", args)
        
    end

    if command == "CaptureCompleted" then
        sendServerCommand("TerritoryWarfare", "CaptureCompleted", args)
    end

end

Events.OnClientCommand.Add(receiveClientCommandForTerritory)

The command should then be passed back to all clients and is handled in a client script like so


-- Register client command receiver  --client
function receiveServerCommandForTerritory(module, command, args)
 
    if module ~= "TerritoryWarfare" then return; end
    
    if command == "CaptureStarted" then
        print("Received Command Capture Started!")
        TerritoryWarfareCapture.CapturingControlPoints[args.controlPointID] = true
    end

    if command == "CaptureCompleted" then
        TerritoryWarfareCapture.CapturingControlPoints[args.controlPointID] = nil
        print("Received Command Capture Finished")
    end

end

Events.OnServerCommand.Add(receiveServerCommandForTerritory)

As shown in the first code block during the context we run this utility return function from the shared space to see if the event is in progress to prevent overlapping events on the same control point

TerritoryWarfareCapture = {}
TerritoryWarfareCapture.CapturingControlPoints = {} -- Table to track ongoing capture events

--shared
function TerritoryWarfareCapture.IsInProgress(controlPointID)
    return TerritoryWarfareCapture.CapturingControlPoints[controlPointID] == true
end

Any hints at what might be going wrong here would be much appreciated, I've gone through some debug print statements to see if my commands are being received, no luck, can't make it passed the module check on either server nor client side. Cryflood

bronze yoke
rich void
bronze yoke
#

yeah, remember arguments are passed by order not name so your code assumes args is the argument table when it's actually a player object

final sluice
#

Idk anything about coding this shit looking like harry potter spells or smth weirdassskullemoji15 weirdassskullemoji15

median prairie
#

Totally agree. :p

Well, I have a question -- Looking to adjust "ZombieZoneDefinition" To only have a specific type of zombie with a specific type of outfit spawn. I attempted to only have

in the file (Along with ZombiesZoneDefinition.Default = {}; of course) , but that didn't work.

Any advice?

fleet steeple
#

Anyone know how to create a randomized tile blend for replacing concrete?

#

If thats possible

fast galleon
fleet steeple
verbal yew
#

how to get character temperature?
Should I work on each body part separately or can it be one param for all?

fast galleon
#

you could use the Moodle level?

verbal yew
#

not want work with Moodle lvl

#

roughly know how to do this, but I donโ€™t know what is responsible for the temperature (itโ€™s when the character is active in heavy clothes that he starts to get very hot)

urban wind
#

Anyone know how to change ownership of map tile objects so they're not thumpable?

#

I'm trying to paste the tall wall fences they use in some neighbourhoods, they as soon as I do, they get broken by a horde

blissful salmon
#

I created a drainable oil lamp which can be used as a lightsource. This works so far so I can hold and light it. I created a visible model etc.
What I like to do now is to make it placeable like normal lamp (or campfire) and being able to light it.
But I have no clue where to start. I assume that I have to create something like an IsoThumpable or something like this... Is there a tutorial for something similar?

prisma gale
blissful salmon
prisma gale
tiny wolf
#

Hello everybody ๐ŸŒž Hope you're fine
Does someone know a table command to remove a clothe from vanilla Zombies ?
I want to remove the vanilla PoliceBulletVest and replace with a modded one

verbal yew
#

your zombie preset override vanilla preset with same guid and preset name

#

Easy way - change Police Vest in script - use parameter from mod with Vest, but item ID stay old

#

Easy way 2 -
use adjuster in client side lua for change Police Vest (better compatibility)

tiny wolf
verbal yew
#

and with this stuff change parameters on moded vest

#

for Police vest

#

stuff like item do param

tiny wolf
#

Gonna take a look ๐Ÿ˜‰

nova socket
#

Sometimes, just sometimes I want to kill people when coding in lua
Apparently doing ipairs with table will silently fail if there is any nil value, even if you check it conditionally

local a = { 0, nil, 1};
for i,v in ipairs(a) do 
    if v then print(v) end -- No 1 for you, poopoo
end
peak bay
#

hello lads, i have made a more occupations mod, i have done all the images, some of the ''coding'' but now i want to figure out how to test the mod? can someone help pls

shrewd sable
#

Place your mod folder in C:/User/Zomboid/Workshop and activate it on the PZ menu. I suggest to activate debug mode: right click on PZ on steam, launch properties "-debug" go!

peak bay
#

and it just says its missing mod.info file

#

can i dm someone and tell them of my situation ? its a bit silly lol

prisma gale
#

Create a file called mod.info in your mods main folder then open mod.info in your editor of choice and strucure it like that

sour island
#

Thermoregulator

verbal yew
#

or body part

sour island
#

The thermoregulator might be feeding the temp to the body damage

bronze yoke
#

this is literally necessary for the language to function, as otherwise ipairs would be an infinite loop as all unassigned keys are nil

dull moss
#

yo anyone knows where equip function located is (the one that fires when player equips an item, i want to catch which item player equips)? talking about hooking up to in-game triggers, something like this: (pic attached)
tried looking up in lua files, thought it's ISWorldObjectContextMenu.equip but doesnt look like it cuz this print ain't firing

local original_equip = ISWorldObjectContextMenu.equip
ISWorldObjectContextMenu.equip = function(playerObj, handItem, item, primary, twoHands)
    print("equipped an item");
    return original_equip(playerObj, handItem, item, primary, twoHands);
end```
mellow frigate
dull moss
#

only want specifically clothes

#

cheers

mellow frigate
# dull moss only want specifically clothes

another way could be to subscribe to OnClothingUpdated and parse all worn clothes. It may look like overkill but OnClothingUpdated is pretty consistently called by vanilla (even though some parameters would have been welcome, wink! wink!) and may handle cases that are not otherwise (like Java calls you cannot hook). Else, there is always the OnPlayerUpdate if your algo is lightweight.

astral dune
#

Been itching to get back to my vehicle mods, but I wonder: Has anyone found a workaround for the the vehicle java only using the vehicle's script engine power instead of the vehicle's instance engine power?
I had a couple ideas before I ran out of free time for modding, but I'm curious if its a solved issue now

modern hamlet
#

Hi I'm trying to get zombie's outfit/type/name that something special to a zombie. For example, if I added a new zombie, how can I find out if I hit this zombie when I hit it? Can someone help me?

local function onWeaponHitChar(attacker, target, weapon, damage)
    if not target:isZombie() then return end
    -- check zombie outfit?
    -- add pain
end
Events.OnWeaponHitCharacter.Add(onWeaponHitChar)
bronze yoke
#

zombie:getOutfitName()

weak sierra
#

is calling dressInPersistentOutfit from a client enough to make everyone see the outfit on a zed?
is calling it from the server enough?

#

the way my mod works it should get called on all clients and the server

#

atm

#

i dont have access to a decompile atm

#

so i cant check how it works

peak bay
#

could someone help me with an more occupations mod i am making?

#

i dont understand where the issue is, the occupations dont even want to show up

#

before, they did show up but they had UI_ prof _ xxx as names

#

so then i changed the translate file, made sure it would correctly show shit, and now im stuck? idk where to go from now

tough grotto
#

I really wanna learn this modding API, its just so confusing xD trying to make a woodland 3x3 cell map, and a collection of mods to allow for crafting essential materials like nails and stuff and basically creating a survival overhaul for PZ in preperation for agressive animals when the update drops. Ive made a few attempts at a map, kinda getting it, but idk where to even start with essentials crafting like a mod that lets you forage for "scrap metal" that you can then make metal stuff with or having seeds appear in foraging, or craftable clothes/guns/furniture etc and maybe even an ATV or somm

#

Idk it feels like this stuff should be simple but idk where to even start with the actual mods stuff

weak sierra
#

nothing is simple in PZ

#

abandon that idea immediately

#

recommend looking at mods that do similar things to what u want

#

study those

peak bay
#

hello, im trying to upload my mod but it gives me result 9 error?

#

its like file path is wrong or something, but i dont get it? i didnt change the file path at all

ivory gyro
#

Have an way with lua for send logs ?
To the server

lean reef
#

Posting half to show off my current progress and also because I'm wondering if there's a good way of drawing, like, a line between two points?

#

there's the debug LineDrawing class with the drawLine and drawArc functions but I dont know if those are only visible in debug mode

#

question aside, I'm really happy with how things are progressing! I've been working on this mod on and off for about a month now and I'm so excited that I have a working method of setting up the node structure

jolly goblet
#

Hi everyone! I need help with that.

random finch
#

Why do so many mods package ItemTweaker? Seems be asking for problems with so many versions floating around.

cosmic condor
#

it comes with instructions and people follow the trends

sour island
ivory gyro
#

Hi, I pay for someone repair an mod. Contact in private message.

nova socket
#

Can anyone tell me if I can override existing lua with sub-mod?
Aka I have a mod with distribution table, I want to create a patch mod that will replace the .lua from original one.

Will that work at all?

vernal island
#

Can someone recommend me a royalty-free audio databse site for mod usage? (DM me please, it may not be allowed to share such sites in this channel)

#

Btw, what does weapon's sound volume represent exactly? Does it effect how far one can hear other's gunshots?

verbal yew
nova socket
#

Because the only load order that mods have is through require chain.

#

My wild guess is that mod that requires other mod overwrites its content if overlaps?

verbal yew
nova socket
#

Oh so any subsequent mod is overwriting as I expected.

#

Thanks

quasi kernel
#

I can't help but keep finding myself back here time after time - even after burnouts.

#

Always neat to see what people are cooking up, plus it motivates me to actually work on my own stuff.

#

I've found myself wanting to make a tropical modpack but the lack of many sea-worthy mods makes it difficult - and that's where making your own mods comes in!1

abstract raptor
#

@fast galleon It was there this whole time, it just was "hidden", I unlocked it. You were correct that it's a tile property.

fast galleon
#

I'm not sure if you saw it but I added the IsoFlagType.water note right after I crossed out the IsoWater object.

#

it's what the water= is converted to.

abstract raptor
#

Do you think if I make a chair have water = true it'll make the chair water shaded?

abstract raptor
#

A: Only works for floor tiles, shader doesn't render ontop of the tile
B: If there's a floor tile there, you can't see it, but you can see the edges

#

c: Doesn't work inside for some reason

random finch
#

Is this still the case?

-- Steam cannot delete files from the upload/download process only update them.
-- Even verifying the cache will miss deleted files due to them not being on the manifest.

bronze yoke
#

never heard the second one, but the first one yes

#

the second one seems consistent with how verifying tends to work though

sour parcel
#

If I were to use an item version of a tile in a recipe, would I have to import the Moveable module, like how one must import the Base?
I'm looking to use Movables.trash_01_29 as one of the examples.

bronze yoke
#

you only need to import a module if you want to refer to it by its short type (e.g. trash_01_29 instead of Movables.trash_01_29)

#

personally i wouldn't

sour parcel
#

Alrighty, thank you.

#

Fingers crossed that I can make this thing work.

winged hollow
#

Been working on a simple mod, adds a drink. The textures for the drink are not showing up, it appears as a question mark in a bubble icon. Secondly it does not replace itself on use with the empty version of the item that I made. Anyone have any idea why this could be?

#

Thank you in advance

#

Best of luck to my fellow modders

bronze yoke
#

the most common reason for the icon not showing up is because of the Item_ prefix in the file name

#

this prefix is mandatory and automatically added

#

e.g. a texture Item_MyItem.png would be referenced as just MyItem in the script

#

i can't say what your issue is for sure without seeing anything but that one comes up here constantly

winged hollow
#

This is what I had last time I played and when I had the issues

#

This is how they are named in my files

#

This is the directory that it uses

#

Both textures are 32x32

#

Looking through another mods files I think perhaps the way it is written is entirely wrong

#

Sorry to bother, thank you for the help

median mantle
#

@winged hollow folder name typo : media\texture -> media\textures

winged hollow
#

I was really losing my hope

#

I did indeed change it, but something still must be wrong with my code

#

But thank you lots, I'm narrowing down what it could be

cursive fog
#

What's the best place to research PZ modding? Is there some kind of documentation?

cursive fog
cosmic iris
#

Has anyone made a mod for Rick's jacket from TWD?

azure rivet
#

Hi, how can I add 3 extra options to wear a clothing?
ClothingItemExtra = Type1, ClothingItemExtraOption = Wear_1, clothingExtraSubmenu = Wear_2,

drifting ore
#

is there any moders?im not. what if you guys add a new ocupation that its a pizza delivery.and you have orgnized runner and you know all the map.20 points?

winter bolt
lusty verge
#

Is there a tutorial for making traits?

#

Cuz I have 0 skill

pastel raptor
#

yo guys how can I get in touch with @heady crystal รจ_รฉ

verbal yew
#

@low yarrow If you set to spawn a zombie in ZombieZoneDefinitions.lua and it is a sex exclusive outfit (Male or Female only), You got to state it as such or else the game will try to spawn the other sex, realize that it doesn't exist, then choose to spawn a random outfit from its clothing.xml list.

open drum
#

Could someone help me why the code in the below does not work on MP? and only work in SP client side??

#

-- Define the luautils table locally
local luautils = {}

-- Define the stringStarts function
function luautils.stringStarts(str, start)
    return str:sub(1, #start) == start
end

-- Define a function to check if a proposed safe zone overlaps with a road
local function isSafeZoneOnRoad(x1, y1, x2, y2)
    for i = x1, x2 do
        for j = y1, y2 do
            local checkSquare = getCell():getGridSquare(i, j, 0)
            if checkSquare then
                for k = 1, checkSquare:getObjects():size() do
                    local obj = checkSquare:getObjects():get(k-1)
                    local oTN = obj:getTextureName()
                    if oTN ~= nil and luautils.stringStarts(oTN, "blends_street") then
                        return true
                    end
                end
            end
        end
    end
    return false
end


local function chk4item(player,item)
    local player = getPlayer()
    local inv = player:getInventory()
    
    if inv:contains("WURO_items.???") then
    return true 
    
    end
    
end
#
-- Function to create a safe zone of a given size
local function createSafeZone(worldobjects, square, playerss, size)
    local player = getPlayer()
    local inv = player:getInventory()
    
    local x1 = square:getX() - size / 2
    local y1 = square:getY() - size / 2
    local x2 = x1 + size
    local y2 = y1 + size

    if isSafeZoneOnRoad(x1, y1, x2, y2) then
        return
    end

    if chk4item() == true then
    SafeHouse.addSafeHouse(x1, y1, size, size, playerss:getUsername(), true)
    inv:RemoveOneOf("WURO_items.???")
    else
        player:Say("You don't have required item")
        return
    end
end

local function Context_safezone(player, context, worldobjects, test)
    local playerss = getSpecificPlayer(player)
    local square = clickedSquare
    local submenu2 = context:addOption(getText("Set Safehouse"), worldobjects, nil)

    local houselists = SafeHouse.getSafehouseList()
    for i=1,houselists:size() do
        if houselists:get(i-1):getOwner() == playerss:getUsername() then
            local toolTip = ISWorldObjectContextMenu.addToolTip();
            toolTip:setVisible(false);
            toolTip.description = getText("You can only own one Safe house");
            submenu2.notAvailable = true;
            submenu2.toolTip = toolTip;
            return
        end
    end

    local subMenu3 = ISContextMenu:getNew(context)
    context:addSubMenu(submenu2, subMenu3)
    for size = 5, 20, 5 do  -- Sizes from 5 to 20, in steps of 5
        local sizeKey = "Zone" .. size
        subMenu3:addOption(getText(sizeKey), worldobjects, createSafeZone, square, playerss, size)
    end
end

Events.OnFillWorldObjectContextMenu.Add(Context_safezone)
median mantle
#

@open drum try : SafeHouse.addSafeHouse(x1, y1, size, size, playerss:getUsername(), true) -> SafeHouse.addSafeHouse(x1, y1, size, size, playerss:getUsername(), false)

open drum
median mantle
#

Which part don't work on MP?

open drum
#

so basically it is o ly applied on my client temporarily

fast galleon
#

@median mantle
why are there so many trajectory mods? Is there a central GitHub for bugfix / improvements?

median mantle
#

@fast galleon Idk since I'm not the author of original Adv Trajectory mod.

fast galleon
#

But you have the best version, judging the comments.

verbal yew
median mantle
#

Thanks guys spiffo

modern hamlet
#

Is it possible to set a character to can't be knocked down without giving god mod?

pseudo apex
#

Hi! How can i change or add the stacking count of an item ? I created an item for my mod and I would like it to stack in groups of 10. ๐Ÿ˜„

bronze yoke
#

that's just not really a thing in zomboid

#

there are no stack limits, the inventory doesn't work like that

pseudo apex
#

works with weight?

random finch
#

To add clothing items to a vanilla outfit (or completely overwrite it), do you simply add the same vanilla guid to your clothing.xml?

random finch
#

Also, how does probability work in the case of subitems? I know it gives probability for the initial itemGUID, but how does it impact the subItems? Can you set a probability for each subItem?

<m_items>
            <probability>0.3</probability>
            <itemGUID>5fc22466-2942-4ba1-8c33-2a8528b73021</itemGUID>
            <subItems>
                <itemGUID>ce1a8520-7120-432e-8a3a-aa7b3094f0bb</itemGUID>
            </subItems>
            <subItems>
                <itemGUID>c7cc655b-284a-4087-85a6-d7c116385fb0</itemGUID>
            </subItems>
            <subItems>
                <itemGUID>0383956a-3fbd-4001-9749-69e2ba70b134</itemGUID>
            </subItems>
</m_items>
#

My assumption is that probability determines the chance for an item to be a slot in general then it rolls for the initial itemGUID and SubItems equally.

random finch
#

Attempting to overwrite a vanilla outfit breaks the outfit completely. Only the items you add work, even when leaving the entire outfit the same aside from the added items. Zed will spawn nude with only the new items.

There has to be another method todo this aside from overwriting the vanilla entry.

drifting ore
#

is it possible to change generator's efficiency?

random finch
#

Yes

drifting ore
#

Like, not from sandbox. i'm trying to make a custom generator with high efficiency

#

i'm trying to find the file where their fuel consumption is listed, but i'm having trouble

random finch
#

You want the fuel to last even longer?

winged hollow
winged hollow
#

The issue was embarrassing, because of this I will not specify what went wrong, but I really do appreciate the help I was given

drifting ore
#

Hello everyone, I faced an issue, when I'm trying to add new clothing Item and for some reason, It just shows this screenshot. I have no clue what in the hell I have to do to fix this issue. Also, the clothing item Itself doesn't appear on the character.

**Tags for future users with the same issue: ** Blank clothes ; Blank ; Clothes
Fix: Just checked the path in file "fileGUIDTable" and rewrote It to the proper one.

neon bronze
#

It means smtj is broken in your item script

drifting ore
random finch
#

What's up with proc distros having more than one entry for the same item?

    CampingStoreBackpacks = {
        rolls = 4,
        items = {
            "Bag_ALICEpack", 0.5,
            "Bag_ALICEpack", 0.5,
            "Bag_BigHikingBag", 2,
            "Bag_BigHikingBag", 2,
            "Bag_DuffelBag", 6,
            "Bag_DuffelBag", 6,
            "Bag_NormalHikingBag", 4,
            "Bag_NormalHikingBag", 4,
            "Bag_Schoolbag", 10,
            "Bag_Schoolbag", 10,
        },
#

When the loot for this proc spawns it rolls 4 times. So each roll the item that's chosen cannot be chosen in subsequent rolls?

drifting ore
covert carbon
#

I will learn two coding languages before I ever touch 3d modelling

#

Im scared of it

verbal yew
hollow current
#

what's the best way to transmit mod data from one client (player) to another? I was thinking about using a combination of server and client commands but can that even return values?

bronze yoke
#

you can't 'return' something with a command, you have to send a response command with the values to 'return'

#

lua being single-threaded, waiting for a command to return something would freeze the game for at least twice as long as your ping is ๐Ÿ˜…

hollow current
#

was hoping I could avoid the response command approach but guess it's the optimal way to go

#

thanks!

low yarrow
tiny wolf
# verbal yew yep, find adjuster into "zRe mod server"

Hey man ๐Ÿ™‚

With your adjust parameter, can't find a way to replace an object by another.
Can you send me an example where Base.Vest_BulletPolice will be replaced by Base.EFK_PACA please ? ๐Ÿ™‚ ๐Ÿ™

lusty marsh
#

what do you guys do to test your mods before updating them? Improved Hair Menu is up to almost 700K subs so I feel like I should be testing things first๐Ÿ˜†

#

I still have nightmares about that time I broke the whole main menudrunk

verbal yew
# tiny wolf Hey man ๐Ÿ™‚ With your adjust parameter, can't find a way to replace an object by...
local function zReAdjustItem(Name, Property, Value)
    local Item = ScriptManager.instance:getItem(Name)
    if Item then
        Item:DoParam(Property.." = "..Value)
    end
 end
zReAdjustItem("Base.Vest_BulletPolice", "ClothingItem", "Look ClothingItem in script EFK_PACA");
zReAdjustItem("Base.Vest_BulletPolice", "WorldStaticModel", "Look WorldStaticModel in script EFK_PACA");
zReAdjustItem("Base.Vest_BulletPolice", "Icon", "Look Icon in script EFK_PACA");
zReAdjustItem("Base.Vest_BulletPolice", "DisplayName", "Look DisplayName in script EFK_PACA");
tiny wolf
verbal yew
#

As for me, this is the most adequate way to replace body armor in zombie clothing presets

tiny wolf
#

Because i'm just discorvering that vanilla bullet vest have no weight ๐Ÿ˜ณ ๐Ÿ˜ฌ ๐Ÿ˜ฑ

hollow current
#
function testFunc(player, context, worldobjects)

    local playerObj = getSpecificPlayer(player)
    local clickedPlayer = nil;

    for _ ,v in ipairs(worldobjects) do
        if instanceof(v, "IsoPlayer") and (v ~= playerObj) then
            clickedPlayer = v;
        end
    end
end```

function is called ``OnFillWorldObjectContextMenu``, trying to add a context menu when you right click another player. There are no isoplayers at all being detected in worldobjects. Any idea why is that?
molten leaf
#

Hello... i dont know this is the right channel or not. but, i have question. is it possible to modding "loot respawn" sandbox option, so whenever its time to respawn, instead of respawn in the exact time it respawn in range between x to y day. thanks.

winged hollow
#

Blender is free so no need to worry about software to do it

#

Plenty of tutorials too

toxic scaffold
#

Hallo, I wrote a script for my server to Automatically restart every 2 Hours because I didn't like my providers solution. For some reason it doesn't seem to work or even show up in the console when I yeet it into the scripts folder. Anyone know why?
First time i try to do this btw

frank elbow
tardy wren
#
funcCache.ScriptItem = __classmetatables[Item.class].__index
#

Anybody know why this would ever return null form __classmetatables?

#

It works when I test it in singleplayer and multiplayer myself, but not on the test server

bronze yoke
#

does the test server use the same mods?

frank elbow
#

Are you testing it in isolation on the test server? & have you confirmed that the problem is that __classmetatables[Item.class] is nil?

tardy wren
#

The test server is stuffed with mods

bronze yoke
#

very specifically there are a couple mods that are known to overwrite Item

#

at which point Item.class is null and won't return anything in the classmetatables

tardy wren
#

... I did a folder-wide search and found only my mod do it

#

Well, access that class I mean

frank elbow
#

Folder-wide search for "Item.class", or "Item"?

tardy wren
#

Item.class

bronze yoke
#

look for Item

#

none of the offending mods were actually doing metatable stuff

tardy wren
#

and my folder, I mean my downloaded folder

#

...Huh

#

Match case and whole word only?

bronze yoke
#

yeah

#

the offending mods were using an item tweaking function which used a non-local Item to store the script item

tardy wren
#

I see

#

...Then maybe I can access the class in a different wat

#

...Oh you fucker Better Flashlight

#

from inside a local function

bronze yoke
#

if you can ensure your file runs first you can save Item to a local variable before they ruin things

nova socket
#

so what is the best way to instantiate an items such as VHS or CDs?

tardy wren
bronze yoke
#

_G["Item"] is the same thing as Item

tardy wren
#

So that's overwritten as well

bronze yoke
#

_G is just a way of explicitly referencing the global namespace

tardy wren
#

What if I try to access it with the full path?

nova socket
tardy wren
#

zombie.scripting.objects.Item

#

Uh, which Ryan do I poke for More Smokes issues

#

...Okay, somehow I managed to make the game have a stroke

#

Then It didn't happen

#

[07-10-23 19:49:17.052] LOG : General , 1696700957052> 0> STATE: exit zombie.gameStates.GameLoadingState.
[07-10-23 19:49:17.117] ERROR: General , 1696700957117> 0> ExceptionLogger.logException> Exception thrown java.lang.NullPointerException: Cannot invoke "zombie.core.textures.Texture.getWidth()" because "this.texture" is null at HUDButton.<init> line:94..
[07-10-23 19:49:17.117] ERROR: General , 1696700957117> 0> DebugLogStream.printException> Stack trace:.

sour parcel
#

Where do I put a test mod? (Specifically for the Steam Workshop.)

hollow current
sour parcel
#

Do I need to assign it the numbers like other workshop mods?

hollow current
#

No, a mod's workshop ID is automatically assigned to it when you publish it to the workshop

sour parcel
#

How do I test without publishing?

hollow current
sour parcel
#

Like so.

hollow current
# sour parcel Like so.
โ”œโ”€ testMod/
โ”‚  โ”œโ”€ preview.png
โ”‚  โ”œโ”€ Contents/
โ”‚  โ”‚  โ”œโ”€ mods/
โ”‚  โ”‚  โ”‚  โ”œโ”€ testMod/
โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ media/
โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ lua/
โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ client/
โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ yourScript.lua
โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ server/
โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ shared/
โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ mod.info
โ”‚  โ”‚  โ”‚  โ”‚  โ”œโ”€ poster.png
finite kettle
#

Hi, can someone explain me why player is always nil ?

worldly olive
#

Is your file running in the client folder or server/shared?

finite kettle
#

yeah if I try to mess things up on purpose the game lets me know

finite kettle
hollow current
#

What is not working exactly?

sour parcel
#

It's not showing up in any menu I can find for mods.

hollow current
sour parcel
#
name=transScribe
id=transScribe
description=This is an example mod containing two maps.
poster=poster.png
#

Not all has been alterd from the base template.

#

In facct.

#

I'll change description now.

hollow current
#

even yet, having written in mod.info, it should be appearing in your mods menu in-game. Assuming you did the file/folder structure correctly

sour parcel
#

I think I did.

#

Are there any naming conventions I should be aware of, because I've managed to mess everything up with stuff like that prior.

hollow current
sour parcel
#
|--Workshop
|  |--transScribe
|  |  |--preview.png
|  |  |--Contents
|  |  |  |--Mods
|  |  |  |  |--transScribe
|  |  |  |  |  |--poster.png
|  |  |  |  |  |--mod.info
|  |  |  |  |  |--media
|  |  |  |  |  |  |--scripts
|  |  |  |  |  |  |  |--transScribe.txt
hollow current
#

Looks correct to me

#

Something I just thought of. Can you go to the directory which mod.info is in, use details view, and check the type of the mod.info file?

#

It should display INFO file

#

if not, I'd assume its saved as a .txt extension file, and the name is just "mod.info"

sour parcel
#

Yeah, it's an info file.

hollow current
#

try to rename folder to mods

#

lowercase m

#

Though not sure if it matters

sour parcel
#

Sorry, that's my bad on spelling, it is undercase in my files.

hollow current
#

ah

sour parcel
#

It should load in with other mods you said?

hollow current
#

Yea it should be in the mods menu in-game

sour parcel
#

This one?

hollow current
#

yes

#

Does the ModTemplate appear in the mods menu?

sour parcel
#

It does.

#

And this menu shows only one's I'm working on, and doesn't show up.

hollow current
#

Well I'd just duplicate the ModTemplate folder and go from there

#

try to duplicate it, and change things slowly in it and see how the changes for it are reflected in-game. Probably start with changing the mod.info

sour parcel
#

Thank you.

hollow current
#

Sure!

sour parcel
#

:|

#

I just realised why.

#

Why does zoomboid have like, four different places to put in third-party content.

hollow current
sour parcel
#

There are now three different workshop ones I know of , and one mod one I can recall.

hollow current
#

that's weird

#

This is everything I have in my Zomboid folder. I use the Workshop one for mods i create

sour parcel
#

They're all in different directories, there the one where workshop stuff is actually downloaded too, one in users, and one that shops when you right-click browse files in steam.

hollow current
#

ahh

#

you only need to work with the one in users

sour parcel
#

That is where I went wrong.

hollow current
#

Well good thing you got it sorted out now!

sour parcel
#

It works now, thanks for the help.

hollow current
#

My pleasure!

queen yacht
#

Hi! How do I put my mod in the Steam Workshop nowadays?

queen yacht
# sour parcel

This workshop button doesnt appear for me, any ideas why? unhappy

queen yacht
#

yes

queen yacht
open drum
#

Guys hi hello

verbal yew
#

@median mantle hello friend, how about making the bullets fly out from where the muzzle flash is coming from?

#

like position for attachment muzzle

median mantle
verbal yew
median mantle
#

It just adds constant value to the player's current coords.
like, projectile initial pos X = player X + cos(player looking angle in rads) * 0.6

#
  • I think that it's not good to discuss something about my mod in here. So, if you have anything to ask me about my mod, plz DM.
verbal yew
#

but I can move them along their axes (XYZ)?

knotty solstice
#

hi

#

why doesnt this script work?
imports {
Base
},
recipe Make Wooden Nails
{
Plank=1
Result : NailsBox,
Time : 100.0,
}

#

i think it should work..

verbal yew
#
module Base
{
    recipe Make Wooden Nails
    {
        Plank=1,
        Result         : NailsBox,
        Time         : 100.0,
    }
}
verbal yew
fast galleon
open drum
#

could anyone direct me to a right path in allowing
players to make more than one safezone?
just like admins?
i made a mod that allows players set safezones anywhere they desire
but when they set more than one
everything except the first one they set are gone once they re login
i know multiple safezones r possible since admins can do it... but cant figure out how to unlimit the normal players..

narrow sparrow
#

I think we should have more npc mod or framework like pzns one's

#

since its stable and user friendly

verbal yew
#

and MP sync

#

yep yep

narrow sparrow
#

Not buggy like that of super survior

open drum
#

which npc mod is pzns??

finite kettle
#

is there a way to get the zombies in lua without relying on OnZombieUpdate?

drifting ore
#

is their a mod for deaf players... I want to know if theirs a house alarm or if zombies are attacking something

#

Like an Red ! Over the players head if they hear an House alarm like if they started it or not

muted garnet
verbal yew
#

^^'

marsh iron
#

Hello! I'm sorry to bother you guys--new to the server here (and also to modding!) If I wanted to add a custom sprite to cars, is there a way to accomplish that?

#

I have 16 years of Photoshop experience, but not so much Lua...

#

๐Ÿ‘‰ ๐Ÿ‘ˆ

#

Any advice would be much appreciated. And thank you!

queen yacht
#

Hello guys! I'm starting now and I'm a little lost, is there any newbie friendly tutorials on how to put my first map in a dedicated server me and my homies rented?

#

Every other mods seems to be working fine, but the the map I created doesn't. I can even spawn in the location where the buildings and everything else suposed to be but there nothing there but woods ๐Ÿ˜‚

#

Sorry for the really bad english

azure rivet
#

GD, I have a mod where I combine two bags to make one, but I have the problem that when I separate them, one of the bags has more space than it should since it is smaller.
I tried to make a script so that when the big bag has a weight greater than 5, I can't do the crafting to separate them, but I can't, can anyone help me on how I could do it? ๐Ÿฅฒ

drifting ore
#

so essientally i found a mod that has everything i want but missing one thing i was wondering if there's a crash course/ beginners guide because i'd like to add to the mod and want to use this an excuse to mod

#

so any tips for a beginner?

wooden roost
drifting ore
#

thank

haughty stream
#

Are there any medicine/dru-g overhaul mods?

I've found a lot of small, specific and focused mods but I'm looking for a full overhaul

blissful salmon
#

I try to add my own perk to the Survivalist group. Technically it works but when I host a game or using the my dedicated server I get the following error in the server console / log when I add XP to the perk.

self.character:getXp():AddXP(Perks.PrimitiveCrafting, calculatedXP)

-->

ERROR: General     , 1696789161083> 1,393,673,521> java.lang.NullPointerException: Cannot invoke "zombie.characters.skills.PerkFactory$Perk.getType()" because "<local6>" is null
ERROR: General     , 1696789161083> 1,393,673,521>      at zombie.characters.IsoGameCharacter$XP.AddXP(IsoGameCharacter.java:14848)
ERROR: General     , 1696789161083> 1,393,673,521>      at zombie.network.packets.AddXp.process(AddXp.java:52)
ERROR: General     , 1696789161083> 1,393,673,521>      at zombie.network.GameServer.receiveAddXp(GameServer.java:1276)
ERROR: General     , 1696789161083> 1,393,673,521>      at zombie.network.PacketTypes$PacketType.onServerPacket(PacketTypes.java:1022)
ERROR: General     , 1696789161083> 1,393,673,521>      at zombie.network.GameServer.mainLoopDealWithNetData(GameServer.java:1532)
ERROR: General     , 1696789161083> 1,393,673,521>      at zombie.network.GameServer.main(GameServer

I did several tests and it seems to happen when I use the "Survivalist" category but not when I create my own category. So when the perks.txt looks like below the error don't appear.

perk Primitive
{
    parent = None,
    translation = Primitive,
    passive = false,
    xp1 = 0,
...

perk PrimitiveCrafting
{
    parent = Primitive,
    name = PrimitiveCrafting,
    translation = PrimitiveCrafting,
    passive = false,
    xp1 = 50,
...

But what I wanted to do is:

perk PrimitiveCrafting
{
    parent = Survivalist,

The code seems to work even with the error on serverside (xp is added and the perk is shown under Survivalist).
Can I do something about the error? I don't know what I'm doing wrong...

wooden roost
blissful salmon
#

I want the Perk to appear along with Fishing, Trapping and Foraging in the Survivalist Group. So I assume the category exists. And like expected the Skill appears at the expected place but the server throws the error.

verbal yew
#

try check where it all start (use notepad and find this string in media/lua folder)

wooden roost
#

That string probably only exists in the locale tho

#

I would do what kERHUS said and go through the media folder looking for the group, you might be able to use the jdoc to help you as well https://zomboid-javadoc.com/41.78/

wooden roost
blissful salmon
# verbal yew exist like string for translate

I can find it in the translation files like I translate my perk/perk cat:
IGUI_perks_Survivalist = "๏ฟฝberlebenskunst",
So I assume "Survivalist" is correct. For tests I tripled the Skill and I can add them where I want.

I just get the error on server side when Hosting or use my dedicated server (every time I add xp; but it works). In solo I get no error message. So it's kind of strange. I couldn't find any categories in the code except in some comments where all perks are listed.

verbal yew
#

hmmm

#

can u send error log? paste from Error Magnifier

#

subscribe on it in workshop

blissful salmon
#

I have no GUI on server. So I think I can't use this. I just have the console on my dedicated server or the log files.

wooden roost
#

Have you tried setting the parent to IGUI_perks_Survivalist

verbal yew
#

didnt notice

#

error on java

#

local6 null

#

im not sure

#

but i think this should be string with type.
not passive = false
but type =

#

need stuff for getType from another existing vanilla perks and tostring it or print for look on it

verbal yew
#

its should be string

#

not sure if this affects anything
โ€‹

blissful salmon
#

in the perks.txt file? I add it and see what happens.

#

Wow, this fixed the error.
type = teststring,
But is this a bug? I didn't read anything about a needed type in the perks.txt.

verbal yew
#

perks factory trying call getType

#

getType is local6 and local6 is null

#

its your error

#

and it should be Type

#

as I say: not sure if this affects anything
โ€‹

blissful salmon
verbal yew
#

need a better modmaker than me, who can tell about java doc

blissful salmon
#

I'll check what other mods with custom perks have in perks.txt

verbal yew
#

try find here

blissful salmon
runic plover
#

Hey! What file/s would one need to tinker with to change how barricading with planks works? Just trying to make a simple thing that makes barricading require 4 nails per plank

blissful salmon
runic plover
#

In ISWorldObjectsContextMenu.lua I changed all instances of nails needed in barricading from 2 to 4, but that didn't seem to do anything. Will have to dive back in and see what's up

nova socket
#

@tame mulch Hi there, have a question around brush tool

        local props = ISMoveableSpriteProps.new(IsoObject.new(square, sprite):getSprite())
        props.rawWeight = 10
        props:placeMoveableInternal(square, InventoryItemFactory.CreateItem("Base.Plank"), sprite)

Is that viable in multiplayer (aka persistent)? Seen there are some transmit* commands in ISMoveableSpriteProps class.
My point is to create a fully intact sprite object (with all sprite properties) in multiplayer from a server side.

blissful salmon
runic plover
blissful salmon
runic plover
lean oasis
#

How possible is messing around with how health and the health ui, i want to make a mod that converts it to be a lot more like mechanics, where you can install and uninstall parts

frank elbow
#

For the more general โ€œhealthโ€ part, I guess it depends on the amount of control you need, since some stuff is hardcoded. Generally, though, that sounds like it'd be feasible

lean oasis
#

Hmm, thank you. Ill look more into it when i get home

chilly steppe
#

I had an idea for a mod, like an endgame mod, mainly that leads up to a server wipe where you have to find certain things in game (like keycards etc), go to a military facility, and use the items (as well as your weapons) to activate a nuclear device that would cause everyones screens to go white and kicks everyone until the server is wiped. Is this possible?

solid trench
#

Hey, ppl! How it's goin'?Spiggo

sour parcel
#

Can you use moveables in recipes?

#

Ex. trash_01_29

drifting bobcat
#

Hi! I'm new to modding and looking for guides and resources. I found this and thought I'd send update PRs as I learned stuff:
https://github.com/FWolfe/Zomboid-Modding-Guide

Thing is, the last update was about 10 months ago. Is this still relevant? Is there a better place to send contributions?

GitHub

Guide to modding various aspects of Project Zomboid - GitHub - FWolfe/Zomboid-Modding-Guide: Guide to modding various aspects of Project Zomboid

bronze yoke
#

it's still pretty reliable

#

the game itself hasn't been updated in ten months so i wouldn't worry too much about anything in it being outright outdated

drifting bobcat
plucky nova
#

guess i'll have to tweak the attachment points somehow

vernal island
#

is there a version/variant of Events.OnGameBoot that fires after lua files in server folder are loaded?

#

and whats the ideal event to load mod's sandbox vars?

nova socket
#

@drifting ore For the question about how to get rid of Destroy option with sledgehammer. There is a scripted answer for that

local function addContext(player, context, worldobjects, test)
  -- whatever you need, then this 
  context:removeOptionByName(getText("ContextMenu_Destroy"));
end
Events.OnFillWorldObjectContextMenu.Add(addContext);

Simply removes option from menu.

paper walrus
#

You should be able to crawl in Zomboid. If zombies can do it, you should be able to do it as well

lean oasis
manic relic
#

questions, is it possible to edit the colors of skill levels?

#

to idk red or something rather then yellow

manic relic
#

or how do I open a pack file

#

or the files in the texturepack folder

#

is there any specific tool for that?

bronze yoke
#

later events can be too late to change certain systems

vague hedge
#

What's going wrong? I have it typed the same as other mods that actually work.

#

Example of something that works.

#

Is it the spaces in the module name?

bronze yoke
#

it's probably the . in the module name

#

spaces do work iirc, though i would say they're probably bad practice

#

items/recipes/etc in modules are represented as Module.Name so having an extra . in there is going to confuse a lot of things

#

also comments should be marked like /* comment */, these /RECIPES/ comments are probably breaking it too

vague hedge
bronze yoke
#

you don't need the spaces

vague hedge
#

Ok

#

So looking at Hydrocraft's recipes, which is what I'm basing off of, do I need to have something besides just this:

.../media/scripts/Trading_Recipes.txt

#

Because all I have is the recipes file as I am not making new items

#

Also from what I have play tested, when I load up my mod and Hydrocraft/Tsar's Common Library 2.0, it breaks those two mods

bronze yoke
#

nah, just the one file should be good

vague hedge
#

Ok, next up..

#

Well now that I started PZ, it took away the logs, but I'll try to find it again

vague hedge
#

finding..

#

This

#

so I am trying to find out if the new hydrocraft changed the trading post name, but what I find curious is it stopped trying after going to the Heavy Vehicle parts. This was before I fixed the comments, so would that be why it gave up?

#

because I have more recipes after the heavy parts recipes

#

If anything, im gonna load up those 3 mods and see how it goes now

azure rivet
#

Hello, I'm trying to make zeds outfits for a mod but when I want to try it with the "spawn horde" from the debug but it appears without clothes, any advice?
Try this simple test but it doesn't work:
`<?xml version="1.0" encoding="utf-8"?>
<outfitManager>
<!--Test-->
<m_MaleOutfits>
<m_Name>AP_Test</m_Name>
<m_Guid>9377b3a8-5548-43be-8c34-5e2c69901128</m_Guid>
<m_Pants>false</m_Pants>
<m_AllowPantsHue>false</m_AllowPantsHue>

    <m_items> <!-- Hunting Vest Camo -->
        <itemGUID>c9381d1c-2d50-4bd0-9d38-076314141a34</itemGUID>
    </m_items>
    <m_items> <!-- Dog Tag -->    
        <itemGUID>88321000-2b08-4537-9c51-4b5eca360c92</itemGUID>
    </m_items>    
</m_MaleOutfits>

</outfitManager>`

bronze yoke
#

you either need to import it or reference it as Hydrocraft.HCTradingpost

vague hedge
bronze yoke
#

yeah

vague hedge
#

and Importing would look like this?

#

Ok, so game has loaded up, now I need to fix the import beccause it seems to break crafting

#

Searching through to see what went wrong..

drifting ore
#

how do i mod project zomboid i want to make an mod?

#

like to start off

#

its for an occupation mod

tough grotto
#

so ive got a good map that is functional and everything, im basically creating a full pure survival experience like the game "green hell" in preperation for wildlife in the next update, does anyone know the basics on adding custom recipes like being able to forage for "metal scraps" then using them to forge nails or being able to rip up plant fibers for rags?

#

i know how to add custom items i just dont know how to modify custom recipes

vague hedge
vague hedge