#mod_development

1 messages ยท Page 10 of 1

tranquil reef
#

Yes

#

Now you're thinking like a programmar

floral lodge
#

I thought you had to do the siui garbage, anything adding buttons like that that I've looked at uses it

radiant venture
#

Hmm it already has that custom context menu

quartz cave
#

here if you want to check "ItemZed" out, it made a lot of thing a lot easier but its no longer working ๐Ÿ˜ฆ
https://theindiestone.com/forums/index.php?/topic/21923-itemzed-updated-11b/

radiant venture
#

i really just see no issue here, but the game does apparently

tranquil reef
#

GoodHot, CustomEatSound, and the cooking stuff might be messed up or something

radiant venture
#

sooooo what i should do issssss?

tranquil reef
#

I'd try removing ReplaceOnUse and check if it works

radiant venture
#

alright

tranquil reef
#

I'm pretty confident in the theory that zomboid is sentient and purposely makes things difficult just to make people aggravated lol

radiant venture
#

i agree fully

quartz cave
#

yea sadly it feels like that

radiant venture
knotty saddle
#

Any mod that allows you to display items on walls? Seems it used to be a part of the More Builds mod, but that is no longer the case.

sour island
#

Weight = 1,7

#

@radiant venture

radiant venture
#

?

sour island
#

1.7 ?

#

Or does comma denote something else

radiant venture
#

OH

sour island
#

Also, if you check the console.txt in your cache folder it should be spitting out an error

tranquil reef
# sour island Weight = 1,7

If that's the reason I'm really mad, I planned on asking about it but I assumed I was just an idiot and it meant something lol

radiant venture
# radiant venture OH

I HATE BEING VISUALLY IMPARED
I HATE BEING VISUALLY IMPARED
I HATE BEING VISUALLY IMPARED
I HATE BEING VISUALLY IMPARED
I HATE BEING VISUALLY IMPAREDcold

sour island
#

afaik only , ; [] change behaviors in scripts

radiant venture
#

welp, fixed that tiny error, if i now start the game and EVERYTHING is fixed, i will be so goddamn pissed

sour island
#

. would only be used for numbers and item types

sour island
#

Worse when your "smart" IDE shifts the entire code about and deletes all the indents

cosmic condor
#

VS Code bro

sour island
#

VS doesn't do that or it does?

cosmic condor
#

It colors everything for me

#

easy to spot mistake

sour island
#

PZ scripts don't have a language to them though? Can VS be programed with it's own rules?

cosmic condor
quartz cave
#

i'm going to try this โค๏ธ

cosmic condor
#

it can help a lot in modding pz txt, everyone should install this plugin

sour island
#

I think intelliJ just has a built in text thing

radiant venture
#

Downloading it rn xd

cosmic condor
#

I'm not intelliJ user

sour island
#

I just never got around to setting it up

cosmic condor
#

too bundled for me

#

VS Code start up time is as fast as notepad

opal stag
#
function ombrophobiaTraitFunction()
  local player = getPlayer();
  
  player:getStats():setStress(player:getStats():getStress() + 0.07)
end

function ombrophobiaTraitInit()
  Events.OnRainStart(function() Events.EveryMinutes.Add(ombrophobiaTraitFunction)
  end)
  Events.OnRainStop(function()
    Events.EveryMinutes.Remove(ombrophobiaTraitFunction)
  end)
end
opal stag
thin hornet
# opal stag ```lua function ombrophobiaTraitFunction() local player = getPlayer(); ...
function ombrophobiaTraitFunction()
  local player = getPlayer();
  
  player:getStats():setStress(player:getStats():getStress() + 0.07)
end

local function onRainStart()
  Events.EveryMinutes.Add(ombrophobiaTraitFunction)
end

local function onRainStopStart()
  Events.EveryMinutes.Remove(ombrophobiaTraitFunction)
end

Events.OnRainStart.Add(onRainStart);
Events.OnRainStop.Add(onRainStopStart);
opal stag
#

Thanks

thin hornet
#

@opal stag
i suggest you do something like

function ombrophobiaTraitFunction()
  for i = 0, 3 do
    local player = getSpecificPlayer(i)
    if player then
      player:getStats():setStress(player:getStats():getStress() + 0.07)
    end
  end
end
#

also

#
player:getStats():setStress(player:getStats():getStress() + 0.07 * getGameTime():getMultiplier())

multiply by the game time multiplier, for fast forwarding

radiant venture
#

i don't understand

#

i'm so confused

drifting ore
#
getPlayer():getAlreadyReadBook():add(item:getFullName())

ERROR: General , 1660159937602> 0> ExceptionLogger.logException> Exception thrown se.krka.kahlua.vm.KahluaException: ForgetBook.lua:3: '=' expected near `function` at LexState.lexerror line:278.

#

Hey, i'm getting this error, and it refers to the code line above, how do i fix it?

#

i do not understand the error at all. very cryptic.

#
function Recipe.OnCreate.PerkMWP21()
local allItems = getScriptManager():getAllItems()
    for i=1, allItems:size() do
        local item = allItems:get(i-1)
        if item:getDisplayName() == "MetalPerk21" then
            if item:getTeachedRecipes() ~= nil then
                local TeachedRecipesSize = item:getTeachedRecipes():size()
                getPlayer():getAlreadyReadBook():add(item:getFullName())
                for i=1, TeachedRecipesSize do
                    local TeachedRecipesName = item:getTeachedRecipes():get(i-1)
                    getPlayer():getKnownRecipes():add(TeachedRecipesName)
                end
            end
        end
    end
    getPlayer():Say(getText("Improvised small gun frames learned!"))
    getScriptManager():getRecipe("Metalworking 3 - Scrap Armor"):setNeedToBeLearn(true)
end
#

This is the function

floral lodge
#

Konijima makes mods like we breathe

thin hornet
drifting ore
#

i think it was fixing another issue

#

should i get rid of global?

thin hornet
#

if you dont add local then its going to be global automatically

drifting ore
#

yeah but thats not really the issue it seems

#

when i run this mod, when joining the server, this mod causes a black screen

thin hornet
# drifting ore ```lua function Recipe.OnCreate.PerkMWP21() local allItems = getScriptManager():...
function Recipe.OnCreate.PerkMWP21(items, result, player)
    for i=1, items:size() do
        local item = items:get(i-1)
        if item:getDisplayName() == "MetalPerk21" then
            if item:getTeachedRecipes() ~= nil then
                local TeachedRecipesSize = item:getTeachedRecipes():size()
                player:getAlreadyReadBook():add(item:getFullName())
                for t=1, TeachedRecipesSize do
                    local TeachedRecipesName = item:getTeachedRecipes():get(t-1)
                    player:getKnownRecipes():add(TeachedRecipesName)
                end
            end
        end
    end
    player:Say(getText("Improvised small gun frames learned!"))
    getScriptManager():getRecipe("Metalworking 3 - Scrap Armor"):setNeedToBeLearn(true)
end
drifting ore
#

Oh and, it was originally recipes as well, but it didnt work

thin hornet
#

So you want to complete the recipe and learn a new recipe?

drifting ore
#

the idea is, you get two choices of "recipes", and you can only learn one, the other gets destroyed permanently and you cannot learn it, and because its not a recipe magazine or whatever

thin hornet
#

something like a branch

#

probably could use OnCanPerform instead to verify if the player chose a branch already

tranquil reef
#

Was it the weight thing?

radiant venture
#

I MOVED IT INTO A DIRECT COPY OF THE FILE AND NOW IT SUDDENLY WORKScold

tranquil reef
#

Oh, bruh lol

#

Now pray it stays that way

radiant venture
#

it better

floral lodge
#

I just installed the first Lua extension for vscode I could find and it's good

#

I wish there was something that showed the available functions for zomboid

opal stag
floral lodge
#

If there is something to show zomboid functions lmk cause life would be ez

thin hornet
#

@drifting ore

recipe choose branch A {
  ...
  OnCreate:Recipe.OnCreate.ChooseBranchA,
  OnCanPerform:Recipe.OnCanPerform.BranchNotChosen,
  ...
}

recipe choose branch B {
  ...
  OnCreate:Recipe.OnCreate.ChooseBranchB,
  OnCanPerform:Recipe.OnCanPerform.BranchNotChosen,
  ...
}
function Recipe.OnCreate.ChooseBranchA(items, result, player)
  -- set branch A as chosen
  player:getModData().ChosenBranch = "A"
end

function Recipe.OnCreate.ChooseBranchB(items, result, player)
  -- set branch B as chosen
  player:getModData().ChosenBranch = "B"
end

function Recipe.OnCanPerform.BranchNotChosen(recipe, player)
  -- return true if no branch choosen
  return not player:getModData().ChosenBranch;
