#mod_development

1 messages ยท Page 538 of 1

bronze mulch
#

Question

gaunt pendant
#

but still, it won't improve much

bronze mulch
#

You mean

#

save it in the cache?

#

like the first time it loads its gonna lag sure

#

but it also saves them clothes

#

so it wont have to check them again

gaunt pendant
#

yea that's what I'm doing rn

#

Browser thinks there's a smarter way to handle that list to begin with

bronze mulch
#

i mean just two diff ideas

drifting stump
#

you can get variations of a specific item

gaunt pendant
#

well this is good enough for me

#

lil micro stutter but nothing as bad as before

bronze mulch
#

i mean

#

you are both right and it would be the best if the ideas would be combined anyway

gaunt pendant
#

Putting this on the workshop for now, might revise if a future version ๐Ÿคท

#

At the very least we know what's causing it now

bronze mulch
bronze mulch
#

Gotta test this more

#

idk if this works

zealous peak
#

yo

#

Not usre if this is betteer asked here or mod support: Is there a mod out there that lets u buuild dirt paths?

bronze mulch
#

build paths

#

the mod lol

zealous peak
#

thank you. Like, seriously

#

I searched for something like this months ago and didn't even think it existed until a friend of mine alluded to it

kindred jay
#

any mods that combine all of the ui menus (i.e inventory, health info, crafting) all in one menu with tabs? Something like 7 days to die?

gaunt pendant
#

Kinda?

drifting ore
#

What are the odds of a Teamspeak mod? Like... If anyone's played Arma 3, TFAR/ACRE2, but project zomboid

#

I feel like it would be doable as the game already has a system to detect how close players are to each other so really the mod would just have to sorta highjack that aspect and take it to teamspeak

#

But I'm not a modder so idk

#

Hell it might already exist

tropic dirge
#

Does anybody know about a spawn protection mod? The reason I ask is. People grind for skills, or live a long time, doing a great job. Then gets disconnected due to an error in an unlucky situation. Logs back in and dies.

lime heath
drifting ore
tame mulch
drifting ore
#

Shouting through them with Q does, though

tame mulch
#

Walkie talkie VOIP works

drifting ore
#

Rimmy had a similar issue recently

#

On YouTube

tame mulch
#

Maybe to far distance?

drifting ore
#

he was stood next to the guy

#

And q worked

#

Also in-game VoIP is kinda... Idk I wanna say underwhelming

#

It doesn't sound very nice

#

A teamspeak plugin though, that'd be pog

tame mulch
#

I think way to connect TeamSpeak to Zomboid is write from game to text file coords of players and if walkie talkies data. And read from outside of game this file and send data to TeamSpeak

drifting ore
#

So would a plugin like that be somewhat easy to create?

tame mulch
#

I think possible, but not very easy

#

I don't know how work plugin for TeamSpeak

drifting ore
#

Yeah

tame mulch
#

I think better wait when we fix radio and walkie talkies. But VOIP with walkie talkie works good now

#

Also can talk between walkie talkie and HAM radio

drifting ore
#

Yea true

zealous wing
#

I got... Fitty cans of Code Red.
Imma do a lotta mod dev this week ๐Ÿ˜„

woven wren
#

Don't know if I should release this tonight or tommorow.

kindred jay
woven wren
#

I'll get more downloads that way.

broken fulcrum
#

hey, anyone knows how are the hair salons called for procedural distribution?

#

I couldn't find it in the wiki, I think it was outdated

flat apex
#

If you mean how haircuts are picked: Randomly with a few conditions found in Definitions\HairOutfitDefinitions.lua

broken fulcrum
#

This โ˜๏ธ

flat apex
#

Ah, I think there's a few for different types of containers and they're prefixed with Salon

broken fulcrum
#

Thank you! I'll try to find it tomorrow, goodnight frog

tropic dirge
bronze mulch
gaunt pendant
#

The whole thing is pretty inefficient the way it's meant to work:

  • Get list off all possible recipe ingredients (all clothing items, for rip sheets)
  • Mark the ones you have in inventory
  • Sort that list, so the marked ones are on top (and then alphabetically)
  • Remove stuff (starting from the bottom of the list, so stuff in your inventory has priority to remain) thatbis considered a variant of other items, e.g bandana head == bandana face, so that stuff only shows up once
#

To achieve that it's at least n^2 (check each item against each other item's extra variants)

#

And gets way worse with more stuff added from mods, obviously.

bronze mulch
#

Probably will ask for help

#

Prepare

gaunt pendant
bronze mulch
#

I mean in general

#

I dont see the point of the window prompt

#

It shows me what clothing I can rip

#

Like bruh

gray goblet
# gaunt pendant The whole thing is pretty inefficient the way it's meant to work: - Get list off...

i've always been kinda bummed by this, why are they even sorting it alphabetically. just sort it at launch, then move every recipe that has mats to a new list and hide it from non mats list. would reduce it to O(n) right? no real reason to have it alphabetically since the amount of recipes available per time being so low. Allowing you to easily search what mats you need. While increasing ram a tid bit should be faster(?)

gaunt pendant
gray goblet
#

I can see it aswell, its viable for vanilla. but a pain when content becomes to high as u mentioned. but theres a mod that just removes the sorting so its fast but hard to find what recipe u can make etc :/

gaunt pendant
#

The sorting is not the problem

#

This part is

bronze mulch
#

Anyway

#

Any idea which script part is responsible for the window showing anyway?

#

If I delete the first 2 script parts

#

Bscly font and image

#

It does not lag anymore in anyway shape or form

#

Which is funny

gaunt pendant
#

Bro leave the window, just remove that 1 - character in line 2592. Poof all problems gone

bronze mulch
#

You kiddin

#