end
drifting ore
opal stag
thin hornet
#

to make your mod splitscreen compatible you need to look through the 4 possible local player slots

floral lodge
#

But also a link to that guide would be great ๐Ÿ˜ฉ

drifting ore
#

yeah exactly! its quite useful especially if you want to dig into other peoples mods

#

one sec

opal stag
#

But mod with traits worked with getPlayer()

thin hornet
#

yeah but not sure that it really work with the additional splitscreen players if using getPlayer(), logically it doesnt

opal stag
#

I'll send thing from More traits mod what's working on split-screen

drifting ore
floral lodge
drifting ore
#

pz modding community be like

floral lodge
#

I think him to be a dev if not for the roles ๐Ÿ˜‚

floral lodge
#

Konijima irl:

thin hornet
#

Typescript powa

opal stag
#
function initToadTraitsItems(_player)
    local player = _player;
    local inv = player:getInventory();
    if player:HasTrait("preparedammo") then
        inv:addItemOnServer(inv:AddItems("Base.Bullets9mmBox", 3));
        inv:addItemOnServer(inv:AddItems("Base.ShotgunShellsBox", 2));
    end
end

Events.OnNewGame.Add(initToadTraitsItems);
radiant venture
#

hey konijima

drifting ore
#

pzpw is also very slick and useful tool if you have any experience in javascript

radiant venture
#

want a fun one to figure out?

floral lodge
radiant venture
thin hornet
#

Its not harder, its actually easier

#

But its beta so you may hit a problem here and there but that is how we can improve and fix it.

opal stag
radiant venture
floral lodge
#

@thin hornet checking it out when I get home

#

I'm totally down

#

And if it's good I'll start getting everyone else to use it :P

If you don't mind me asking, what do you do for work? Just curious cause you seem like you'd work for Google or something cause your kinda amazing

thin hornet
#

It clone the template and set it up for you, then you code in typescript and run compile commands to generate your mod into a lua version which is copied automatically into your Zomboid/mods directory

radiant venture
#

please konijima i've stared at this recipe code for like an hour now.

mystical coding god of the PZ chat answer me๐Ÿ˜‚

drifting ore
#

hi, non-coding god here, could i see the AluminumCanteenFull base item?

radiant venture
#

sure

thin hornet
#

the evolvedrecipe seems ok

radiant venture
# drifting ore hi, non-coding god here, could i see the AluminumCanteenFull base item?

item AluminumCanteenFull
{
DisplayName = Aluminum Canteen,
DisplayCategory = Water,
Type = Drainable,
Weight = 1.7,
Icon = AluminumCanteenFull,
CanStoreWater = TRUE,
FillFromDispenserSound = GetWaterFromDispenserPlasticMedium,
FillFromTapSound = GetWaterFromTapPlasticMedium,
IsWaterSource = TRUE,
ReplaceOnDeplete = AluminumCanteenEmpty,
ReplaceOnUseOn = WaterSource-AluminumCanteenFull,
IsCookable = TRUE
UseDelta = 0.0666666,
UseWhileEquipped = FALSE,
CustomEatSound = DrinkingFromBottlePlastic,
StaticModel = AluminumCanteenFull,
WorldStaticModel = AluminumCanteenFull,
}
enjoy my messy "this is my first mod" type coding

thin hornet
#

hum, UseDelta = 0.0666666, illuminati confirmed

drifting ore
#

all good hehe, i forget do you have to specify the module in evolvedrecipe like Base.AluminumCanteenFull?

radiant venture
#

uhhhhhhhhhhhhhhhhhh

#

yeah sure i'm gonna pretend i even know what you mean rn

quartz cave
floral lodge
#

Why does discord think the delta value is a phone number ๐Ÿค”

thin hornet
#

module MyModID
{
    imports {
      Base
    }

    /*************RECIPES*******************/

    evolvedrecipe HotDrinkCanteen
    {
        BaseItem:MyModID.AluminumCanteenFull,
        MaxItems:3,
        ResultItem:MyModID.HotDrinkCanteen,
        Cookable:true,
        AddIngredientIfCooked:true,
        AddIngredientSound:AddItemInBeverage,
        Name:Prepare Beverage in canteen,
        CanAddSpicesEmpty:true,
    }
}
floral lodge
#

What resources can we point Wou to for future reference?

#

Cause I too may need to make a recipe and I'd like to have them :D

drifting ore
#

and

#

scripts section of fwolfe details everything you need in your script .txt files, mrbounty has quite a few variables for making items

tranquil reef
#

How can I check if a tile is one of a specific name

thin hornet
opal stag
tranquil reef
thin hornet
#
local spriteName = isoObject:getSpriteName() or isoObject:getSprite():getName()
sour island
#

getSpriteName() isn't the same as getSprite() getName() ?

opal stag
#

I want to add a new "BIG" battery to the game, is there is a smart and easy way just like to create item with type "battery"

opal stag
radiant venture
thin hornet
#

should technically be the same but i supose it depend if the object sprite instance has instanciated

full vine
#

Could anyone tell what precisely does ToHitModifier on firearms?

floral lodge
#

We should totally have a setup guide channel in the server that clarifies how to start and how to find the functions you need, as well as suggesting konijima's decompilation guide

drifting ore
#

the decomp guide is actually huge. once you get used to searching through the source code it's pretty easy to find what you need

#

guys

#

I need help with modifying a mod

opal stag
#

Is there an easy way to add a BIG battery?

quartz cave
drifting ore
#

I am using this mod that textures mobs to be shadows, spawning with no hair or clothes, but for some reason it is broken and they spawn with underwear, even though it does have a fix

#

-- used to spawn underwear automatically on zeds
UnderwearDefinition = UnderwearDefinition or {};

-- base chance of having a special underwear spawning, don't want this too high as it adds new items on dead zeds everytime!
UnderwearDefinition.baseChance = 0;

-- outfit name

#

this is the code, anything we can add to fix it ?

opal stag
#

But I'm looking for easier way

#

I'm just lszy

#

I want to create electric katana

thin hornet
thin hornet
#

by big battery you dont mean the car battery right?

opal stag
#

right

#

it's small

#

But bigger than common

#

Like small accumulator for electric katana

drifting ore
#

at first glance a lot of the code for using batteries looks for Base.Battery explicitly. so it may be a bit harder than just adding a new item and setting it to drain less over time

thin hornet
#

Well if you make a bigger battery it doesnt have to work with other items that uses the regular battery

#

for example my flashlight only works with a single size of battery

opal stag
#

it's logical beacuse it's BIGGER

thin hornet
#

then just create a new battery item from the basic one

item BigBattery
{
    DisplayCategory = Electronics,
    Weight    =    0.1,
    Type    =    Drainable,
    UseDelta    =    0.000001,
    UseWhileEquipped    =    FALSE,
    DisplayName    =    BigBattery,
    Icon    =    BigBattery,
    MetalValue = 1,
    cantBeConsolided = TRUE,
    WorldStaticModel = BigBattery,
}
tranquil reef
#

is there a reason this isn't working? it does the "Outhouse Check" thing but can't figure out if the tile is actually one of the things