Tho won't it break something?

gaunt pendant
#

Dead serious

bronze mulch
#

Like

gaunt pendant
#

Not worst case you'll have duplicates in the tooltip (omg how will we ever live wkth that)

bronze mulch
#

The whole tooltip window makes no sense to exist anyway

#

That's what craftmenu is for

gaunt pendant
#

That part is:

For every clothing item x:
  For every clothing item y:
    For every variant in x:
      Is y a variant of x?
bronze mulch
#

Cuz like

gaunt pendant
#

Which is ok-ish for vanilla's 190 or so clothing items with few variants

bronze mulch
#

Delete

#

Turns into this

#

But does not lag

gaunt pendant
#

Bro just delete that 1 minus and check

#

It works

bronze mulch
gaunt pendant
#

Or use that mod I posted, which at least takes most of the computing needed out of is y a variant of x

bronze mulch
#

But also the fact that it displays it for some reason?

gaunt pendant
#

It reaches crazy numbers of iterations

#

190^2=36k
400^2=160k

bronze mulch
#

Yes but it stops lagging when you delete the texture also

gaunt pendant
#

The texture is not the problem

#

You probably deleted smth else related

gray goblet
#

could be if he reloads the texture everytime he checks an item

#

but it shouldnt

bronze mulch
#

I dont mean that the texture is the problem as you say its obsly the sorting system

gaunt pendant
#

Likely, the game caches once-fetched textures

#

Otherwise it'd be unplayable

bronze mulch
#

But if deleting the texture and font fixes it

#

It means that the vanilla script check them all in the first place as you said lol

gaunt pendant
#

The problem is checking every single clothing item against every other single clothing item's variants and by doing so fetching everything via script manager

gray goblet
#

^

gaunt pendant
#

Couple mods that add clothing you have a million iterations every time that tooltip pops up ๐Ÿคฃ

#

All while that list never really changes, only what's should be shown on top should

bronze mulch
#

Sponge clothing adds the ability to open and close almost every jacket etc

#

Still tho what I wanna do is delete the tooltip window as a whole

gaunt pendant
#

Yup, so you're nearing n^2+n ๐Ÿ˜‚

bronze mulch
#

So when you hover the cursor the whole window just does not popup

gaunt pendant
#

Remove everything in that if

#

2767 to 2775

#

Well, remove the if as well haha - no point having it empty

bronze mulch
#

Wait is this even possible to release as a workshop mod if it deletes a part of vanilla script

#

Cuz you optimized it

#

But this is deleting lol

gray goblet
#

is it not possible to override like in python?

bronze mulch
#

Dno that's why I'm asking

gray goblet
#

dunno tbh, never touched LUA i know its a thing in java

bronze mulch
#

@gaunt pendant comrade you reckon if that possible lol? or will it need another script for it to delete it

gaunt pendant
#

You can usually replace full functions

gray goblet
bronze mulch
#

even worse

#

even worse one*

gray goblet
#

ive noticed this alot cuz i do some experiments to see how much of each material etc u can find per city

#

and looting eventually ur game to almost entire stop fps wise. driving when ur 2k weight runs at 5 fps compared to 150 fps when at 20-30

bronze mulch
#

Can't get alot of help through google since most of them modding forums happen to be about minecraft lol

gray goblet
#

well, in the end its all code.

#

what are you currently having an issue with?

gray goblet
#

ive just been loosely reading, but i mainly work in java / python so abit unsure of datatypes etc in lua

bronze mulch
#

with this mod that optimizes it mostly

gray goblet
#

oh yeah yeah, i have that issue in my playthrough

bronze mulch
#

๐Ÿ’€

pseudo lake
#

Pretty easy fix would be to sort them and only load limited amount

bronze mulch
#

What im trying to do and did with tiaxx's help anyway is to delete the whole window prompt on its own anyway cuz i find it nonsense that it is there in the first place

gray goblet
#

it only happens for items with alot of recipes so theres an obvious fix although tedious

bronze mulch
#

like

gaunt pendant
bronze mulch
#

Why do i need to see 192 items i can rip

#

if thats aleardy in the crafting menu

#
  • it lags the game
gray goblet
#

is every clothing variant its own id or just a meta type of an overlaying id?

bronze mulch
#

Alright so

#

as you said tiaxx i deleted the whole window on its own now using your help

gaunt pendant
bronze mulch
#

My question is how do i release this as a mod now that i can download everytime i gotta uninstall every mod cuz i use way too many

#

i see the steam workshop thing

#

for releases etc

gaunt pendant
bronze mulch
#

wut

#

you mean mod ur mod

gaunt pendant
gray goblet
#

how does it check for recipes? does it look through all recipes and checks which ones got rip clothing as a recipe?

#

i hope they are doing a crafting rework of that system ngl, it seems wicked slow

bronze mulch
#

Post to github poster description alright noted

#

Problem being im not sure even how to start this script

#

time to use google for help as always

gaunt pendant
#

It should find it there and you can start changing stuff around

bronze mulch
#

got somewhat past the issue

#

alright

bronze mulch
#

or does steam do that automatically

gaunt pendant
bronze mulch
#

the mod thing

#

bruh

#

as much as im bad at programming

#

doing simple stuff like a website or somethin in html is easy did that like 5 years ago

#

But im having major issues typing a simple script in lua that would do

#

Find lines "" >delete them

gaunt pendant
#

Because that's not how you do it

bronze mulch
#

forgot the part where it tries to do that in

#

IsInventory

gaunt pendant
#

The game loads all the vanilla scripts, then all the mods (in some order). So what ur mod would do is replace an existing function, that is loaded from vanilla game

#

So brute force method: copy the entire function to a new file in your mod and change stuff there.

#