#
local outhouseTiles = {"fixtures_bathroom_02_24", "fixtures_bathroom_02_25", "fixtures_bathroom_02_26", "fixtures_bathroom_02_27", "fixtures_bathroom_02_04", "fixtures_bathroom_02_05", "fixtures_bathroom_02_14", "fixtures_bathroom_02_15"}```
drifting ore
thin hornet
#

youll need to make a model, sprite and add it to distribution

#

a recipe to add and remove the battery from your katana where you transfer the usedDelta

#

a katana without battery and a katana with battery item probably too, when you add/remove the battery you switch it and copy the condition, repair times and blood from one to the other to make it feel like its the same katana

opal stag
#

Ik, I just newbie in pz modding, but I know things I need to do

#

Ty again

thin hornet
#

now that i think about it, katana is a weapon so it cannot be a drainable type, youll probably have to mess around and store the power into the item modData and do some magic

opal stag
#

it will shock zombies, huh

quartz cave
#

yea, he should just use the battery as a ingredient for the weapon?

opal stag
#

So I think

thin hornet
#

ive done something like that with the chainsaw in Authentic Z

#

for the chainsaw fuel storage, had a Chainsaw and ChainsawOff item and when turning it on id run a OnTick event to consume fuel and stop it when fuel empty.

opal stag
drifting ore
#

gotta love playing with authenticz and random zombies, minding your own business when bob ross sprints up and one shots you

drifting ore
#

but others may have spawned too

#

what if you set UnderwearDefinition.Female_AnimalPrint.chanceToSpawn = 0? again i'm just kind of skimming here, but maybe the basechance is not counting towards those specific outfits further down?

#

uuh, I'll be straight with you chief I have no idea how to mod, I am just trying to fix this as much as I can

#

how would I go on to add that ?

#

just straight up copy it ?

#

hmm, is it a mod in the workshop? could you link it?

#

sure

#

cool, give me a few to look through the mod's code

#

sure, its pretty short

sour island
#

What do you guys think of my recoloring technqiues

#

Rather than simply slide around color adjustments I break the sprite down and choose color schemes that don't look god awful

#

also made male variants for nude mags

cosmic condor
#

how did you do that?

sour island
#

Photoshop

drifting ore
# drifting ore sure, its pretty short

here's what I would add to test if that's the issue.

UnderwearDefinition.Female_AnimalPrint = UnderwearDefinition.Female_AnimalPrint or {}
UnderwearDefinition.Female_AnimalPrint.chanceToSpawn = 0

paste that at the bottom of NoUnderwearDefinition.lua and test in single player to see if animal print underwear shows up. if it doesn't i'd communicate that info to the mod author since he'll have to update the mod for everyone on your server to have the changes

sour island
#

mostly just copy and pasting the sprite and selecting out parts

cosmic condor
#

I mean, it's very small pixel, yet you can manage to recolor different part

sour island
#

imo Recoloring the whole thing looks bad - so I had to select out the title vs person / hair

thin hornet
drifting ore
#

also where is the lua file for the underwear definition located ? so I can try to add more

sour island
#

The mod uses IRL magazine tiltes

#

some are more fun that others

drifting ore
#

the art is very well done. hard to make something easy to recognize at that size hehe

sour island
#

I used the vanilla one as a base

drifting ore
#

found it no worries, thanks!

sour island
#

Top left is the vanilla icon's color scheme through my layering

drifting ore
#

hell yeah, good luck my man

sour island
#

also did magazines a while back

cosmic condor
#

which tool did you use to separate each layer?

sour island
#

my hands lmao

cosmic condor
#

graphic tablet?

sour island
rocky yarrow
#

Is there a way to reload the lua files while in game so that it adds up the new lua files ?

sour island
#

I used the select tool - set contiguous to grab everything that's the same color OR go in by hand

drifting ore
#

writing code is one thing but making pixels not look like hot garbage? true black magic

sour island
#

Fortunately not my own art - actually making it would take forever, messing with colors is easier

cosmic condor
#

pure dedication to details

sour island
#

Well there's an adjustment tool

#

I can adjust the entire sprite but it looks like hot garbage

drifting ore
#

UnderwearDefinition.FrillyBlack = UnderwearDefinition.FrillyBlack or {}
UnderwearDefinition.FrillyBlack.chanceToSpawn = 0

UnderwearDefinition.Female_FrillyRed.UnderwearDefinition.Female_FrillyRed or {}
UnderwearDefinition.Female_FrillyRed.ch = 0

sour island
#

that's why I thought up the idea to only adjust selections instead

drifting ore
#

if I kept adding it like this, it'd work right ?

cosmic condor
#

I always use Hue/Saturation tool ๐Ÿ˜†

drifting ore
drifting ore
#

look ma I'm coding

#

๐Ÿ˜„

#

hackerman

#

lol

sour island
#

Glad I was able to impress you haha

lusty nebula
sour island
#

HottieZ is a vanilla item lol

#

Not translated in a few languages too

cosmic condor
#

Untranslatable

sour island
#

There's a few tho

lusty nebula
#

Ok, so now it seems a good time for a Viagra pills mod too LOOL ๐Ÿ˜„

cosmic condor
#

American centric you say

sour island
#

I changed the translation to Nude Magazine

#

namedLit.NUDIEMAGS = {
|| F = { "Adam Film World", "Adam Film World Guide", "Barely Legal", "Hustler Magazine", "Beaver Hunt", "Celebrity Skin", "Chic", "Gallery", "Genesis", "Gent", "High Society", "Hustler", "Juggs", "Leg Show", "Modern Man", "Oui", "Penthouse Forum", "Perfect 10", "Playboy", "Score", "SCREW", "Swank", "On Our Backs",},
M = { "Playgirl", "Viva", "Black Inches", "Blueboy", "Bound & Gagged", "Drum", "Freshmen", "Honcho", "Mandate", "Manshots", "Playguy",},||
}

lusty nebula
#

Probably was better soft porn magazine LOOL ๐Ÿ˜„

full vine
#

Oui

๐Ÿ‘

cosmic condor
#

Si

sour island
#

๐Ÿคท I think these are pretty PG puns

#

also IRL magazines

#

'bound and gagged' is the special one with it's own icon

cosmic condor
#

Did you see those sweets that they recently added? I have never heard of more than half of them.

#

Plonkies, SnoGlobe, QuaggaCakes

sour island
#

Those are puns made by the devs

cosmic condor
#

yes

full vine
sour island
#

Quagga are Jaffacakes

cosmic condor
#

Isn't it this one?

sour island
#

Not sure what the pun is going for

#

Might just be gibberish

cosmic condor
#

now you missed the joke too ๐Ÿ˜†

sour island
#

oh

#

then it is a zebra cake

full vine
#

๐Ÿ˜ฎ

sour island
#

plonkie = twinkie

cosmic condor
#

yes, this one is funny in English

full vine
#

as a non-US/UK resident the pun is totally missed on me, sadly. by the way! what we had in early 90s were snickers mars bounty etc. i wonder why they aren't in the game then

sour island
sour island
cosmic condor
#

American Centric strikes again

lusty nebula
#

I can't understand how people eating those things can be still alive LOOL ๐Ÿ˜„

full vine
sour island
#

no clue

full vine
#

like more bars aside granola bars

sour island
#

maybe not that one

#

lmao

#

instant sniped

cosmic condor
full vine
sour island
#

Gigglers could be Snickers'

#

or could just say candy bar

full vine
#

guess Mars isn't going to be Uranus, need something more okay. Jupiter would work, Phaeton maybe

sour island
#

and not get too crazy

#

Ares

#

flip it to Greek

full vine
#

Bounty => Delight

sour island
#

Ares A&As

calm depot
#

And I'm back

lusty nebula
#

the only real foods of the true survivor are spaghetti and pizza ๐Ÿ˜„

cosmic condor
#

Uranus is HUGE

calm depot
#

This discord appears to suffer from the Scunthorpe problem ๐Ÿ˜‚

full vine
#

what would you say about the weapon mods for PZ aside Brita (which i guess is its own thing entirely) that would extend vanilla firearms in the most natural way in terms of "feels"?

lusty nebula
#

Otherwise you can expand to Bear Grills bars...Cockroaches in hot sauce, Locust bars, Ant powder ๐Ÿ˜„

sour island
full vine
lusty nebula
#

Do you think we will see NPC's before getting elderly? ๐Ÿ˜„

cosmic condor
#

depends on how old are you

drifting ore
#

u guys aren't elderly? ๐Ÿธ

full vine
drifting ore
#

i would play that

cosmic condor
#

I'm not ready for NPC yet. There are a lot of mod ideas that I want to complete before jumping to NPC modding

drifting ore
#

here's a general question, would you rather have exercise fatigue be shorter or have a lesser effect on movement/etc?

full vine
# sour island Firearms B41 adds like 10 guns afaik and is balanced

been trying to play it and read the code of things, and it has MP5 being worse than a Glock in terms of hit and crit chance etc. While I would agree that it is natural in terms of extending vanilla state of assault rifles (or automatic weapons in general) vs pistols, I'm kinda meh-feeled about MP5 being worse than a Glock :S

unique trail
#

Anyone knows what is the difference between Distributions.lua and ProceduralDistributions.lua?

lusty nebula
drifting ore
full vine
cosmic condor
unique trail
cosmic condor
#

check the names of containers in Distributions.lua

drifting ore
unique trail
#

But modded files look like this..

lusty nebula
#

Btw..I dunno you but I'm getting crazy with the thing of the sync saves that can't be removed...

unique trail
#

Should I go with the second approach?

full vine
# drifting ore here's a general question, would you rather have exercise fatigue be shorter or ...

I think it would be cool to implement adrenaline mechanics. Like if you're exercise-exhausted, you need to spend X amount of time, something around overnight, to clear 80-90% of exhaustion, reducing penalties to your swing time and damage. However when at that point, when you start swinging a melee weapon once still exhausted, you get a short burst of dmg and general "agility" and pain resistance after first couple of swings for some time, and then get more exhaustion on the body parts that were involved in exercise/swinging

drifting ore
#

that would be really cool!

cosmic condor
full vine
#

I think one of the "more traits"-category mods made something like that but I'm not sure. Guess gotta check it out

drifting ore
#

my first mod is a pharmaceutical mod. i'm trying to make an anti-inflammatory type pill that gives minor pain relief but also makes you less stiff if you've been working out

unique trail
#

Is it easier? Idk... I like the first approach more... But i guess im different

#

Im just not sure if that wouldnt break something

#

as all modders do it different way

cosmic condor
unique trail
#

Im confused xD

cosmic condor
full vine
unique trail
#

But in Distributions.lua there are also a lot of different containers etc..

#

So im confused do they hold different containers or are they the same ?

#

Oh wait I think I know

#

Procedural holds the distributions for the rooms

#

different rooms

#

and Distributins just the containers

#

no?

drifting ore
cosmic condor
# unique trail But in Distributions.lua there are also a lot of different containers etc..
#

this has been shared many time ๐Ÿ˜†

full vine
sour island
#

Delays the debuffs until after you're no longer in panic.

#

Unless you're absolutely exhausted

drifting ore
#

dissolvable tablets definitely has to be a thing. looks like i have a lot to work on lol

full vine
sour island
#

I hope with the new liquids overhaul we get more dynamic recipes

drifting ore
#

the liquid mixing looks so cool

sour island
#

Kind of hate to see all the types of bottles X all the types of liquids in recipes

full vine
#

@drifting ore yeah looks like the adrenaline mod actually does the adrenaline thing. who knew

unique trail
drifting ore
#

it's a very cool mod. i don't play with it often though because i love to cheese adrenaline junkie with cowardly and agoraphobic

cosmic condor
fast laurel
#

I want to make a mod that literally changes the value of one setting to 0 that isn't usually open to being changed. All the guides for mods are way complicated beyond my need for that. Any advice? I just want the "incremental loss of effectiveness from vehicle repair" to be disabled / set to 0.

#

I think it would be a popular mod. Lol

full vine
#

ah, forgot to add -- spawned into louisville of course. fun fun

drifting ore
#

more traits is great for high power gameplay, i can take so many negative traits that i can do adrenaline junkie, 3 nimble, 9 fitness and strength, keen hearing, and blunt skill. basically set if you can last the first 2 days

full vine
#

yep, kinda that. like watching a tv show about horrible stories of failing attempts to escape whatever until on 11th episode you finally make it

bright wolf
#

battering ram go brrrrrrrrrrrrrrrrrrr

full vine
#

you finally make it
only to die in a bit because you saw that survivor zombie with a backpack but only had a frying pan but decided to try anyway, or wandered too courageously into darkness which you set to more dark in sandbox settings beforehand heh

lusty nebula
#

Now with 41.73 they added the chance to call this for help if needed and if you are only equipped with a frying pan LOOL ๐Ÿ˜„

floral lodge
#

need to call a function from this file in the file it's pointing to please help

full vine
floral lodge
#

can I not open chat in singeplayer??

#

My mod has commands people need to be able to call

#

:/

thin hornet
floral lodge
#

that makes sense

#

what about singleplayer not having chat?

thin hornet
floral lodge
#

thanks a ton, again, konijima โค๏ธ

#
    if module ~= "MultiplayerTimeSkip" then return; end
    if string.lower(command) == "enable" then
        Enabled = true
        print("MultiplayerTimeSkip Enabled!")
    else if string.lower(command)  == "disable" then
        Enabled = false
        print("MultiplayerTimeSkip Disabled!")
    else 
        print("Please enter enable or disable to enable or sidable the mod!")
    end
    end
  end

Events.OnServerCommand.Add(OnServerCommand)

should doing /MultiPlayerTimeSkip enable in the server chat not work?

thin hornet
#

no idea what you mean here

floral lodge
#

like

#

how do I call the command

#

from inside the server, it keeps saying command not recognized

#

I don't know the syntax

thin hornet
#
--- send client command to the server
sendClientCommand(module, command, args)
--- send server command to all player
sendServerCommand(module, command, args)

--- send server command to a specific player
sendServerCommand(module, command, player, args)
#

sending a chat command is something else completly

#

technically not doable in vanilla without hooking ISChat and doing some magik

floral lodge
#

awww what

#

then what do these do

thin hornet
#

you would use theses to send network command between client and server

#

chat commands are not Command like this

#

they are java sided too

floral lodge
#

looool I been doing the wrong thing the whole time

thin hornet
#

you can hook into ISChat:onCommandEntered() and check what the chat is sending and send your network command there

floral lodge
#

uhhh

#

I might try that later :P

#

me and my friend about to try out what I have for now!

#

the command was just to disable it when we want

#

but for now we leave it enabled

thin hornet
#

you can use keybind or stuff like that

floral lodge
#

true

thin hornet
#

keybind, open a custom UI and have a button to toggle stuff

floral lodge
#

I haven't done ui stuff yet cause it looked hard

#

will look into it, might migrate my mod to your typescript thing

thin hornet
#

using typescript will help alot for detecting errors such has invalid type usages etc

#

but might be complicated at first if you have zero knowledge of javascript or typescript

floral lodge
#

i've done javascript

#

unfortunately I hated it

#

:)

#

We'll see though

drifting ore
#

the best way i can describe how typescript will help is through an example. let's say you have a function myZomboidFunc(player, item, time) that you want to call, so you pass it a player, an item, and a length of time. you get an error. with typescript you'd be able to tell that player is actually supposed to be a number, not a player object.

#

that's an error that i encountered and was able to debug using pzpw

floral lodge
#

that sounds real nice

thin hornet
#

re-writting WaterDispenser and FuelAPI into typescript atm

#

this will give a couple example to see what you can do with this system

floral lodge
#

oh sweet!

cyan basalt
#

is PipeWrench what you are referring to when you mention writing it in Typescript? That sounds way more natural than writing lua to me

thin hornet
#

and yeah writing js/ts is alot more cleaner than lua especially if you are a oop programmer

#

it look like java and C# to me

cyan basalt
#

awesome! I write lots of oop code for work so lua was kinda weird but I'm sure I'd get used to it

#

Typescript definitely sounds nicer tho :)

cyan basalt
#

so when it says: A Java-based transpiler (source-to-source compiler) that converts exposed API from the core of Project Zomboid to TypeScript declarations, mapping the API in a digestable way for IDE software to intelligently forward to programmers when programming their mods. that just means that the ide will have the api methods exposed and not give warnings is that correct? it's not actually decompiling the java -- right?

thin hornet
#

i had that class in lua but really look messy in lua and gets harder as the class grow bigger

cyan basalt
#

or it's just transpiling it into typescript defs

#

awesome thank you! I'll star that and take a look

#

ooo i think it's private im gettin a 404

thin hornet
#

its doesnt decompile java

cyan basalt
#

gotcha

thin hornet
#

we offer typing definition of the java and lua side

#

then you have all of it available in your typescript, and it transpile your ts into .lua

#

my system named pzpw has a pzpw-config.json which contains the info for each mods and workshop so that it compile your project and move it directly into Zomboid/mods and Zomboid/workshop

cyan basalt
thin hornet
#

yeah

#

pzpw is a node cli you install globally

cyan basalt
#

gotcha that makes sense

thin hornet
#

its uses pzpw-template when creating a new mod

cyan basalt
#

does the node version matter?

thin hornet
#

PipeWrench has two branch, stable and unstable so you can easily work on the unstable branch of pz when updating your mods

cyan basalt
#

ahhh i see

thin hornet
#

i suggest the lts version but i didnt test with the other one

thin hornet
#

oh damn lol brb

#

should be good

cyan basalt
#

yup it's good now

thin hornet
#

so the assets/ dir contains everything like models, textures etc and the src/ contains your mods .ts files

#

everything is stiched together at compile time and moved to your game cachedir

cyan basalt
#

gotchaaa and then you just compile it using your tool and it copies the lua scripts/assets to mods/workshop?

#

that's pretty neato nice work

thin hornet
#

yeah depending what compile command you choose

cyan basalt
#

gotcha

thin hornet
#

compile-distribution just copy the mods into Zomboid/mods

#

compile-workshop generate everything and move it Zomboid/workshop ready to be uploaded through the game UI

cyan basalt
#

and as a newbie: copying into workshop is what you want to do when you're ready to upload to the workshop? is that the case

#

ah ok you already answered it haha

thin hornet
#

haha yeah

cyan basalt
#

so is WaterDispenser a mod that you wrote in lua and are rewriting using typescript?

thin hornet
cyan basalt
#

ty!

#

and i answered my own question

#

i appreciate the assistance! I'll let you know if I make any progress with it ๐Ÿ˜

thin hornet
#

sure for any question im here

cyan basalt
#

awesome thanks!

#

since the general pipeline seems that you just add lua scripts/assets to media/shared/client/server, does this mean that java mods aren't available to be installed through the workshop? Or are there some out there

#

I'd be interested to take a look at them and see how they handle it

thin hornet
#

java mods are not upload-able to the workshop.
but you can have a link in the description and instruction how to install it tho
usually java mods are for server side only as that doesnt require clients to install anything

viral notch
#

Konijima? how big knowledge you have about change seat mechanics and UI side ?

thin hornet
viral notch
cyan basalt
cyan basalt
#

awesome thank you!

thin hornet
viral notch
thin hornet
#

do you have a git repo with your project?

viral notch
#

the square is when there is no vehicle UI
but there is just idk how to make it works

viral notch
#

nope dont use it

thin hornet
#

well you can DM and show me some code so that i can help you

heavy iris
#

Hey there, am I doing something wrong with basemod's client/server commands?

--- Clientside
local Client = require 'Client';
function Client.Commands.getWarned()
    local emitter = getWorld():getFreeEmitter();
    if emitter then
        emitter:setPos(5261, 7934, 3);
        local audio = emitter:playSoundImpl("MysteriousFireAlarm", false, nil);
    end
end``` 