This will then override/replace/redefine that vanilla function with that code

#

That replaces the vanilla function ISRecipeTooltip:isExtraClothingItemOf(item1, item2)

#

A mod cannot just delete that 1 part within the function, you have to redefine it. Best case you can call the original and change the result or do smth before and then call the original. You cannot do that here, you have to completely replace the function body (even if mostly identical)

bronze mulch
#

So the script will bscly look like that

#

Function >the function that im changing

#

Copy paste of the original function but turned off < If i wan't to completly turn off that window lol

gaunt pendant
#

Yeah I believe it was ISInventoryPaneContextMenu.addDynamicalContextMenu u wanted to override

#

Mind you, this is kinda the worst way to do it compatibility wise

#

If TIS ever changes a single thing, you're still overriding it with the "old" logic. Not much you can do about it in this case, though.

bronze mulch
#

Alright let's say i want to do this like

#

you said ealier

#

delete them - for example

#

in which way the whole script turns off

#

or change the script

#

so it just wont turn off in anyshape or form

gaunt pendant
#

Yea that whole block is then commented out, makes u wonder if it was supposed to be on in the first place ๐Ÿคฃ

#

So yeah, copy paste that whole function, then change as u like, e.g. comment out that block

bronze mulch
#

CraftTooltip:layoutContents

#

epic

#

Alright copy pasted the whole function

#

top to bottom

#

did them changes

gaunt pendant
#

Ok so 1 catch still:

bronze mulch
#

What do i do for this

#

to load itself into the main one

gaunt pendant
#

CraftTooltip is local, so ur mod cannot access it. Use ISRecipeTooltip:

#

They reference the same object, so that works

#

Lastly, put in a folder in mods dir. See that example mod folder already there for reference

#

In userdir/zomboid/mods, that is

#

Won't go into workshop stuff, that's extra steps

bronze mulch
#

Wait i got confused

#

The function that im editing rn is

bronze mulch
#

a

#

wait

#

didn't see them

#

and the start

#

is crafttooltip anyway

#

alright

gaunt pendant
#

U don't copy that. I'm just showing that "CraftTooltip" is file local, so your mod lua wouldn't know about it

#

Luckily, they aliased it as ISRecipeTooltip as global var

#

So u can use that, it's the same but available to your mod

bronze mulch
#

alright

#

this at the top and lines 2458 to 2684 copied

#

with the changes applied

#

Let's see where it goes

gaunt pendant
#

Wait what ๐Ÿ˜‚

bronze mulch
#

or did you literally mean the whole function

gaunt pendant
#

Why isExtraClothingItemOf ?

bronze mulch
#

wrong screenshot

#

lol

#

mbm

bronze mulch
#

lol

gaunt pendant
#

Args should be x,y

bronze mulch
#

Alright literally copied it from the vanilla code

#

should work

#

hopefully

bronze mulch
gaunt pendant
#

But yes, whole file should be

function ISRecipeTooltip:layouContents(x, y)
  -- your logic/copy paste with ur changes
end
bronze mulch
#

looks gud

gaunt pendant
#

mod.info has the stuff shown ingame, e.g. mod name and description, just look at what's already there

#

Should be able to figure it out from there

bronze mulch
#

looks gud

#

alright

#

moment of truth

gaunt pendant
#

It's been 10 minutes. His PC exploded taking everything within a 2km radius with him. Probably. Rip.

bronze mulch
#

i have no idea why

#

but it

#

i mean its there

#

fuck

#

its the id

#

does the id need to be the same as the lua file xD

#

Didn't work

#

big f

#

here lies my beauty

#

wonderin if

#

thats the script problem or i cant put it in

#

the mod folder xD

#

i mean

#

it was there

gaunt pendant
#

Mod id is ur arbitrary name for it, just make sure its unique

bronze mulch
#

i mean first it bugged out cuz the id was examplemod

#

to be extra sure i named everything

gaunt pendant
bronze mulch
#

that was sup to override the vanilla one

gaunt pendant
#

That's not at all it though?!

gaunt pendant
#

Multiple functions, still referrong to it as CraftTooltip

bronze mulch
#

you know the song that goes

#

skubidubiduba

#

like

#

late 90

#

female voice

bronze mulch
#

Wait

#

there has to me a simple way

#

to change every

#

Crafttooltip

#

Wait

gaunt pendant
#

Wtf are you doing ๐Ÿ˜‚

bronze mulch
#

why does

#

why does

#

what

#

what the fuck

#

i changed that

#

i sent a screenshot

#

wdym

#

BRO

#

AAAAAAAAAAA

#

comrade

#

if i check one

#

they all light up

#

y know any epic lifehack

#

to copy paste it to all of them at once

gaunt pendant
#

Yes, but u don't wanna do that

bronze mulch
#

wdym

#

WDYN

gaunt pendant
#

In that script file, delete everything. Now copy the CraftTooltip:layoutContents(x,y) function AND ONLY THAT FUNCTION into it. Now rename it to ISRecipeTooltip:layoutContents

#

Then do your change (e g. remove that 1 minus). Save, restart game, be amazed.

bronze mulch
#

chineseballs

gaunt pendant
#

I really cannot explain it any simpler ๐Ÿ˜ญ

bronze mulch
#

no but like

#

you mean

#

delete everything?

#

literaslly

#

xD

#

alright

#

i mean

#

sure

#

sure

#

bro

gaunt pendant
#

No just wipe that lua file cuz whatever u put in there has nothing to do with wat u showed above

#

Hence is cursed ๐Ÿคฃ

bronze mulch
#

XDDDDDDDDDDDDDDDD

#

Bro

#

i have no ideaw how

#

but it fucking

#

reversed

#

everything i did

#

just fucking went bamboozle