```lua 
---Serverside
local a = require b
local Server = a.system
Server.SendCommand("getWarned",{})```
thin hornet
heavy iris
#

not here, its the big template folder I work on

#

I have frameworks, all of them call System = Server or Client, and store it in framework.System

#

should not cause any trouble right?

thin hornet
#

if any mod has a lua/client/Client.lua and load after yours it will overwrite your file

heavy iris
#

of course

#

but i'm testing my mod alone here

#

(I'll take care of that later, you're right)

fierce bluff
#

Guys, does anybody know if it's possible to scale down the player inside a car?

craggy furnace
#

nope

#

you either make the car larger or manually adjust the animation

#

otherwise ๐Ÿคทโ€โ™‚๏ธ

heavy iris
#

is that not working in single player?

local function pys()
    if isClient() then return("ClientEvents") else return("ServerEvents") end
end
tranquil reef
#

I've asked this before but nobody answered, is it possible to make the "Grab" function not show for item world models?

#

If not I can just automatically drop it whenever you pick it up, but it'd be easier to just make it not possible in the first place lol

winter thunder
#

@tranquil reef you could technically make the item impossibly heavy, that way the player could technically never pick it up as it would exceed all character weight limits

#

Just a thought, bc I have no clue otherwise

tranquil reef
winter thunder
#