#

XDDDDDDDDDDDDDDDDDD

gaunt pendant
#

Prolly moved files around before saving

#

So it fits that mod folder structure

broken fulcrum
#

Damn

bronze mulch
#

what's the song

#

with the female voice

#

that goes like

#

skoobi doobi do ba

broken fulcrum
#

Wut

bronze mulch
#

like late 90s song

#

it was used in meme complations

#

alright

#

back to doing them mods

bronze mulch
#

what the fuck

#

WHY IS SPAGHETTI UNDER THER

#

E

bronze mulch
#

WAIT

#

BRUH

#

wait fuck im lost

#

actually

#

alright

#

i actually got lost

#

what line to what line do i copy

#

i did 2325 to 2684

bronze mulch
#

what

gaunt pendant
#

If it's the unmodified file, it should be 2458 to 2642

bronze mulch
#

NEW SINGLE OUT NOW!!! https://lnk.to/scatmanhatman

The worldwide number one hit that launched Scatman John in the Pop and Dance scene.

Follow the legacy of The Scatman on Facebook: https://www.facebook.com/ScatmanJohnOfficial


EURODANCE, SONY, BMG, RCA, 90'S HIT RECORD, 90'S NUMBER ONE, Scatman John, official video, Haddaway, Ace Of Ba...

โ–ถ Play video
gaunt pendant
bronze mulch
#

bruh i got so confused i thought i was sippin on whisky

#

turns out its rum

#

anyway

#

to fast travel

#

to a line?

gaunt pendant
#

Ctrl+g for me, dunno if thats the default tho

#

I'm too old to learn new keybinds ๐Ÿคฃ

bronze mulch
#

pasted

#

change applied

gaunt pendant
#

Looking good now

bronze mulch
#

one more time

#

what now

#

XD#

bronze mulch
#

bruh i turned it on

#

still does not work

#

pog

gaunt pendant
#

Copy that folder structure

#

media/lua/client/doTheThingMod.lua

bronze mulch
gaunt pendant
bronze mulch
#

ah

#

I mean the mod appears ingame

gaunt pendant
#

Userdir/mods/YourDoTheThingMod
Has mod.info, .png and subfolder media

bronze mulch
#

then luda

#

client

gaunt pendant
#

Yes and .lua file in there

bronze mulch
#

ever heard the story of chineseballs

gaunt pendant
#

Not sure I want to ๐Ÿคฃ

bronze mulch
#

Alright

#

turning the game now

gaunt pendant
#

Also make sure that file actually ends in .lua, not .lua.txt, I see u have file extensions off for some reason

bronze mulch
#

god died

#

sending the script once more

broken fulcrum
#

every time I read your mod's name I can only think of john cena talking in chinese lol

#

"bing chilling"

bronze mulch
#

bro

bronze mulch
broken fulcrum
#

why that name bro hahaha

bronze mulch
#

i dont fucking know

#

why aint this working

#

wdym

broken fulcrum
#

unhappy sadge

bronze mulch
#

bro

#

i made progress

#

lemme ss

broken fulcrum
#

yeah, I remember

#

then I think you fucked up with something lol

bronze mulch
#

XDDDDDDDDDDDD

#

WDYM

#

XDDDDDDDDDD

#

lemme

#

lemme

#

check my game files

#

holy fuck

gaunt pendant
#

Ahaha wtf

bronze mulch
#

comrade

#

you sure

broken fulcrum
#

maybe try asking help from nasKo or other dev?

bronze mulch
#

i dont need to copy the whole thing

#

like literally

broken fulcrum
#

they could point that out for you I think

bronze mulch
#

2325 to 2684

gaunt pendant
#

No, you are making this more complicated than it has to be :rofl:

bronze mulch
#

when i deleted them fonts and sizes

#

i mean

#

epic

#

the mod works

fast galleon
#

somebody remote desktop him

bronze mulch
#

bro

#

im just gonna

#

fucking copy the whole

#

script

#

xDDDDDDDDDDDDDDDDDDDDDDD

#

i fucking can't

#

it override

gaunt pendant
bronze mulch
#

the wrong line

#

somehow

gaunt pendant
#

Unless u name the file identically

bronze mulch
#

lemme

#

lemme check something chief

#

i mean

#

at least now we know

#

the script isn't working xD

gaunt pendant
#

I'm pretty sure it's called Chineseballs.lua.txt ๐Ÿคฃ

bronze mulch
#

i did

gaunt pendant
#

Ok

bronze mulch
#

part 3

#

alright

#

any ideas of what might be broken

#

we appreciate help

#

just to be sure

#

the mod does not need a working poster to work

#

does it xD

gaunt pendant
#

Sec

bronze mulch
#

started to question the meaning of life

#

yall ever think bout a cheeserbuger

gaunt pendant
#

Ahh crap

#

U see those constants? FONT_HGT_SMALL etc used in the function?

#

Copy those too

#

Sry this is a mess ti figure out via remote, still at work

noble imp
#

hey hov to mod

#

I press subricibe on steam

#

it doesnt sends any dovnland

#

or to project zomboid

gaunt pendant
#

Lines 2334 + 2335

noble imp
bronze mulch
#

XD

bronze mulch
#

like 5 minutes ago

#

after realizing

#

i did delete those two

#

and it did the same like 2 days ago

bronze mulch
noble imp
#

I cant mod

bronze mulch
#

you sure they didn't download and arent in your

#

mods<

#

in the main menu

bronze mulch
#

just copy and paste these below >function?

noble imp
#

I press subrcibe
I launch my game
I look into mods

#

nothing

#

even my dad

bronze mulch
#

Seems like a steam mod

#

steam problem

#

you did the whole

#

restart steam etc

gaunt pendant
bronze mulch
#

above

#

that seems hardcore

gaunt pendant
bronze mulch
#

ye

#

anger

gaunt pendant
#

Jeez

bronze mulch
#

at this point

#

maybe just copy the script from

#

to

#

i will try that ina few

#

But lags

#

xD

#

wait

#

wait

#

i might have fixed it

gaunt pendant
bronze mulch
#

holy fuck

#

i pasted it under

#

it works

gaunt pendant
bronze mulch
#

Why didnt it work

#

when i pasted it above

bronze mulch
#

bruh

#

alright

#

im gonna go get drunk

gaunt pendant
#

๐Ÿคฃ

noble imp
#

hey anyone here

#

I have issues for modding

#

mine is 41.68 cracked version cause I dont have money

#

I dovnlanded mods I vanted

#

but couldnt figure out vhere to put them

#

I put them in mods folder but it didnt vork

broken fulcrum
#

try putting them in here -> C:\Users\YourUser\Zomboid\Workshop

noble imp
#

Im a dumb about computers

bronze mulch
#

will not be updated if it breaks it breaks

broken fulcrum
#

but if you go to Users

#

justs select which one you use

noble imp
#

vhat nov

broken fulcrum
#

'Zomboid' Folder

#

then 'Workshop' Folder

#

put mods in there

noble imp
#

๐Ÿ’€ there is nothing like that

broken fulcrum
#

it should appear in-game

noble imp
#

letme check

broken fulcrum
#

do you have a pirate game? maybe it's installed elsewhere?

noble imp
#

eyyyy

broken fulcrum
#

Nice

#

๐Ÿ˜„

noble imp
#

found vorkshop

#

๐Ÿง€

broken fulcrum
#

now put the mod folders in there

#

and you are good to go

noble imp
#

in vorkshop folder right

#

there is a mod folder

#

in above that

broken fulcrum
noble imp
#

ok

#

you are a great guy

broken fulcrum
#

just the ModTemplate

noble imp
broken fulcrum
#

and some .txt files

#

contains my modlist

#

generated automatically

#

this is my Workshop folder

#

you can also make your mods and put in there to test it before launching to the workshop on steam

noble imp
#

didnt vork

#

let me investigate

bronze mulch
#

now i shall get

#

into

#

modeling

broken fulcrum
#

damn

#

good luck bro

bronze mulch
#

but there

#

i have at least

broken fulcrum
#

that shit it haaard

bronze mulch
#

blender experience

broken fulcrum
#

oh

bronze mulch
#

@gaunt pendant

#

comrade

#

gimme ur steam id

#

so i can add u as a co mod thing

noble imp
#

@broken fulcrum I put them in mods folder instead of vorkshop

#

VORKED

#

eyeyyyyyyyyeyyeyey

#

ฤฑm in happy

broken fulcrum
#

๐Ÿฅฐ

#

Nice bro

#

good to hear

gaunt pendant
broken fulcrum
#

your steam will appear on the right

#

with him

bronze mulch
#

yus

gaunt pendant
broken fulcrum
#

Man, I think I somehow made a mod that erased my fucking main menu

tropic dirge
#

Can I use this for my server?

bronze mulch
tropic dirge
bronze mulch
#

I don't see why it wouldn't work

bronze mulch
#

Crafting Contextmenu Antilag [41.69]

#

this one

#

or RipAndCraftStutterFix

tropic dirge
#

Will do

exotic fox
#

Anyone do modding comission work here?

broken fulcrum
tropic dirge
exotic fox
formal ocean
#

anyone knows what happened to radioEquipedCheck()? can no longer see it in modding docs

#

we wanted to make radios work while on belt

keen frost
#

You can't is java hardcoded

chrome egret
#

Nothing saying you can't manually check whether they have a radio on the belt

obsidian portal
#

Hey, got a quick question here, working on adding in a pillow, and I want it to act like the spiffo plush, where it is kind if just a 3d model that sits around, what would be a good way to implement this? Already have the model ready in blender

frail widget
#

This might be a dumb quetsion but we all have to start somewhere

#

Where can I get started on modding?

obsidian portal
#

the PZ wiki has some good starting points @frail widget

latent orchid
#

yeah, the wiki overall has been improved massively

vapid arrow
#

i just updated my mod, added firearms weapons, zombified doomguys and variants of colors to the armor.

obsidian portal
#

Lets go, got an item added, I just need to import the model correctly, and set an Icon

#

Does anybody here know how you are supposed to assign a 3d model to a Item? Its just a world item

wet sandal
#

Anyone know how to get a custom icon in this area? Or any mods that add one?
Just looking for a class/lua name to get me started

#

ISEquippedItem.lua

#

Found it

keen frost
wintry stag
#

Someone knows the Discord User of the guy that created the weird Richard Mask from Hotline Miami?

#

I recreated his mod and now the mask has better textures and well, it's a full mask instead of a hat

pulsar charm
#

none of my recipes make any sound in the game. these are two of my recipes, both using base game sounds, but neither play. Am I missing something?
I am already importing the base game at the top

hexed arrow
#

Heyo guys can someone give me a Lua example how I would cycle through each clothing item in the players inventory and change the condition for each? I manage to change one item at a time and only by its string name and not its category.

viral sinew
#

This is weird, I made table with HandWeapon class as a key and if I try to getStock() inside of the table, it returns nil instead of the WeaponPart class

azure rivet
bronze mulch
#

Alright

#

Part of my struggles

#

Part 2*

undone crag
viral sinew
#

Is storing HandWeapon class as a key of a table not recommended?

zealous wing
#

I just want to say that I am almost done with my Littering 3.0 mod.
I should have a beta up on the workshop this Saturday for people to try. ๐Ÿ˜„