Ah ๐Ÿ˜‚ understandable

tranquil reef
#

It's supposed to look like a water puddle, so opening the floor inventory and hovering to see that it weighs like 5000 kilograms is pretty strange LUL

unique trail
tranquil reef
unique trail
#

Well quickly thinking about it.. You need to make an if condition which is going to determine when not to show the option, and probably do that inside "OnPreFillWorldObjectContextMenu" event

#

there is also a guide somewhere on how to operate tables..

#

I know how to insert stuff into the context menu, but never though about removing... It might be simple but im not certain at the moment

cyan basalt
#

I noticed in the files that there is a car that's rigged and has anims, is this something that's only accessible with mods currently? I haven't noticed it in my vanilla run yet. I know in some of the vehicle mods you can open the hood and stuff

winter bolt
#

i think thats a test thing since i dont think theyve gotten around to adding it to all of the vanilla vehicles

#

i know they plan to at some point but its probably not a big priority

cyan basalt
#

ahhh gotcha that makes sense

drifting ore
#

i have an item that is set to drainable and has a usedelta. is there anything else i need to do to have it consume part of the item?

drifting ore
#

ayyy i figured it out. for anyone else you gotta do item.Use(). it threw me off because it doesn't come from InventoryItem, it comes from DrainableComboItem. so there ya go ^^

shadow geyser
# tranquil reef I've asked this before but nobody answered, is it possible to make the "Grab" fu...

yeah you can. you can have to modify the following function "ISInventoryPaneContextMenu.doGrabMenu(...)" in ISInventoryPaneContextMenu.lua, to not add the option when the item is the item you don't want moved. Then do the same thing to ISWorldObjectContextMenu.handleGrabWorldItem(...) in ISWorldObjectContextMenu.lua. thats probably the easier way. But I think the safer way would be to modify the context menus afterwards in OnFillWorldObjectContextMenu and OnFillInventoryObjectContextMenu as that way you won't be modifying vanilla code, and you are less likely to get issues with conflicts

#

to remove the context menu through the event, you would want to use setVisible(false) to make it not visible which will "remove" the grab option

tranquil reef
#

What line of code would actually get the specific grab menu of an item

shut ember
#

Does sendServerCommand not work when not using a dedicated server?

#

Because my client doesn't seem to be receiving any commands, or atleast the Events.OnServerCommand isn't being updated

shadow geyser
#

the grabOption is adding the option for the grab, the submenu is creating the submenu context menu, and that last line, associates the submenu with the grabOption so that it shows up next to it, when you hover over the grabOption

blazing vine
#

How do makes clothes that are wearable to one sex? Like I want to make a female only item and I dont want to make a male one how do I prevent people from wearing it. Or do I have to spend more time making both versions?

cosmic condor
#

I mean, men can wear bras and all

blazing vine
#

Yeah but I made so many clothes just for girls I really dont want to spend like 100 hours redoing everything

cosmic condor
#

Have you check if it's looking good on men?

blazing vine
#

Yeah, it doesnt look good because I used the female model. so it looks dumb on guys

cosmic condor
#

I'm not sure if it's possible to limit

blazing vine
#

well I guess they can be punished by manmade horrors of extreme clipping

#

if they really want it

sterile mirage
#

Looking for someone to help with modding my own personal multiplayer server.

shadow geyser
# blazing vine How do makes clothes that are wearable to one sex? Like I want to make a female ...

I can't see any option for the clothing to do it in an easier way, but you could do the same thing that I was mentioning to monkeyshark by modifying the context menu to remove those options. you would need to modify doContextualDblClick in ISinventorypane to stop the double click from equipting, then removing the options in the dowearclothingmenu call to not add the option when the item in question is your clothing. again the best way to do this would be to hide the context menus using the onfillcontextmenu call rather than modifying the vanilla code.

cosmic condor
#

Is there any sample mod that allows only one sex to wear its clothing?

shadow geyser
#

also it comes to mind that since you can highlight multiple items and tell the character to equip it, that in that case the context menu stuff won't be able to prevent that. but you can probably prevent that by modifying the isValid() for the ISWearClothing timed action, to make wearing that female clothing invalid when you are male which should stop the action from happening. I can't quite remember whether or not that would cancel the rest of the queued timed actions though, or if it will just skip to the next

jagged ingot
#

Hmm.

shadow geyser
#

if you end up modifying the isValid(), I suggest you monkey patch it instead of straight modifying it, as it will have less conflicts if other people are also monkey patching.


local old_isValid = ISWearClothing.isValid;
function ISWearClothing:isValid(recipe)
    -- Do all of original isValid stuff, then add in our custom stuff 
    if old_isValid(self, recipe) then
        blah blah blah your custom checks
    else
        return false
    end
jagged ingot
#

Mixins would be fun.

#

Chaining function calls is so funny.

#

Could have three mods or some amount leeching off of a render function lol

#

Modding be like

#

Get me a Spiffo variant of that and It'll be gold.

cyan basalt
#

i overthink so much i don't even know where to start

#

ask me why i've decompiled the source code and set up multiple projects but haven't started ๐Ÿคฆโ€โ™‚๏ธ

drifting ore
calm depot
#

If it's one of your items and gender is wrong, return false, otherwise, return result of original function

cosmic condor
#

I would like to study the code, if there are any mods that use the function for this purpose

vale plank
#

does anyone know of a good texturing tutorial? i'm wanting to try my hand at a basic clothing mod (just retextured skinny jeans to be a classic grunge plaid instead) but i can't find any good guides on how to retexture something while keeping it in line with the game's style

winter bolt
#

if you can get one of the textures in black and white you can pretty much just use it for the shadows so you can add in other details yourself without needing to worry about them

vale plank
#

gotcha! i'm actually using your mod for a lot of cross-referencing so tysm :)

winter bolt
#

nice lol

#

most of my recent items i textured from scratch but i have no idea how to explain that whole process

#

when you add details and stuff to the texture you're making i'd recommend making it all in black and white so you can add colour and other stuff later to make it easier

cosmic condor
#

If you want to be more precise, you may need to use Blender for texture painting, vanilla UV map is hell

winter bolt
#

oh yeah i made a shadow template for most of the body that you can use

#