#

Currently I am working on distros and some other polish.

rotund quarry
#

Hey there, I have a question. It's rather broad and general. Let's say I have complete 3D model of a car with variety of its variants, perhaps some attachments. How difficult it would be to add it to the game in terms of all the coding/scripting/witchcraft? Also, if there's someone willing to help me with that if I'd actually had such model?

bronze mulch
#

@gaunt pendant comrade when are you free xD

zealous wing
gaunt pendant
bronze mulch
#

Decided to delete the whole window

#

I did it

#

Bravo me

#

But

#

When you have more items it shows the rip one or all

#

And when you hover over that it still lagz

gaunt pendant
#

๐Ÿค”

rotund quarry
lunar robin
#

I'm currently trying to stop the loot generation totally, so no loots spawns on the map what so ever.
The servertest_SandboxVars.lua don't have the values for none loot spawn:

    -- 1 = Extremely Rare
    -- 2 = Rare
    -- 3 = Normal
    -- 4 = Common

This is what I did next, unfortunately wouldn't work.
#mapping message

I'd be grateful for any suggestions for my case

chrome egret
#

What happened when you overwrote the distribution like that?

lunar robin
#

Server terminates itself, cursing me for broken overwritten distributions files.

#

I'll try servertest_SandboxVars.lua

FoodLoot = 0
CannedFoodLoot = 0,
etc.

And I'll write back

chrome egret
# wet sandal `ISEquippedItem.lua`

Slightly disheartened that this one file handles all the icons instead of merely equipped items. Have you determined a good way to add a new button entry to this?

lunar robin
chrome egret
#

What's the error on your distribution file when you do it the other way?

#

It'd odd to me that it would break the game, because people have used it in mods before and it's "broken" their loot generation. Curious that you wouldn't be able to do effectively the same.

noble imp
#

vhats the best mods

chrome egret
wet sandal
chrome egret
#

boo

#

Gonna be hard to draw it in the right place with multiple other mods potentially doing the same thing

lunar robin
#

Maybe that'll help

wet sandal
#

I opted to go sideways instead because it was better for my mods purpose.
ISEquippedItems does store the y position of its lowest element though, so mods could use and update that if they wanted to properly add more buttons to the column it seems.

chrome egret
#

Thanks for the advice. I like having my custom UI linked to a keyboard shortcut for convenience, but I think most will prefer an on-screen button like that.

lunar robin
#

I'm not sure what causes this, but after generating a new save on a custom map the zombies seem to be spawned initially in some of the buildings, although my servertest_SandboxVars.lua has the following values:

    ZombieConfig = {
        PopulationMultiplier = 0.0,
        PopulationStartMultiplier = 0.0,
        PopulationPeakMultiplier = 0.0,
        PopulationPeakDay = 1,
        RespawnHours = 0.0,
        RespawnUnseenHours = 8760.0,
        RespawnMultiplier = 0.0,
        RedistributeHours = 8760.0,
        FollowSoundDistance = 100,
        RallyGroupSize = 20,
        RallyTravelDistance = 20,
        RallyGroupSeparation = 15,
        RallyGroupRadius = 3,
    }

I tried generating a new save, multiple times, and each time there were zeds in the buildings. Maybe there is some kind of a prefab for zombie spawn overriding the sandbox options?
BTW, my map has a completely black mapname_ZombieSpawnMap.bmp, so I guess it's not remotely possible for the map itself to generate zeds.

wet sandal
#

I'm not familiar with how zombie spawning works, but the story generator comes to mind in this case.

lunar robin
#

They're turned off as well.

smoky meadow
#

guys does anyone knows how to make custom animation in PZ?

bronze mulch
#

also i found the general fix

#

cuz it turns ouit

#

if you have even more clothing mods

#

both yours and the thing we did yesterday don't work that well

#

my fix idea would be deleting the whole winow

#

i did it

#

it works

#

but

#

it does not when you have two of the same item type in your inventory

#

cuz the one or all still prompts the window to pop up

#

ideas?

#

By ideas i mean

#

xD

#

you reckon where this part of the code is

#

im reinstalling the game

#

cuz i fucking prolly deleted half of the code

lunar robin
fast galleon
# bronze mulch im reinstalling the game

Bro don't edit game files, just overwrite with mod. You can turn it on/off as you want. If you have more mods, check if somebody else also overwrites same thing.

bronze mulch
#

im editing the game files in the first place to check which file is responsible for it in the first place

#

then i will overwrite that part with them mod

fast galleon
#

HM, make mod with all copies lua files?

gaunt pendant
#

@bronze mulch Ctrl+f "CraftTooltip" find where it creates and assigns it. C'mon it's not that hard ๐Ÿ˜ฉ

bronze mulch
#

I would do that

#

i actually even opened the visual studio

#

and did exactly what you said

#

But then my food came

bronze mulch
#

pretty sure its like this are

#

area

#

tho these 3 are just for the option

#

its one script up or down i found it a minute ago

wet sandal
#

I usually just drop a break point with the lua debugger when trying to find which code path is responsible for something. Probably a faster workflow to consider.

#

Instead of editing the files to see a change.

bronze mulch
#

update

#

i forgot i did it yesterday

#

while being mighty drunk

#

loaded a mod that i made yesterday called

#

chineseSquares

#

i dont remember why is it called that

#

but it works

#

Note to self

#

drink more

gaunt pendant
#

Ahh yes, the Ballmer Peak

wet sandal
#

Lol

obsidian portal
#

Does anyone have a resource for loot tables and how to add a new item in?

lunar robin
#

Just add the needed definition and value.

drifting ore
#

Im looking for mods. Is there a mod,

  1. that lets you blend in with zombies, making them not recognize you or something?

  2. That lets you be a zombie in MP and scare your friends?

  3. That lets you control zombies with some kind of... remote or something like that?

#

Id love to know if there are such mods

cosmic condor
#

Those are game-breaking mods. I don't think there are such things.

drifting ore
wet sandal
#

Sounds like it, but its a mod, it doesn't have to be balanced.

drifting ore
#

yeah, i guess so

wet sandal
#

Might be cool if they spiced it up with higher crafting cost, and some random chance some zombies see through the disguise. And make you really slow without removing the disguise.

drifting ore
#

yeah!

bronze mulch
#

there is a mod that lets you >put zombie blood on you

#

so you wont be noticed by them

#

wont change ur model tho

fair frost
#

Maryland State Police, requested by my friend

storm scarab
#

Hey guys I know its silly, but does anyone know a way to delete zombies via Lua? I've tried removeFromWorld() and it always ends in this happening

tame mulch
storm scarab
#

I've been trying to figure that out, But thanks for the feedback

#

Only thing i've been able to locate is ForceKillAllZombies()

#

But obviously that only works to kill ALL zombies, not a specific

undone crag
wet sandal
#

@storm scarab

function DebugContextMenu.OnRemoveAllZombies(zombie)
    local zombies = getCell():getObjectList()
    for i=zombies:size(),1,-1 do
        local zombie = zombies:get(i-1)
        if instanceof(zombie, "IsoZombie") then
            zombie:removeFromWorld()
            zombie:removeFromSquare()
        end
    end
end
#

So looks like your original solution just needs to be paired with zombie:removeFromSquare()

storm scarab
#

Yeah i just figured that out now lmao

#

Thats funny, But thanks regardless

cerulean lintel
#

has no one ever modded out the vision cone for a full 360ยฐ FOV?

wet sandal
#

I'd also be interested in this! A full removal of the vision mechanic would make for an interesting, more arcade-y, experience.

obsidian portal
chrome egret
wet sandal
#

You want to insert, not overwrite

wet sandal
#

If i'm reading this right, this code would insert a new item into the distribution pool for garbage bins with a weight of 3

local binItems = SuburbsDistributions.all.bin.items

table.insert(binItems, "NewItemName");
table.insert(binItems, 3);
#

Doing it like this makes your mod more compatible with other mods and far less likely to break if IS updates the distributions themselves.

warm flume
#

Hey my shit keeps buggin out I was wondering if there's someone who knows how to set up a multiplayer modded server. pls dm me

hexed arrow
hexed arrow
#

how big is a cell? or rather what is it? sorry Im really new to lua

#

bigger than a square and smaller than a chunk?

broken fulcrum
#

each square in the ground = 1 tile

#

so 300 tiles x 300 tiles

hexed arrow
# broken fulcrum 300x300

thank you, while were at it can you tell me how to scan a certain square radius for a certain object ? similiar to the function Notloc mentioned above but instead of cell a 6x6 square outwards from the player

#

I found some community api that should do this but I know too little to understand yet, I hardly grasp it as of yet

broken fulcrum
#

That's go beyond me, I'm as newbie as you to this haha, ask the guys at #mapping

#

if you are trying to make a map

azure rivet
#

Hello, I have a problem with a helmet, when I want to equip it, it does not remove the beard and hair and it does not work with the HatCategory, and if I put it "m_mask 0" the neck is deleted, any advice?

undone crag
#

๐Ÿ˜–

inner blade
#

Would there be a way to add decapitations/dismemberment?

hexed arrow
#

anyone know why this doesnt work? player:PlayAnim("clap02");

#

or does it just get overwritten by another animation the milisecond it works?

#

it doesnt give me an error but no animation plays

#

but the player:playSound("bird1"); works

hexed arrow
hexed arrow
#

and the OnHit event

#

thats how I would do in rn lol

inner blade
#

I guess, but I mean like it edits the actual player model and it like can only occur if you're using a bladed weapon. Like how clothing can only be ripped via guns and blades.

hexed arrow
#

sure it would work the Onhit event has a handweapon variable

#

so if it is a bladed weapon it can only cut and if it were a blunt weapon it changes to a different amputed limb model

#

you can also access the bodypartdamage variables

inner blade
#

Maybe I'm thinking to hard about it since I also want it to function like if a headwear were to fall off, but with limbs.

hexed arrow
#

I mean this could work... maybe add the limb model 2 times, one as a replacement for the body and with masks hiding arms and legs and another as an item that defines as headwear and can fall off. We can also use the bodyTexture function for it to be white and black depending on skin color

#

I mean we could also spawn the limb at the same location as the zombie

inner blade
#

Either or, I'm not the smartest with the coding part but I can do models.

hexed arrow
#

im not good at either one xD

inner blade
hexed arrow
worldly olive
#

Hello!!
Was somebody able to add an OnEat parameter to an item using the new ScriptManager?

I tried this:

local antidepressants = ScriptManager.instance:getItem("Base.PillsAntiDep");
if antidepressants then
antidepressants:DoParam("OnEat = OnEat_Antidepressants");
print("Added property");
end

And I can see that the print happens so I that ran.

Then I have this:

function OnEat_Antidepressants(food, character)
print("Took antidepressants");
end

But that second print never happens. Does somebody knows what should I do to make that works? ๐Ÿค”

willow estuary
worldly olive
#

Hmmm, good point. That makes sense.
Will look at that.
Thanks!!

queen leaf
#

Is there a mod that lets you change the icons/names of various containers? It may make sorting/fetching items easier if I can tell at a glance if this is the Bag Box or the Gun Box

#

Like, if you paint a crate blue, could the crate icon somehow become blue as well?

lunar robin
lunar robin
#