i completely forgot i made this

#

its not perfect but it should be good enough

hearty gulch
#

Is it possible to adjust the starting durability from another mods items that are spawned in?

eternal garnet
#

I have a "Custom Occupations" mod, and for all of my items I have the code:

inventory:AddItem("ItemName")

For some reason however the item, "Base.DigitalWatch2" for some reason will not spawn, despite this being it's ID.

I have tried spawning said item with just "Base.DigitalWatch2", but that has not worked either.

Has anyone else had issues with this item?

shadow geyser
hearty gulch
winter bolt
#

you can have it be in a separate mod, as long as its loaded after the original mod

#

and then in the lua file you can add

if getActivatedMods():contains("ORIGINALMODID") then 
CODE HERE    
end
shadow geyser
#

you could instead add the call into the the OnGameStart event, which will make sure it gets loaded after all the scripts are loaded. I can't actually remember rn when in the order all the item script files are read in comparison to the other mod files

twin basalt
#

Does anyone know if its possible to overwrite the body masks folder for a clothing item? theres a part of a body i want to hide whilst keeping another part in though the masks don't offer that option...
Can i overwrite the masks folder for that specific clothing item without altering game files?

winter bolt
#

the folder in that line doesnt actually exist so i havent tested how it works

twin basalt
#

ill try to look into it

#

thank you

winter bolt
hearty gulch
#

I'm struggling to find a way to get the items the other mod spawns. is projectzomboid . com/modding the best place to look up classes and methods?

winter bolt
hearty gulch
#

Oh cheers this actually has a search box. Any pointers where I should look to modify another mods items?

cosmic iris
#

Did you ever end up posting this on the workshop?

#

I have the UGG jacket, so if anyone needs reference photos or videos i could help out

hot patrol
#

I did not. I was really just playing around with blender. I couldn't get the texture to a point I was happy with.

hot patrol
twin basalt
winter bolt
#

hmm

#

you can also try messing with this line as well since i know this one does work
<m_UnderlayMasksFolder>media/textures/Clothes/BulletVest\Masks_BulletVest</m_UnderlayMasksFolder>

#

it hides parts of clothing textures and models but not the base model

#

actually hold on let me find a better example so you can check the actual folder

#

<m_UnderlayMasksFolder>media/textures/Clothes/Jacket/Masks</m_UnderlayMasksFolder>

twin basalt
#

yeah that i know of but i need to hide the body parts the most

#

and it does not hide it for some reason

winter bolt
#

inside those mask folders theres an image that has the whole body with the coloured zones so you could try editing that and seeing if it changes what parts the mask hides on the body

#

this one

twin basalt
#

ohh, that may be...

winter bolt
#

i'm not sure how likely it is but still

#

oh actually

#

i dont think it would work if you use the underlay mask line but it might work if you do that with the masks line i posted earlier

#

not sure though since there are no items in the base game with that mask line that actually point to an existing folder

twin basalt
#

im pretty sure the m_MasksFolder has something to do with the actual clothing item

#

but it may also go with the body with the Mask.png image

#

no yeah.. for some reason the masksfolder is connected to the clothing item

#

i have no idea why is this something that is possible while custom body masks aren't

#

because you could literally just change the texture of the clothing item without using a mask on it

#

there is a static variable "s_masksFolderDefault" pointing to the textures/body/masks folder

#

but how do i change it i have no clue

winter bolt
#

i'm gonna do some testing

twin basalt
#

this is the clothingitem object in java

#

like it seems the body mask is there but unchangeable?

#

or wait

#

could base textures be used to remove and act like a mask?

winter bolt
#

hmm

twin basalt
#

nope nevermind, basetextures cant be used if there is a model on the clothing item

winter bolt
#

yeah i've just tested a bunch of stuff with m_MasksFolder and it doesnt seem to affect the base body at all

#

it might just be for changing how overlayed clothes items affect the current item or something

#

or its just redundant idk

twin basalt
#

i think they may want to consider adding a feature like that

#

because it seems the body directory variable is in the object

#

but unchangable because its static

winter bolt
#

oh yep your guess was right

#

editing the mask folder in the body folder does aggect the body

twin basalt
#

oh?

#

ah

winter bolt
#

which means its probably hardcoded

twin basalt
#

i dont think so though

#

in the link i sent you theres the "s_masksFolderDefault" variable

#

but its static and the value is the body mask textures directory

#

its in every clothingitem class

sour island
#

@eternal garnet check that you're getting the correct player's inventory

twin basalt
#

i think they thought its unnecessary to change the mask directory for the indexed masks

#

maybe something they should consider changing though

winter bolt
#

yeah

#

i'm assuming you cant change it through lua then

#

i'm not really familiar with how static variables work

twin basalt
#

its static and cant be changed

#

like ever

winter bolt
#

damn

#

that feels like an oversight lmao

#

at least we solved that mystery i guess

twin basalt
#

well theres still the m_masksfolder which we didnt really get whats it for

#

cause only the Mask.png alters the clothing item

winter bolt
#

what does it change?

twin basalt
#

its sort of like an invisible mask on the clothing item

#

which parts of the texture should be visible

#

which is dumb?

winter bolt
#

oh like for the current item

twin basalt
#

yeah

winter bolt
#

yeah i dont understand why the masks are even separated into different colours and images tbh

#

it feels pointless but theres probably some weird stuff that requires it

twin basalt
#

the option to add masks onto the clothing item itself is pretty pointless to me

#

as its static and cant change

#

and you can just have different textures with transparent spots if you want to add masks onto different items with the same model

winter bolt
#

yeah i dont really get it

#

i understand how the underlay masks thing works but the rest destroys my brain

twin basalt
#

i feel like were missing something

#

but idk

sour island
#

the amputation mod does this

#

have you opened it up to see what it's doing?

#

there used to be a pinned message with all the masks and indexes

winter bolt
#

yeah i have the indexes here but we're trying to figure out how to change what the indexes affect when a clothing item uses them

#

im gonna check the amputation mod

sour island
winter bolt
#

oh the amputation mod just uses the normal masks

sour island
#

You're trying to make an item placed somewhere effect somewhere else?

winter bolt
#

the parts of the body that are hidden by each mask id is defined by a mask folder but theres no way to change the mask folder that a clothing item uses because the folder is hardcoded

sour island
#

you'd have to change the clothing item to point to a copy of the file in the other folder?

#

But you'd probably have to change it's model to be placed differently

winter bolt
#

nah it doesnt work since theres no way to change the folder it uses for hiding the base body mesh

#

its a static field

#

you can point to masks that hide the clothes but not the body mesh

sour island
#

clothing items are ran through scripts though

#
public static final String s_masksFolderDefault = "media/textures/Body/Masks";
twin basalt
#

oh

#

where is this located?

sour island
#

it's not even used once...

#

the variable

twin basalt
#

ah

winter bolt
#

i'm confused lmao

sour island
#

๐Ÿคทโ€โ™‚๏ธ

#

I'm in the decompiled source

twin basalt
#

then how do the body mask work?

sour island
#

selecting to see uses has 0

#
   public ArrayList m_Masks = new ArrayList();
   public String m_MasksFolder = "media/textures/Body/Masks";
#

that's public

twin basalt
#

..?

winter bolt
#

yeah but that doesnt affect the body mesh

twin basalt
#

but it dosent work though

winter bolt
#

oh wait what

#

what else is m_MasksFolder used in

sour island
#

just this:

#
   private void onFileTaskFinished(ClothingItem var1, Object var2) {
      if (var2 instanceof ClothingItemXML) {
         ClothingItemXML var4 = (ClothingItemXML)var2;
         var1.m_MaleModel = this.fixPath(var4.m_MaleModel);
         var1.m_FemaleModel = this.fixPath(var4.m_FemaleModel);
         var1.m_Static = var4.m_Static;
         PZArrayUtil.arrayCopy((List)var1.m_BaseTextures, (List)this.fixPaths(var4.m_BaseTextures));
         var1.m_AttachBone = var4.m_AttachBone;
         PZArrayUtil.arrayCopy((List)var1.m_Masks, (List)var4.m_Masks);
         var1.m_MasksFolder = this.fixPath(var4.m_MasksFolder);
         var1.m_UnderlayMasksFolder = this.fixPath(var4.m_UnderlayMasksFolder);
         PZArrayUtil.arrayCopy((List)var1.textureChoices, (List)this.fixPaths(var4.textureChoices));
         var1.m_AllowRandomHue = var4.m_AllowRandomHue;
         var1.m_AllowRandomTint = var4.m_AllowRandomTint;
         var1.m_DecalGroup = var4.m_DecalGroup;
         var1.m_Shader = var4.m_Shader;
         var1.m_HatCategory = var4.m_HatCategory;
         this.onLoadingSucceeded(var1);
      } else {
         this.onLoadingFailed(var1);
      }

   }