Is there any quick way to run a scripted scheduled command serverside? I'm not familiar with Lua, but, umm:

while (true)
{
  Console.Write("/removezombies -x 300 -y 300 -z 0 -radius 300");
  Console.Write("/removezombies -x 300 -y 300 -z 1 -radius 300");
  Console.Write("/removezombies -x 300 -y 300 -z 2 -radius 300");
  Console.Write("/removezombies -x 300 -y 300 -z 3 -radius 300");
  Console.Write("/removezombies -x 300 -y 300 -z 4 -radius 300");
  Console.Write("/removezombies -x 300 -y 300 -z 5 -radius 300");
  sleep 600;
}
gaunt pendant
lunar robin
#

You are right, dumb question. ๐Ÿ˜„

#

I was thinking of it as from a Lua perspective

#

Forgot about bash

gaunt pendant
#

Screen makes that rly easy, used to do that on minecraft server via screen -X stuff yourcomnand

#

But I'm sure there is also ways with "vanilla bash" to redirect to a processes stdin

lunar robin
#

Simple bash loop

while true; do
    {
        echo 'removezombies -x 300 -y 300 -z 0 -radius 300'
        echo 'removezombies -x 300 -y 300 -z 1 -radius 300'
        echo 'removezombies -x 300 -y 300 -z 2 -radius 300'
        echo 'removezombies -x 300 -y 300 -z 3 -radius 300'
        echo 'removezombies -x 300 -y 300 -z 4 -radius 300'
        echo 'removezombies -x 300 -y 300 -z 5 -radius 300'
        echo 'removezombies -x 300 -y 300 -z 6 -radius 300'
        sleep 10s
    }
done
hexed arrow
bronze mulch
#

update

#

i fucking lost the thing that i made

#

xD

storm scarab
#

happens to the best of us

storm scarab
bronze mulch
#

update

#

i fixed it

#

turns out im really good and deleting shit while sippin on rum

storm scarab
hexed arrow
#

for zombies this doesnt seem to work I cant figure it yet

storm scarab
#

Do you know how to clear hats for example? been unable to do it

#

Or atleast stop them from dropping hats

#

Whatever i've tried nothing seems to work, I've tried to clear their hat and nothing works

#

i've tried clearing their inv and that doesnt work neither

#

Starting to drive me insane

hexed arrow
#

same man

#

exactly the same

#

for players it works

#

ive been messing with it for 2 hours now haha

ruby juniper
#

Is there mod collection you guys like using for Single Player? I intend to do a self sustaining playthrough. Build my own cabin and such.

storm scarab
bronze mulch
#

Alright comrades

#

i seem to have a problem

#

Tiaxx

#

comrade

#

i seek help

#

i happen to

#

seek the function

#

Which

#

eee

#

which changes shit

#

i9 cant quite fucking put my finger on this

gaunt pendant
#

you what now

bronze mulch
#

alright

#

so

#

remember the deleting -<

#

so it does not sort duplicates

#

i deleted the whole window as a whole

#

bravo me

#

problem is

bronze mulch
#

by that i mean 30 mods

#

for clothing

#

SO

#

Keep in mind i did it yesterday but lost it

#

found it again

#

and lost it again

#

SO

#

im trying to find em

#

function

gaunt pendant
#

You need to stop with the cocaine man, it's too much

bronze mulch
#

I tried changhing this

#

ISInventoryPaneContextMenu.addDynamicalContextMenu = function(selectedItem, context, recipeList, player, containerList)
CraftTooltip.releaseAll()

#

cuz it says

#

= function

bronze mulch
#

Im trying to override the original file

#

like the scrip from the thing we did 2 days ago

gaunt pendant
#

find where it does tooltip = CraftTooltip.addToolTip()

bronze mulch
#

i did actually

#

lemme

#

find it again

#

xD

#

Alright so

gaunt pendant
#

what u posted looks correct

#

BUT

bronze mulch
#

i deleted 2 parts

gaunt pendant
#

you haven't removed this, so it still creates the tooltip in the background

bronze mulch
#

fu8ck

#

zxDDDDDDDD

#

IT WORKED REGARDLESS SO I IGNORED IT XD

#

fuck

#

i might have to check the code next time

gaunt pendant
#

well you won't see it ๐Ÿ˜„

bronze mulch
#

problem being

#

i never do it

gaunt pendant
#

So what was the problem, then?

#

oh hold on

#

you're still assigning tooltip ๐Ÿ˜„

bronze mulch
#

e

#

the problem is

gaunt pendant
bronze mulch
#

fuck

#

it also worked

#

alright

#

how do i

quartz shadow
#

the mod that i made and put into the folder manualy is not showing up at all in the mod manager

#

help please

bronze mulch
#

put it in userdir

#

userdir/zomboid/mods

#

Should look like the example mod

#

you put your lua file in the lua folder that you prolly made

quartz shadow
#

i put it in mods folder and workshop and its not showing up next to example mod

gaunt pendant
quartz shadow
#

the way i open the files for zomboid is via steam in browse local files

bronze mulch
#

you gotta put it in userdir

#

go to %appdata%

#

click ur username/windowsname

gaunt pendant
#

%USERPROFILE%\Zomboid\mods

bronze mulch
#

go to zomboid

#

put it there

gaunt pendant
#

copy paste to explorer

bronze mulch
#

Alright chief

bronze mulch
quartz shadow
#

ok did that starting the game up

bronze mulch
quartz shadow
#

i put in users/zomboid/mods and workshop still not showing up

unreal mortar
#

trying to make a mod that changes the appearance of flags in the game. where would I find the flag model to edit and have what I want?

bronze mulch
#

You gotta put em mods

#

Or the actual scrip

#

in two folders so the game recognizes it