#

(var2 instanceof ClothingItemXML)

#

it's read right off the xml

winter bolt
#

i tested though and the only thing that affected the body mesh was changing the textures in media/textures/Body/Masks

sour island
#

Let me check body visuals

winter bolt
#

oh

#

i got it to work

#

no way

#

i just setup the textures wrong

#

m_MasksFolder does affect the body

sour island
#

๐Ÿ‘

winter bolt
sour island
#

What was the goal of all this anyway

winter bolt
#

fello wanted to hide part of the body mesh for an item they were making i think, but the default masks werent working for it

#

@twin basalt

#

yep it works now

#

wait

sour island
#

Like to replace the body with something else?

winter bolt
#

no i'm a moron hold on

#

i accidentally left in the edited body masks

eternal garnet
#

Itโ€™s that item for some reason, unless some other moniker needs to be applied

winter bolt
#

yep false alarm m_MasksFolder does not affect the body

eternal garnet
#

When I get back home I will post the full code line

winter bolt
#

yeah it doesnt seem to do anything

drifting ore
winter bolt
twin basalt
#

lol

#

maybe its bugged?

#

it seems like thats what they were going for

#

but for some reason it dosent work?

#

like i think we need to check the code for where the "m_Mask" indexes are set

#

because those numbers correspond to the image names and if we can change the directory at it can work

cosmic iris
#

I'm still really surprised no one has put out a mod for it anyway!

hot patrol
winter bolt
#

it'd be cool if it did get fixed

hot patrol
cosmic iris
#

Haven't found a tailor i trust enough. Big step doing such a permanent change on a $5000 jacket lol

winter bolt
#

ive always wondered why they modify clothes that much for shows and stuff?

hot patrol
winter bolt
#

im not into fashion design or anything so i dont really see why it happens so often

hot patrol
cosmic iris
#

I think they just have very specific looks they might want

#

And a lot of the clothing has story behind it

#

At least the first 6 seasons, the later ones not so much

winter bolt
#

the comic version looked a bit different i think

cosmic iris
#

Talked with the costume designer a handfull of times. She would dye stuff based off of what they were doing or what character they were with that episode

winter bolt
#

just generic jacket with the fur

hot patrol
winter bolt
#

it looks the same but without the badge i think

hot patrol
cosmic iris
#

This picture is a great demonstration. Eulyn womble (costume designer) always thought that Rick and Shane was one so their clothing and color reflects that. Shane has a dark top so Rick has a dark lower. Rick has a tan top but then Shane has a tan lower

winter bolt
#

all the post-alexandria images look the same

cosmic iris
winter bolt
#

lmfao

hot patrol
#

Oh damn. Lol

winter bolt
#

ricks season 2 outfit did go hard

dapper geode
#

Hello, I got some error when uploading mod to workshop, it said "results=15", anyone know how to fix this?

cosmic iris
#

depends on the size, but they go from $300 to $2000

#

Color looks different because of the lighting etc obviously

hot patrol
#

I had wanted to buy the original. But my replica is pretty solid. 3 winters in and still going strong

winter bolt
#

yeah pretty much every jacket that characters wear in media are so expensive irl

#

the jacket they used in re4 remake is like almost 2 grand

cosmic iris
cunning musk
#

Does anyone have a list of songs in the True Music mod?

cosmic iris
#

Usually about $35 but as mentoned above, most of them are quite heavily modified for the show

winter bolt
#

yeah i remember seeing an instagram account mention that a lot of them are discontinued

cosmic iris
#

That again, would be mine KEK

winter bolt
#

oh lmao nice

cosmic iris
#

@rickgrimes_sa_ids on instagram

winter bolt
#

yep thats it lol

#

i went through it recently because i was looking for inspiration on what to add to my mod

hot patrol
cosmic iris
#

I would love to see some more westen clothing

cosmic iris
cosmic iris
winter bolt
#

i was thinking of editing the winter jacket from my mod to look more like ricks now since i made another one that was more like leons

#

and i dont really like how the old one looks now

hot patrol
#

Ooo nice.

#

I saw your new Leon one to and that looks really good

#

You should call the Rick one the murder jacket or something since that's the meme

winter bolt
#

lmao

#

i just named it after his fortnite skin

hot patrol
#

Huh..

#

It's called winter jacket in Fortnite?

winter bolt
#

yeah since its an alternate style it has a unique name

hot patrol
#

I like murder jacket better. pepeLaugh

cosmic iris
#

I think most zomboid players would get it lol

winter bolt
#

i could probably add a tooltip lmao

#

i like keeping the names vanilla friendly

unique trail
#

Anyone knows if there is a way to create a loot table which only applies to a specific room inside a specific zone? E.g. I want to put a unique loot table to medical room inside the secret base, but how do I limit the loot table to only apply when it's inside medical of SecretBase zone?

cosmic iris
#

Love your mod by the way! @winter bolt

winter bolt
hot patrol
#

Same here. Some of the most stylish clothing

cosmic iris
#

Haven't ever disabled it, a must have in my eyes since it adds so much variaton!

winter bolt
#

i'm not sure what else to add to it tbh lmao

#

there arent that many items in it right now but its hard thinking of new clothes that are different enough from existing ones to justify adding but also not already being added by other mods

cosmic iris
#

Speaking of TWD though, i'm really surpried no one has added the orrange backpack yet

#

I have 0 experience with modding but probably wouldn't be too hard?

drifting ore
winter bolt
#

oh nice

drifting ore
# unique trail Anyone knows if there is a way to create a loot table which only applies to a sp...

https://theindiestone.com/forums/index.php?/topic/38185-new-room-definitions-4165/

these are all room definitions, so i guess you would just have to figure out a way to define a new one?

unique trail
winter bolt
drifting ore
winter bolt
#

its just a hiking bag i think

cosmic iris
#

Plenty of character used it. It's mostly iconic for being in the show for so long

#

Rick, Daryl, Eugene, Glenn and Carl used it

#

Probably some more but those are the ones i know used it at the top of my head

winter bolt
#

oh damn yeah i forgot it was first in season 3

#

for some reason i thought it was just 4

cosmic iris
#

Ill drop a few picutres of it

cosmic iris
shadow geyser
# unique trail Im aware of how to define a new one... The thing is that this forces me to creat...

you could always hack it so that you are adding in your new items through code, rather than a distribution table, that way you can avoid having to make a new map to have the room definition. you can use the lua event "OnSeeNewRoom" that would trigger the first time a new room is loaded and generated. Then just figure out the correct criteria so that it only executes your code in that specific room. Checking the coordinates would probably be enough. then you can do what ever you want to add the stuff you would like, into the room

cosmic iris
unique trail
cosmic iris
#

Here is the listing

winter bolt
#

nice

cosmic iris
#

Shows it pretty well

polar prairie
# cosmic iris

this ingame as a model for the poncho-mod would be so cool.

cosmic iris
#

Zomboid was my way to live the TWD dreams i had

#

Getting some pieces from the show ingame would be spiffo

winter bolt
#

yeah i tried making a poncho a while ago but never got far

#

apparently i deleted the file too

cosmic iris
#

Ponchos are quite cozy IRL

#

Such a cowboy sterotype but i have one i used at the office for a few months during winter times

winter bolt
#

yeah i kinda want one tbh

ancient grail
#

hi how do i create a ui that opens when a player enters the server. cuz what i found is something that stays even after exiting the server

#

local UI
local text1 = getText("UI_Rules")

local function choose(button, args)
-- getPlayer():Say(args.choice);
UI:close();
end

local function onCreateUI()
UI = NewUI();
UI:addRichText("rtext", text1);
UI:setLineHeightPercent(0.35);
UI:nextLine();

-- UI:addButton("b1", getText("UI_Cancel"), choose);
--UI["b1"]:addArg("choice", getText("UI_Ready"));

UI:saveLayout();

end

--open 'UI'
function onCustomUIKeyPressed(key)
if key == 21 then
local UI = onCreateUI();

end

end

Events.OnCustomUIKeyPressed.Add(onCustomUIKeyPressed);

--Events.OnLoginStateSuccess.Add(onCreateUI());
Events.OnGameStart.Add(onCreateUI());
--Events.OnConnected.Add(onCreateUI());
--Events.OnCustomUIKeyPressed.Add(onCustomUIKeyPressed);

#

pls advice thnx

cosmic iris
#

oh what

winter bolt
cosmic iris
#

Lmao had no idea

winter bolt
#

yeah they added daryl and michonne a few years ago and then rick last year

cosmic iris
#

Im surprised they didnt go with Rick's denim shirt for his outfit

winter bolt
#

oh they did

cosmic iris
#

The Denim supply?

#

Blue denim shirt

winter bolt
#

grey but still

cosmic iris
#

Oh the gray levis

winter bolt
#

jacket rick and poncho daryl are 2 of my favourite skins easily

#

jill valentine is up there too

cosmic iris
#

I was asking since very other media hes in he has the blue denim one

#

PUBG, the VR games and some mobile games

#

They use the exact same outfits

hot patrol
#

Another TWD clothing items I am surprised has never been modded in is Daryl's vest.

#

You'd think that would be #1

cosmic iris
#

I think i know why actually! AMC did a few pictures of every cast member as they were going to make action figured but they never did them. So they probably just used those pictures when they put him in games

winter bolt
#

i did add a leather vest without sleeves to my open jackets mod so i could probably do something with that

cosmic iris
#

Seen this "skin" in like 4 games lmao

winter bolt
#

lmfao it looks so awkward

#

it reminds me of those harry potter promos

cosmic iris
hot patrol
cosmic iris
#

Same vibe pretty much

winter bolt
#

trevor man

cosmic iris
#

Haven't really seen him in any shows or movies since

#

Wonder what he's up to

winter bolt
#

he was in better call saul a few times

#

only for a short role though

hot patrol
#

It's crazy how much ogg looks like Trevor whilst also looking nothing like him. Like obviously they used his face scan but you can really tell how they method him out hard

winter bolt
#

yeah lmao its scary

cosmic iris
#

crazy how it's pretty much the same character

#

He plays that type of person in the 3? things ive seen him in lol

winter bolt
#

yeah he's been super typecast but he's still great lmao

cosmic iris
#

He's still brilliant yeah

radiant venture
#

spongie why did you have to present me with thsi cursed knowledge

#

the world didn't need to know TWD was in fortnite xd

winter bolt
#

in bcs he's still similar but not evil like trevor or simon

winter bolt
#

i'm one of the few that uses them lmao

radiant venture
#

well yk characters from a 18+ show in a 12+ game

winter bolt
#

yeah its funny

radiant venture
#

i feel like they kinda missed their target audience

winter bolt
#

i never see anyone use the resident evil skins either except for myself lmao

cosmic iris
#

To be fair, i guess target audience for TWD and fortnite is a bit different

radiant venture
#

still haven't watched TWD

#

i probably should

cosmic iris
#

Is Fortnite still going? havent played since 2019 i think

#

Did i hear that they removed building??

winter bolt
#

nah theres an optional gamemode without building

#

i always play it though

radiant venture
#

so yk they missed BOTH target audiences

winter bolt
#

i really hope they add a leon skin to promote re4

#

it'd look sick

cosmic iris
#

Yeah it was a really strange thing to mix fortnite with TWD

#

Wait, is there RE skins in fortnite?

winter bolt
#

yeah they added chris and jill last year

radiant venture
#

weren't they adding that one grey fucker from RE uhhh 2 i think? to DBD?

cosmic iris
#

Feels like another example of missing the target audience lmao

winter bolt
#

jill looks great but chris is really rough

#

chris has his re8 outfit and the model is honestly dog shit

radiant venture
winter bolt
#

his re5 model looks so much better but i'm really annoyed it wasnt matching with jill

radiant venture
#

WHAT DID THEY DO TO HIM

winter bolt
#

he actually got butchered so hard

radiant venture
#

i hate how he looks in re 8 in general tho-

#

like

winter bolt
#

i love how he looks in 8 but that fortnite skin is not it lmao

drifting ore
radiant venture
#

to me since i'm a bit younger he'll always be "the guy from that one RE7 DLC" please don't murder me spongie a saw your profile i know you love RE

winter bolt
radiant venture
#

i'd love to cosplay his RE7 look tho

#

still gotta get the gasmask somehow-

#

and well, the muddy sort of smudge for all the clothing

winter bolt
#

yeah i dont really mind his re7 look that much its just that they changed his face so radically compared to the other games

radiant venture
#

i'm always so scared to weather clothes for cosplay-

winter bolt
#

you have to fight a real biohazard for the authentic look

radiant venture
radiant venture
hot patrol
winter bolt
#

its weird because his model in 8 is the same face scan from 7 but they just modified it to resemble the other versions more

hot patrol
radiant venture
winter bolt
#

his face is pretty consistent except for 7 lmao

radiant venture
#

where did his jawline go in 7?

#

also god the CV version-

#

ah wait i remember 5 now, didn't he try punching a boulder?

winter bolt
#

yeah lmao

radiant venture
#

YEAH THAT SCENE?

#

what were they even thinking

#

heehoo break knuckle?

winter bolt
#

the fact that chris has his 5 outfit in fortnite while jill has her re1 outfit is super annoying because its literally the reverse in dead by daylight

#

they dont match in any crossovers lmao

radiant venture
#

lovely

#

haha corparate funny

shadow geyser
shadow geyser
winter bolt
#

yep

#

travis scott too lmao

radiant venture
cosmic iris
#

Jesus lol

#

Seems like everything is in Fortnite

sour island
#

fortnite is the real metaverse

radiant venture
winter bolt
#

theyve got ripley and the xenomorph too

cosmic iris
#

Just dosent feel like it's hitting the target audience with most of those, so i wonder how well they are doing

violet shell
#

Seriously, is it possible to discuss off topic stuff in another chan ? This is modding chan guys ๐Ÿ™‚

winter bolt
#

oh yeah i forgot what channel this was lmfao

radiant venture
#

pff right-

cosmic iris
#

Yes, definitely. Where do we migrate to? KEK

radiant venture
#

lets go to general chat

radiant venture
eternal garnet
#

@sour island

  if player:getDescriptor():getProfession() == "bountyhunter" then
    local inventory = player:getInventory() 
    inventory:AddItem("Stahladd3_Colt1851")
    inventory:AddItem("Stahladd3_Colt1851")
    inventory:AddItem("Base.Bullets38Box")
    inventory:AddItem("Base.Bullets38Box")    
    inventory:AddItem("Stahladd3_OldShotgun")
    inventory:AddItem("Base.ShotgunShellsBox")
    inventory:AddItem("Base.ShotgunShellsBox")    
    inventory:AddItem("Base.Katana")
    inventory:AddItem("Base.HolsterDouble")
    inventory:AddItem("SlingA")        
    inventory:AddItem("J6_Helmet")
    inventory:AddItem("J6_Scarf")
    inventory:AddItem("J6_Shirt")
    inventory:AddItem("J6_Torso")
    inventory:AddItem("J6_Pants")
    inventory:AddItem("J6_Gauntlets")
    inventory:AddItem("J6_Shoes")```
#

This is what I am using and these items spawn

#

Just the Watch does not

violet shell
#

@eternal garnet here is a code I use in one of my mods to give players some stuff at start. Maybe it could help you ?

-- Add a starting item when a player spawns --

Events.OnGameStart.Add(function()
local player = getPlayer()
local pData = player:getModData()

    if not pData.FirstTimeItem then
        player:getInventory():AddItem(MyMod.MyStartingItem)
        pData.FirstTimeItem = 1
    end
end)```
#

people here helped me to code this properly a few month ago.

sour island
#

That'd be the same thing he's doing tho

eternal garnet
sour island
#

Does it not work for either digitalWatch or digitalWatch2?

eternal garnet
#

I will give that a try now and let you know

sour island
#

I see the issue

#
    item DigitalWatch
    {
        DisplayCategory = Accessory,
        Type                =            Normal,
        DisplayName            =            Digital Watch,
        Icon                =            DigitalWatch,
        Weight                =            0.0,
        MetalValue = 3,
        Obsolete = TRUE,
    }

    item DigitalWatch2
    {
        DisplayCategory = Accessory,
        Type                =            AlarmClock,
        DisplayName            =            Digital Watch,
        Icon                =            DigitalWatch,
        Weight                =            0.0,
        AlarmSound = WatchAlarmLoop,
        SoundRadius = 7,
        MetalValue = 3,
        Obsolete = TRUE,
    }
#

Obsolete = TRUE,

eternal garnet
#

Ah

sour island
#

that tag deletes it on spawn

eternal garnet
#

Is there a way to get around that as the item is in game

sour island
#

look in clothing_jewellery.txt

#

There's variants for each wrist (didn't know that)

eternal garnet
#

WristWatch_Right_DigitalBlack

violet shell
#

@sour island Can you explain what Obsolete argument does ? Or point me to somewhere I can read about it ?

eternal garnet
#

Think I got it

sour island
violet shell
#

so, how we can find some digital watches in game then ?