#mod_development
1 messages ยท Page 209 of 1
But you will be able to make fully playable maps, that are good, and without any major flaws at the push of a button
I would say it will get you 80% of the way to a "great map" at the push of a button
i'd enjoy that
but didnt expect anyone to actually be there
Yeah... I just have been doing the leg work already for the game im making... or this wouldnt be feasible
Luckily its just changing the output format of my stuff, and making a UI for it. Little bit of setup to handle PZ tiles
my favourite map mod is clear cove because it just feels like vanilla except i don't already know where everything is
My personal main goal for it is to make small mission maps
procedural generation would be another way to approach that issue
Entrance, buildings, objectives somewher eon it, and exit point
Like any of you ever play the old Syndicate game?
Those are super simple, it will handle those no problem
but it will do full on towns and cities
Hello everyone :) i'm actually quite interested in doing a UI mod, but i don't know where to start and it would be my first modding experience, maybe i don't even want it to have something functional just having something being replaced after i edit the files would be nice
fair warning, i personally dont have enough knowledge in the ui to give you any information and i think all the people who know things about the ui are asleep. but from what i heard the ui is quite a bother to mess with
more power to you though, are you planning on just changing it visually or moving around things as well?
changing visually only
well if you dont move a single thing like a button or text at all
im sure you can get away with no coding
youll probably have to find out the file structure for ui elements
i actually managed to unpack the .pack files
and beyond that just have some fun making pictures
so i already have the png
alrighty, id recommend just finding a template mod and base yours off that
you can see the source of any mod in the workshop but the game also comes with an example mod
i think as long as you name your png the same thing and put it in the same place
it should override
at least for me, i replaced the icons for some of the traits and it was simple as naming a png the same name
and putting it in the same place
what if i wanted to make the image a higher resolution?
hmm
i know some games like terraria dont accept things that arent the same resolution
but i dont think zomboid is like that, havent tried tho
once you know it replaces correctly id say just test it out
make the image like 10x bigger and see if it works
to be safe tho make it the same size when your testing to see if its even working
beware zomboid has a dummy mods folder in the source that confused me at first thinking it was where you put unpublished mods
the real one with the template is in your user folder -> zomboid -> Workshop
thanks for the warning
np
i have some part of the UI unpacked
but i'm having trouble with UI2
i'm using that unpacker.jar file someone made in the forums
it works on some files
but not with UI2
hm i havent unpacked any of the files before to tell you
but looking at it ui2 is significantly larger than ui one
which might have something to do about it
its possible it crashes before finishing
i mean they are still kilobytes so not that big at all
but unless the file is corrupted i dont see what other reason it could be
try it on another one
like tiles 1
to see if it works
yeah, actually tiles 1 doesn't work either
it breaks at sizes too large
wether its exporting too many images
or images too big
i remember i unpacked terraria files to make a texture pack and i think i had a similar issues
of course those were pck files not pack
almost every png file doesn't even surpass 1Kb
does it tell you anything when it doesnt work?
instant
yea
i dont think its the file size tbh because what kind of a program cant export kilobytes lol
but its possible its just too many images
i already tried waiting for once
i think i waited for 5 minutes
and still nothing
maybe i'll have to wait longer...?
oh yeah
it creates a folder
with the name of the file
so at least we know it works
i say just try to find a different pack exporter program
no
i was looking at the files however
it might be a bad sign that, all the files that i successfully was able to overwrite were actually the only traits that were not packaged
i never even tried any of the other ones and i know they are packaged because they werent in the source only these ones
im not able to try and see if i can override them right now
you splitted the xml file?
oh right
unpacking what i can
it creates a folder with the xml file
and the unpacker also splits that
to edit each individual sprite
i think
you might want to try and see if you can even overwrite the packed images as it is
you should be able to but i have to test
ill have to probably give it a shot tommorow tho
yeah, i'll try doing with what i have
https://github.com/drandarov-io/project-zomboid-mod-moodle-quarters/tree/master/source
so looking into it you def can replace them
Changes one additional quarter of the moodle background to a square for each moodle level. - drandarov-io/project-zomboid-mod-moodle-quarters
this mod does so
i been trying to learn java for a while due to school and simply better myself as an IT guy and a lot of pepole recommended that i pick a porject and wrestle with it to improve at a language is learning java through trying to mod project zomboid a decent idea? would you recommended it? i was considering this or minecraft really
well
so, i made two new textures, but now i don't know how to turn the pngs into a xml :/
zomboid modding uses lua
zomboid source is java
so unless your making a mod that needs to manipulate the source
you wont learn much java here lol
maybe a little from decihpering how it works to make what you want in lua
since looking at the source is probably the best documents for modding zomboid has at the moment
if you simply want to learn java
probably do minecraft or another game that needs java
if you want to learn lua or practice coding in general
than yea zomboid isnt bad
Fax
ill be totes honest, dont really know why you need xml
it seems they just repack the pngs
You can start very entrance level with skill in modding in zomboid once you understand how all the pieces work together
actually, true, ill try without the xml
Might be better to do a project on coding for absolute beginers though if theyve never coded a single thing before.
its kinda disheartening how easy it is lol, i started zomboid modding as an excuse to challenge myself to practice coding stuff
but going from c# making a game
It makes it accesible for more people\
I went from C# making games to this
So it was a pretty easy transition, C# and lua are structured very similarly
Thats were I started and its what was taught in when I went to school for game design as wel
i want to learn java doing a project i like such as video games mostly but ye i guess PZ Is like world of warcraft where most stuff are in lua
ui stuff
college is a bust so far lol
But I chose hobbiest route after school and enjoy making mods for Zomboid then I did making games for myself
ive taught myself more stuff dicking around in my room than the time its taking me to even get my first object oriented programming class lol
its for a college class too cuz the ooc class is dogshit
lol
I learned more in the 6 months after I left school when I was working on my own project then I did while I was in school
yea
im doing it for the piece of paper for money
and the excuse to not be working full time
so i can teach myself and make game lol
i got a full time job as an it helpdesk to gain experiance for cyber while studying but i still have to take the exam next month and i need to get better in java
and python really
When I left school programming was my weakest strength and Modeling and game design were my strongest. 6 months after school programming was my strongest
ye im not worried about python im making java a priorty but most courses are so boring in mundane i tried MOOC and netbeans did not click with me at all
doing c# stuff in godot for 2 years before i was in the college door, by the time i get out there will have been no point lol. at least ill have had the "college experience"
stuff kept getting borked if i dont use intelij community edition
The piece of paper for game dev school is worthless, you dont need one. But learning where to get started, the figurative tools they teach you to teach yourself the literal tools in the future and the connections are pricless
oh im aware especially for coding careers
most the people jobs want to hire are 7 year old started programming prodigies
failed highschool never went to college
but damn can they write lol
make more money than anybody
yea
im not worried about dev carrers since im IT side but carrer wise u guys look like u have it the roughest
if ai takes game dev from me i can gurantee you ill be the drunk homeless on the side of the street
im not going for no other job lol
that was it and they took it from me
lucky you can enjoy that
i took a two year IT course since i went to a trade school
So I left the game industry to go back into construction because I like working with my hands as well and more and more these days im seeing it as I probably made the right call
(it was to learn coding)
lucky you
im in 2 year it couse in something simmilar to a trade school
they suck hard but oh well its just a box for hr to check
Its going to take a lot longer for AI to come after my job security
look i only got one goal in life and thats make a video gams before i die
if the bucket list gets checked off by some damn robot
then the buckets bouta be me
that or move to the woods
learn widdling
sell wooden gnome statues for 50 bucks
and fish for food lol
While you live in the wood Ill be living in my stone castle built by my own two hands.
Going down to homedepot hiring myself some cheap white colored labor
starvation would knock that will down
il belive you when u threw around 3k application and worked a hard non skilled manual labor
i did my highschool dead end job dues lol
i wanna stay out the system not get back in it
so what did they teach you? my hs jobs taught me to KILL for a chance to work in an office
well one of them taught me
u have no idea when i got this helpdesk job how comfortable and happy i became
dont work for restraunts
As of right now I dont need to remap my skills. Started in trades young and now I can potentially try whatever I want in life as a career knowing I have 10 years of Masonry experience to fall back on at anytime
I get a 4 month paid winter vacation from being a seasonal worker.
so I cant complaine
Having resturant experience is good to fall back on when things are really desperate
same
My city is made of bricks and stones and will need work forver. Itll be a very long time before AI comes for that
I worked as a dishwasher off and on for a collective of 6 years working.
Its not the most glamorous but it pays the bills when things are desperate.
i think once the damn ai gets good enough to take masonry
nobody has a job anymore lol
we all just submit under the thunderhead who knows all
and runs the perfect economic system
and my last dishwashing job was an absolute banger of a resturant and atmosphere, met my long term partner who was a cook there as well. Most fun I ever had in my life
either only the elite lives or we reached etopia
You should watch the second episode of the Animatrix. Hits very close to home right now
is it a sort of
ai becomes god and nobody needs work anymore thing?
thats what i was refrencing with the thunderhead lol, just a book not a show
No its about how humans used AI and how AI eventually rose above humans
It doesnt happen with a bang
It happens with tensions of the humans fearing for there jobs
because the machines were better at it and the humans were scared to work along side them as equals
If you have never seen the Animatrix and only the movies then your missing out. I never liked the movies but that show is a banger
i aint seen either lol
i sit at home coding zomboid all day i watch like 1 show/movie in a blue moon
buttttt, ill write it down
maybe for one boring popcorn night
it sounds cool
and anything described as a "banger" you know means its got some merit
Its an 1h 45 minute movie broken down into 9 small stories
I only use that word for works that have merit
Pursue a skilled construction trade. That's something Ai machines will never be able to do
I would not trust a brick laying robot
yea but brick laying robots cant really do it as fast, practical, or like
do the cool brick designs
the only way your gonna lose your job before the takeover is if we find a material better than brick
The robot misses everything a skilled hand and eye doesn't
so much better that we stop using brick entirely
Masonry is already already not black and white data points and restoration masonry which is what I do is ever more grey.
I'm an electrician by trade. So much of my trade is done by feel it's something a robot can never do
Yea sometimes the answer isnt just build a perfectly straight wall
Especially working on older houses
Those things are chaulked full of problems you gotta work around
hah
i see what you did there
thats a masonry joke right there
wait no
i thought you said caulk which i dont even think is really masonry lol
It is.\
oh okay good good
Not something used every day but people have some for different use cases
I dont bother with it, Unless I need to chauk like lkek 30 feet of wall or floor.
and if its inside id rather use a laser level.
Don't worry, they will.
who knew that the nerdy mod development channel of a zombie game would house more than 1 hard working tool tradin laborer
Yea I know,
The mod development channel last night and this morning has been the popping off with really interesting topics about not what the chanel is intended for.
I honestly dont know what the outside world is like on this server I just hang out here
i dont care and i dont think the server administrators do either
there is like 5 repeating people that use this channel
Neither do I
When ever a someones got a question it gets answered right away
i wonder if the devs ever pop in here
They do\
Some of the Devs started here
Yea the guu who did the tow truck mod
and lockpickin
I go to other channels and I feel so alien, its like what people just sit and enjoy playing the game and dont spent 90% of there time in game not playing it?
Oh odd
yea its cazy
i spend all my time makign my mod its so weird when i actualyl get to play it lol
How fiendishly drole
its like skyrim moddin
two differnet games
both very fun
i dont mena zomboid and skyrim
i mean skyrim and skyrim modding
It takes me at least 3 hours of set up just to start playing because I gotta go through everymod I want and what I want to do int he game.
and if I gotta make something custom then its longer
I gotta start planning the day before the night I want to play
as long as i got fancy handwork and dive through windows
im good tbh
i too have liek a 100 mod playlist but man
my friends and i never last that long to see half of em
and im too lazy to perfect the craft of the modlist right now
I think this winter I want to focus on content creation for PZ. So I can enjoy playing it a bit more and make custom mods for it to keep up with my modding side
I have a list of my basic mods I use all the time (like 40-60) and then I build from there to cater to specific things I want to do
well correction, my friends are not patient enough nor anybody should be
to wait 2 days for some guy to make a modlist
Someone knows how to create zombie free zones which are used commonly with community centers? I hope this is the correct channel to ask...
if i need this one
well i need that one
and then i need that one
and oh god we are 200 mods deep
Everytime I gotta go through every single one then do a second pass to make sure I didnt miss anything
I got like 600+ mods in my library
you mean
like gameplay?
like clearing out a cell so no zombies?
oh waitt
im dum
yea im not sure how to do that but i imagine its possible
It is the right channel you just got the wrong people atm\
if it comes down to it just make a mod that script deletes every zombie in that area
It could
It should
personally part of the zombioid charm is that your never safe
But it seems you need to define the zone
itd be very fitting if the "community center" kept getting strays wandering in
Let the people eat cake.\
sorry my strickly vanilla-like diet came out
Without the righrt vocabulary to know what it wouldbe been called they could be hard to cold search for
Ooh a zone for no zombies - ah it's a Konjima mod. ๐
Also, working on some game night QoL. Wouldn't mind any feedback anyone's got.
This showcases tooltip zones per piece. Most useful for boards, and cards I imagine.
ive been meaning to try this mod, awesome lookin thing love when you can just do real life stuff in zomboid
having not used it yet, gif looks good
i would say if your extra fancy do a little outline around the selected square buttt
its not super needed and i think that looks zomboidy nuff
oh so true
monopoly does collab game boards with like everything so it would make sense
id say im a willing artist for the capitalist spiffo but it seems you already made that thing yourself
i just think itd be fun to draw
Oh gosh, yeah I'll just poll in my own code
I did but, I'm far from good at pixel art. Usually spend an ungodly amount of time for something passable.
Also, added scaling for 1.5x and 2x, so I may need to redo everything again ๐ญ
Oh no you don't need to scale the pixel art do you?
Would it be possible to make game UI use nearest neighbour filtering instead of bilinear?
Probably not currently I assume that's why it took the devs till now to make ui properly scale
Good idea tho
And I might be wrong
There's a patch for Inventory Tetris that already does that, which is why I asked.
im glad to be wrong
Whats it called? Ive never aeen this
Neat
wierd question
but would it be realistic if the Hemophobia trait would be able to be lost?
the same way in how the become Become Desensitized mod works?
like after killing 250 zombies you shouldnt really be afraid of some blood around / on you right?
phobias as far as im aware
are an "irrational fear"
i dont know if they can go away fully
i mean it seems like it should for that though
but then again irrational might also mean yea youve killed 10 thousand zombies and know like
the blood isnt gonna hurt you
phobias are not irrational fears
yeah like in a "face your fears"
there is nothing irrational about the fear of spiders
Phobias are overly strong fears that are often engaged in the mere presence of a thing
true
you know a tiny daddy long leg isnt going to hurt you
but certainly not irrational, spiders are fucking creep, and gross, and many (and many more in the past) are poisoness
but your still scared shitless
Just because the fear is not useful against a single type of spider, does not make it irrational
fear of the dark
It may seem irrational in a particular overly constrained context, but that is the power of perspective
some people have a fear of clowns
fuck clowns to
specific harmless bugs like ladybugs
this conversation took an interessting turn xD
id say its irrational to be screaming and crying in fear of a daddy long leg
phobia is a phobia but by the term its not a real threat
Clown profile over laps with pedo and serial killer to much for my liking, ill pass
it does occur
its not clowns faults that the job of being a clown gives you such easy access to be a horrible person
Look, anyone trying that hard to make other people laugh and smile, where wearing a ton of makeup, and wierd clothes... aint all right up in the head, its that simple
so like
case and point robin williams
not a pedo or serial killer, but did off him self from depression, and he wasnt even a clown... but did those thigns alot
i try way too hard to make people laugh and smile
all im missing is the makeup and funny clothes
but hey if it makes people laugh and smile ill put it on
Well, as long as you stay away from the makeup and clothes, ill only be worried about you offing your self, not playing touch the no no spot with kids or eating your neighbors
im calling up the national clown association
i promise you your birthday this year
it will be crazy
balloon animals everywhere
biggg party
oh im not afraid of clowns, I just think they are creepy wierdos
my brother on the other hand... would shit himself
alright im outtie, work holiday lunch at fancy grill place. peace out
enjoy the food, keep an eye out for the chef
i heard they like to wear red noses from time to time
and funny wigs
anyways gamer bro
seems there is points for both sides
just make the mod to make you lose fear of blood
its modding the great thing people are just gonna use it or not if they agree or not
yeah il think about it
Hi! I want to try something different on a private server for myself and some friends, but Iโm not sure if what I want is possible, even after quite a bit of research.
I want to set up my mp server so that I can regularly update the map files without losing progression on things like character stats and placed objects. Player construction would be disabled. I understand this is an issue for most servers. Is there anything at all to make this possible? Iโm open to any/all ideas for a workaround.
I dont think its a bad idea but I dont think a phobia ever goes away. I could imagine that it would be come more mangable as you became more desensitized.
Like not completely removing panic but leaving you at the first moodle state.
That way it doesnt completely leave you and still gives you a bit of a debuff but you can sleep at night now
its not impossible. Ive done it with an offline world but it wasnt 100% successful.
Theres a program that let me do it. The guy whos tutorial ai was following did it in MP liv3
He did it though in like build 35. I tried in build 41 with limited success
Thatโs helpful to know, thank you! Do you know how I can find out more? Being able to do update the map in mp reliably would be a massive game-changer for my project haha
Your going to have to wait till I get home. Ill DM you
No worries, take your time. Thanks!
Where can I find the moodle background texture thingy?
For more information I was planning to try to make it more colorblind accessible for my brother
Oh shit there is blue red
Still I would love to know where to find the background for the moodles
you can use the mods or look at how they do the job and replicate.
Do your own mod. If it is just a copy, no it is not ok. But if you inspire of learn from them and credit, that's good.
Gotcha
Can someone in a bright mind explain me why in the world my server suddenly decided to stop itself by quit command into socket?
LOG : Network , 1702505803133> 8,530,493,192> *** SERVER STARTED ****
LOG : Network , 1702505803133> 8,530,493,192> *** Steam is enabled
LOG : Network , 1702505803133> 8,530,493,192> Server is listening on port 16261 (for Steam connection) and port 16262 (for UDPRakNet connection)
LOG : Network , 1702505803133> 8,530,493,192> Clients should use 16261 port for connections
LOG : General , 1702505803133> 8,530,493,193> LuaNet: Initializing...
LOG : General , 1702505803133> 8,530,493,193> LuaNet: Registering server listener...
LOG : General , 1702505803133> 8,530,493,193> LuaNet: Initialization [DONE], triggering events for 'LuaNet.onInitAdd'.
LOG : Network , 1702505803133> 8,530,493,193> DISCORD: token not configured
LOG : Network , 1702505803133> 8,530,493,193> *** DISCORD DISABLED ****
LOG : General , 1702505803134> 8,530,493,193> ##########
Server Steam ID 90178694834704412
##########
LOG : Multiplayer , 1702505803149> 8,530,493,208> [MPStatistics] mem usage notification threshold=16,320,875,520
LOG : General , 1702505804505> 8,530,494,564> command entered via server console (System.in): "quit"
DEBUG: Multiplayer , 1702505804625> 8,530,494,684> QuitCommand.Command > cmd="quit" user="admin" role="32" unknown connection"
Literally loads up and quits imeddiately from some unknown source?
is there a socket or control file passing commands to it?
OS/Platform?
cuz 'admin' and 'unknown connection' translates to a local character device passing commands directly to the java program
/bin/sh -c "echo save > /opt/zomboid-debug/Zomboid/zomboid-modded-debug.control; sleep 5; echo quit > /opt/zomboid-debug/Zomboid/zomboid-modded-debug.control
/bin/sh -c "/opt/zomboid-debug/start-server.sh -servername modded-debug </opt/zomboid-debug/Zomboid/zomboid-modded-debug.control
and when the zomboid-modded-debug.control file is present, but not a character device, it automatically triggers that stop behavior (the first block I posted)
Anyone figure out a way to setHighlight() a tile without the highlight being obscured by snow?
The real question is... Did anyone create the phone number mod while I was working today?
i haven't but if you sit on it too long it is a risk
Lol, im ok with someone making it before I get there. Like I said I got lots on my list to do
square highlight has these issues with grass too. As an alternative you could use some of the WorldMarkers.
highlight for tile... this might not be your use case.
So I seen this mod, which gave me an amusing idea.
https://steamcommunity.com/sharedfiles/filedetails/?id=3046040846&searchtext=
Mod Idea: Add a cd with Party Rock anthem by LMFAO to the game. Then anytime someone plays it, all the loaded zombies start dancing
bonus points for adding a Thriller CD and dance as well
It seems like it may work out. However, can you make the marker square? I'm still messing with it to see what it can do.
The jukebox can be picked up and becomes an inventory item but it does not seem to have an moveable item in the scripts folder. Is it still possible to have this item become the output of a recipe? If I just create a moveable in this format will it work? item Mov_FoldingChair
{
DisplayCategory = Furniture,
Type = Moveable,
Icon = default,
Weight = 0.5,
DisplayName = Folding Chair,
WorldObjectSprite = furniture_seating_indoor_01_60,
}
I think there are workaround for recipes using movables. You could always mess with the Lua parameters to call on test and on perform functions.
yes, e.g. Result: Moveables.solarmod_tileset_01_0,
testing to see if it will let me use Moveables.recreational_01_1 as a result
ah, just what I was thinking. I figured I was overthinking this
you can pass two strings for the marker, it should be possible to add more highlights.
"media/textures/highlights/" + var1 + ".png"
Yah I just noticed that. Not too savvy on what kind of texture to make but I just took the image size and through a white transparent alpha on it.
There is FIFO service called zomboid.socket that is ran by server and the only entity that passes commands into it is me. And it suddenly stopped after few server restarts. Thus why I asked why and what sends quit command without my knowledge into server that just started up. There cannot be any context of any user or player because if you look at timestamps and logs
LOG : Network , 1702505803133> 8,530,493,192> *** SERVER STARTED ****
DEBUG: Multiplayer , 1702505804625> 8,530,494,684> QuitCommand.Command > cmd="quit" user="admin" role="32" unknown connection"
How in the world would somebody silently join in a span of 1.5 seconds of server startup?
I don't have any cronjobs for such ridicolous action either.
like I said, if the socket loses character device status (haven't figured out that part yet), for whatever reason, the java process receives a 'quit'
did you get it restarted?
for one of ym server instances, I can just reference the service and it brings the socket up automatically.
loses character device status Can you elaborate on that?
Not really. It is set to be a character device. Something happens. And the file is still there, but the kernel stops caring about it
the 'something happens' is the part I'm still trying to figure out.
but it just means I have to be a little intentional with start/stop sometimes
I mean what do you call "character device"?
the 'FIFO service' you were referring too
it's a First In First Out character pipe/socket
root@apocrypha:/opt/zomboid-debug/Zomboid/Server# cat /opt/zomboid-debug/zomboid-modded-debug.socket
[Unit]
BindsTo=zomboid-modded-debug.service
[Socket]
ListenFIFO=/opt/zomboid-debug/Zomboid/zomboid-modded-debug.control
FileDescriptorName=control
RemoveOnStop=true
SocketMode=0660
SocketUser=zomboid-debug
SocketGroup=svc_zomboid
I mess with a lot of block devices and other UDEV items, so... I always differentiate
ye, my FIFO is running and something for some reason kept sending quit into it, until it randomly stopped after 2-3 restarts through systemctl
according to daemon procedures of Stop/Start there is not such thing to happen from zomboid.service which is the parent of it.
so.. what in the actual fuck then
best bet in those cases:
systemctl stop zomboid.service
systemctl stop zomboid.socket
rm -f /path/to/socket_file
systemctl start zomboid.socket
systemctl start zomboid.service
yeah - if setup right, the service is suppose to create and destroy the socket as a part of it's startup, but alas
you think its because the device is busy by some pid that daemon didn't recognize (aka socket stuck?)
but if the system doesn't see the socket file as a character device - just a regular file - the daemon receives it as a 'quit'
OH FUCK TRUE
no, because I've seen it when my system has fewer than 1024 pids active
last command received because of that?
even lsof isn't oversubscribed
Because guess what is the last command to it?
quit obviously is the last after any restart.
fuck me.
I suppose an 'echo > /path/to/socket' would work too, but that still doesn't register it with systemd and udev
er maybe that's just dmesg... either way - still doesn't register the socket
yeah, well at least I now know that its better to kill socket file for sure.
yes. remove it and restart the whole stack
liek I said, it's wierd, because the service doesn't start the socket on it's own, but a stop/start (via restart) works fine
and my production instance works flawlessly
๐คทโโ๏ธ
root@apocrypha:/opt/zomboid-debug/Zomboid/Server# lsof |grep -v kworker|grep -v lsof|wc -l
23127
root@apocrypha:/opt/zomboid-debug/Zomboid/Server# ps aux|wc -l
251
yeah that happened when I messed with daemon by restarting it multiple times when Steam was doing their poopoo (maintenance)
HEY! Someone who might benefit from some toys I've been writing!!!
then I noticed server just started receiving quit command, came to solving this on my own by stopping the whole stack manually
simple, but it works - still need to make it require $1 to be 'all' or something - or also allow it to skip modules and just update the app and restart
#!/usr/bin/env bash
steamfile='tmp/update_mods.txt'
servername='modded-debug'
ini_file="${servername}.ini"
printf 'force_install_dir /opt/zomboid-debug\n' | \
tee tmp/update_mods.txt
printf 'login anonymous\n' | \
tee -a tmp/update_mods.txt
test -n "${1}" && \
printf 'app_update 380870 validate\n' | \
tee -a tmp/update_mods.txt
for wi_id in `grep '^WorkshopItems' Zomboid/Server/${ini_file} |cut -d= -f2|tr ';' '\n'`
do
printf 'workshop_download_item 108600 %s\n' ${wi_id} | \
tee -a tmp/update_mods.txt
done
printf 'quit\n' | \
tee -a tmp/update_mods.txt
/usr/games/steamcmd +runscript /opt/zomboid-debug/tmp/update_mods.txt && \
rm -f tmp/update_mods.txt
echo "servermsg 'server restarting in 5 minutes. Get to safety'" > Zomboid/zomboid-modded-debug.control
sleep 180
echo "servermsg '2 minutes left'" > Zomboid/zomboid-modded-debug.control
sleep 60
echo "servermsg '60 seconds'" > Zomboid/zomboid-modded-debug.control
sleep 60
echo "servermsg 'going down for restart now'" > Zomboid/zomboid-modded-debug.control
systemctl restart zomboid-modded-debug
runs from the zomboid user's home
and steamcmd requires a fully qualified path to the script file
you wanna funny thing?
I like funny
#!/bin/sh
# Script for checking and restarting server when mod updates are in order
# Use crontab to add this to queue but consider sleep timers to not overlap with cron job.
# Example:
# */10 * * * * /bin/sh /opt/pzserver/checkmods.sh
SOCKET=/opt/pzserver/zomboid.control # Path to your zomboid server socket, FIFO service should be installed as recommended in Dedicated server manual for it to work
LOG=/home/pzuser/Zomboid/server-console.txt # Path to your server console log to read commands responses
echo checkModsNeedUpdate > $SOCKET;
sleep 10;
if grep -q "CheckModsNeedUpdate: Mods need update" $LOG; then
echo servermsg \"WARNING! Server restarts for mod updates in 5 minutes\" > $SOCKET;
sleep 240;
echo servermsg \"WARNING! Server restarts for mod updates in 1 minute\" > $SOCKET;
sleep 30;
echo servermsg \"WARNING! Server restarts for mod updates in 30 seconds! Logout NOW!\" > $SOCKET;
sleep 30;
systemctl restart zomboid;
else
echo not found
fi
my lazy ass crontab that finds out mods has to be updated 
where's the checkModsNeedUpdate function declared?
In server commands, its a basic console command of a server from IS
oh really? That's awesome
I'l lbe working that into my setup. Thank you
I wrote a script that reads the mods line and pulls all the workshopItemIds in the same order and creates that line. That was just the first goal.
I'm writing parsers for the lua and items/recipes/etc to verify functions and check for overlaps/overrides. With my work schedule (our team of 5 is down to 3 right now), a couple more weeks of time and effort, and I should have it.
should be able to punch in a workshopItemId, the system will pull it down, scan the mods - a simple sqliteDB to help with storage and relationships - and be able to verify/correct conflicts and order on the fly
my denizens would shit bricks if I setup restarts on a cron-check - I guess they would get used to it, but... probably better to bot it from my discord
finally - another *nix nerd.
the part that seems easy on it's face, but I'm willing to bet will be super difficult: testing the map mods as a part of the aforementioned script
yikes, gl
danke
Perfect
just... why
smdh
it begins:
spectrm@madmax:~/Zomboid/workshop_processor$ ls -l app/models/
total 24
-rw-rw-r-- 1 spectrm spectrm 74 Dec 14 08:38 application_record.rb
-rw-rw-r-- 1 spectrm spectrm 53 Dec 14 08:47 cell.rb
drwxrwxr-x 2 spectrm spectrm 4096 Dec 14 08:38 concerns
-rw-rw-r-- 1 spectrm spectrm 52 Dec 14 08:47 map.rb
-rw-rw-r-- 1 spectrm spectrm 62 Dec 14 08:42 mod.rb
-rw-rw-r-- 1 spectrm spectrm 60 Dec 14 08:42 workshop_item.rb
<m_underlaymasksfolder> adds custom mask + vanilla mask
What I really wanna do is make a custom mask only appear
Maybe by making a mask that is empty I would probably be able to make custom masks show and empty vanilla mask
its a .class file? java?
is it possible to identify a sprite in a square that is not an object? To find most sprites I have been able to check for objects in the square and read the sprite name. With this one it doesn't see it. industry_02_67 is part of the "silo". I tried spriteName() but I don't think it is seen as an object at all.
all tiles should be objects
Thank you, I must not be addressing it right then. I will try again.
is there a way to detect if a zombie cannot path to a player?
Thanks again, it was getTextureName() that I needed.
Anyone aware of a method to display temporary markers on the map - like a simple square? Maybe a mod that already does that that I can check out?
For context, I am trying todo something similar to auto-marking a safehouse/zone on the players map when itโs created.
Apparently there are MapMarkers and WorldMapMarkers. I have seen the usage of WorldMapMarkers, but not MapMarkers.
MapMarkers for the map, WorldMapMarkers for the world itself.
aight i havent messed around with multiplayer bugs before to know how your exactly supposed to make stuff eun for all players,
i assumed it would be just put the stuff in the shared folder buttttt
right now i've got two things
I have text the player says that i want to show to all players, but currently only shows on that players side
and i cancel the player from tripping when bumping into zombies, but they still visually trip on other peoples screens
what is the usual way to fix problems like these?
use client/servercommands to transmit information to the other players
do you have an example i can see?
ive abandonded google as a resource when it comes to zomboid modding lol
it has never served me once
but you know what maybe you right
let me see what i can find
Odd... It's still one of my primary gotos.
well i uh
use bing currently lol
too lazy to swap it
and bing is just terrible at giving good results
Chat gpt has also been helpful
chatgpt seems to just collect stuff from google anyhoo,
i tried it for a bit but i felt guilty lol
not really, but i can explain the concepts:
when you call sendClientCommand(player, module, command, args) from the client, the event OnClientCommand will fire on the server with the arguments module, command, player, args
player is the player sending the client command - if it doesn't matter which character on the client is sending the command, or if it doesn't really belong to a character at all, you can omit that argument and the game will assume it's player 1
module and command are strings - you can technically put whatever you want for them, but usually module is the name of the mod, and command is the specific instruction you're sending to the server
args is a table - any additional information you need to pass to the server should be here. you cannot send objects over the network (as they are really just a memory location specific to that instance of the game), only basic types
typically, on the server you would have an OnClientCommand handler that checks if the module is your module, then fires code based on what the command is, using the arguments:
--on the client
sendClientCommand("MyModule", "MyCommand", {})
--on the server
local OnClientCommand = function(module, command, player, args)
if module ~= "MyModule" then return end
if command == "MyCommand" then
-- do something!
elseif command == "MyOtherCommand" then
-- do something else!
end
end
Events.OnClientCommand.Add(OnClientCommand)
similarly, when you call sendServerCommand(module, command, args) on the server, the event OnServerCommand will fire on the client with the arguments module, command, args
you can also use sendServerCommand(player, module, command, args), in which case the command will only be sent to the client that player is from
you cannot call sendClientCommand from the server, and you cannot call sendServerCommand from the client, so if you need two clients to communicate, you have to send a client command to the server, which then responds by sending a server command to the client(s)
untrue! it also just makes things up completely and insists they're true with full confidence ๐
i know lol
i remember i was having an issue in C#
and im like ykonw what
let me try this gpt thing
the dang robot just lied to my face, told me the wrong answer
When it doesn't know. But it seemingly has a deep knowledge of the objects and functions available in the zombie/ java classes
does it?
it'll definitely be of more help as just an assistant to someone with actual experience, but i've seen people asking for help with code they've generated with it and it's just entirely made up functions and structures
I use it to prime the pump for teraform and helm (kubernetes) work, too
thanks for this btw
i didnt expect a giant concise guide on how to do it when i asked lol
The more exact you are with your request, the better your results will be
Yeah
Albion is an angel
๐
a popular pattern is to make a table of functions where the keys are the command names, so you can just do commands[command](args) instead of using an if tree
but i thought it'd be better to keep it simple for demonstration
Reason: Bad word usage
NUH UH UH
Indeed
So I'm brand new to zomboid modding, but not new to lua. From what my research tells me the best way to detect if a zombie is within range of a light source, like a lamp, would be to run a function with OnZombieUpdate and then search for the tile within the radius of the individual.
The only other thing I saw was just browsing through the modding page, but I assume I would need to have some java knowledge to utilize the api.
you can get the light level of the square the zombie is on
which is likely much more performance friendly than zombies looking for lamps around them every frame
this is all I do for one my mods that needs the light
for some reason you need to send the playerindex, but im not sure if that would actually change anything using it for zombies
Can somebody make a simple codelock mod?
Combination Padlock is already a thing, no?
It can be done... For a price
Ill pay with the blood of my enemies
what's the exchange rate of blood for eggs?
Depends if they eggs come from chicken from a cage, hall or from the field
and if the chickens are vegan or vegetarian
If you feed them chicken then the chicken will be more chicken = higher price
I would ask my demon accountant but he died by a Slayer guy unfortunately
hate it when that happens. So hard to find good help these days
do you want prion zombies? Cuz that's how you get prion zombies...
Anyone know a way to figure out which zpop files relate to areas of the map, in a similar way to how BTSE chunk list viewer can give you those files for the map chunks?
Due to the way my mutant spawn system works it can get exponentially out of control, and also need to ensure I reset the zpop for the instanced dungeons that get reset on server restarts but currently this means that faction members are logging into their HQ being extremely occupied, same thing with Hub zones, I know I could just prevent zeds existing there but it's a bit too clinical and easily abused, if I can't find away around it then I'm going to need to write a whole new mod just to delete zeds from the HQ's based on the players faction and the name of it for the first player that logs in 
zpop_50_9.bin
first number is x, second is y
so that file corresponds to the zpop in cell 50,9
Ohhh, so each file relates to a cell and not a chunk, this makes a tonne more sense thank you so much ๐
I believe. Open to corrections if I'm wrong.
Would totally stand to reason as there is way less zpop files than map save files
Anybody knows which mod is the one that adds random sturdy/big/sharpened/dull/five-star etc to melee weapons?
not sure where to ask but is there a mod that increases smoking time? the current duration for smoking doesnโt work well with the Smoker and smokers sound mod
thank you ๐
My pleasure ๐ซก
WIP of my new map mod, it connects to my previous mod (Leavenburg)
Link? ๐ฅบ
From Marvel's The Punisher
That mission in vice city where you had to bomb a construction site made me want to bomb a puppy orphanage so I made the van that starts those godawful minigames
They don't let you remote control exploding helicopters designed to cause an aneurism in the player yet but i am considering it
Ooh what mod
Common Sense
Oh sick that's one I always use. Good job on it btw
Thank you! Glad you like it!
Well done! And wonderfully well deserved :)
Hey mod chat, I've had a challenge idea centered around a recent mod, the loot boxes mod, where i can only use loot from those boxes
problem, some of the recipies take the Money item, and as far as i know, money in zomboid only spawns in 2 things, cash registers and survivor stashes
I wanted to figure out a way to make a mod that makes money spawn in every type of container to make it more interesting
Actually i found a mod that makes zombies have a chance to drop money, sorry
this was a good direction for a check, but I also want to get the color of the light being casted. Tried using https://projectzomboid.com/modding/zombie/iso/IsoGridSquare.html#getLightInfluenceR() but tbh I have little to no java knowledge.
declaration: package: zombie.iso, class: IsoGridSquare
I'll prolly take a short class on basic java to get a better understanding after I make this first mod
If you have no Java knowledge you should be good honestlyish, depends on if your tinkered around with languages similar to Java or just lua
I've never written a thing in Java but I know enough c# and am able to somewhat decipher the source
But hey nothing wrong with learning lol
If anybody here has experience with UI and graphic design and would like to help me out on a mod as a contributor, please send a friendship request ๐
are the payphones the only phones in the game? I thought there was a desk phone but I can seem to find it
Just need someone who knows how to make UI look good lmao
There's them and those mobile phones. The mobile phones spawn on desks very very rarely.
Thank. I must of been thinking of the mobiles.
What do you qualify as good / what are you looking to do?
i can give advice but i dont think i could lead the charge exactly lol
depends on what you need
what are you making ui for?
hi can someone help me to make a mod? i want to buy one
I just had an idea about a mod to make the game a bit more hard/realistic in a small way, it would be something like not telling you certai things like the ammo in ur gun unless u inspect it maybe or reload/unload it. Would be cool
That sounds pretty neat
I look forward to seeing it and testing it out once you create it
Hey everyone. I am planning on starting to mod Project Zomboid. I have experience in C++, and as far as I understand PZ is programmed in Java, so how hard will it be to learn Java?
I am planning to make a few simple mods first. I plan on adding sharpening.
Items will have a certain level of sharpness ranging from 1-100%. The sharper an item is the more damage it will do, and the faster actions it will have (by actions I mean stuff like crafting items with knives, or chopping down trees).
Items will be sharpened using a whetstone (which has its own durability) which will be somewhat common to find, especially in rural areas and survivors houses.
Later on I plan adding other stuff like different types of whetstones (like japanese whetstones who are faster to use, but wear faster too;
guided sharpeners which do not need a very high maintenance skill, but are extraordinarily rare to find;
and arkansas stones which are the most plentiful and last long, but sharpen very slowly.)
Note: In my most basic version on the mod I plan on making, sharpening will not be tied to maintenence, the skill of sharpening will always be constant.
In the far future it will even include stuff like making wood handles for tools like axes.
Now, how hard will this be to mod (the most basic version) and how do I get started?
well zomboid uses lua for modding, so this is a huggeee downgrade in terms of difficulty level lol
i recommend looking at this page really quick
but when you get to the part that says stuff about intellisense
the guide on how to setup with intellij is outdated
this is a fork from that guide that tells you the current way
there is no big document currently on zomboid modding as far as im aware
but this https://projectzomboid.com/modding/ website is pretty helpful in just seeing the things you can do with objects
other times your gonna have to dig around with the source code which that guide for intellisense also has you do
package index
thanks for the information!
np that should be enough of the basic stuff to get you to the point where you are finally able to actually write some code
How good is zomboids source code to follow?
ehhhhhhhh
Is it easy to understand
that is heavily dependent on your knowledge in coding or not
if you know java or something similar
yes
but either way it is still a bit
much
at times
you can figure anything out in time
I know C# and C++ but Iโve had previous experiences trying to follow source code and it just sucks lol maybe just a me thing
yea its gonna be the same thing here
nah i get that
i know c# too but sometimes that shit from someone else is hieroglyphics
Iโll probably check it out anyways after I finish my map mod
Doesnโt hurt to try 
hey
so has anyone here figured out random spawning yet
like TRUE random spawning?
wanted to spawn the player naked in the middle of nowhere butttttt for a trait
couldnt exactly get that far with the spawning part yet lol
i looked on the workshop for mods that do it but they seem to all record all the cells in the game, which isnt ideal as it wouldnt work wiht modded maps
and i wanted to entertain the idea of just mimicing eating telecorn before spawn on the player, but i still dont even know if telecorn is acutlly real lmao
It has passed into the anuls of legend. But all legends have their KERNEL of truth
bows
I think it only exists in a mod, now
idk i saw albion made a mod for telecorn spawn rates
also - separate note...
never name your variables like this, no matter how redundant proper naming seems to be:
public void doUtilityVehicle(IsoMetaGrid.Zone var1, IsoChunk var2, String var3, String var4, String var5, Integer var6, String var7, ArrayList<String> var8, int var9, boolean var10) {
which could have been a joke
lol
im pretty sure thats a like side effect of the decompilation of the code
i dont think they know the variable names
so it just
does that
I've never seen that in decompiled java, but my experience is limited... and I see it all over inside functions, not just in the declarations
yea its very very like
grosssssss
and hard to read
i would be heavily concerned if that is how the real source code is
took me 25min to figure out that this function doesn't use the scriptName at all, but only picks from zones
each type of randomizedVehicleStory seems to have it's own structure entirely. My head cannon is that they had an internal competition to push the best way to write them, but it's clear to me which ones were written by the same person and which ones not
that
is pretty funny
that or they just didnt realize someone already did the work
not to bash on anyone: software development can be a nightmare even for the experienced
i know what you mean totally 100% right now
im digging through the source scrouunggginggggg to find where the heck the dang view radius variable is
yknow for like eagle eyed and junk
i need to see where they set it and its just a nightmare
Howdy, I want to make a mod for zomboid that just involved me changing the jpeg of a single item for me and my friends
How do I do this?
Hey! Try this tutorial if it's for an object. If it's for a tile, you can check out this tutorial series.
1:11 Step 1 - Know your file locations
4:06 Step 2 - Storyboard your ideas out
9:03 Step 3 - Get your files from the game or other mods
11:47 Step 4 - Build your mod files
1:01:54 Step 5 - Create the textures (mislabeled in the video, oops)
1:19:45 Step 6 - Put your mod files in the right structure
1:30:37 Step 7 - Test your mod (please back up ...
Quick guide on how to make a mod with custom tiles so that your own custom tiles show up in-game.
If you like what im doing please consider donating to my Patreon.
https://www.patreon.com/DaddyDirkieDirk
Ahh, its just the way an item looks in an inventory.
Try the first one, then. You'll get to the relevant part pretty early on in the video.
Nice, thanks
Np!
this is because of decompilation, the variable names are lost in compilation because they don't have any runtime significance
if you use beautiful java it'll rename variables based on their type float1, float2, zombie1 etc which is a lot easier to read
hey lucky guess
I guess if they're not passed or used outside that class, it's more likely to happen
and you can see the actual names of method parameters on the reference site
so long as it is public
I did eventually end up going there. I've just never seen it out of java before. But most java I've dealt with before was tomcat and jboss stuff
would be nice to get beautiful java using those names, no idea if they take contributions but i know jab scraped them for umbrella so it can't be too hard
but I think we've also ssen some code that DOES name their variables that way. I worked with a guy who that's how he wrote bash scripts. He never admitted it, but I think it was for added job security

declare -x global_ary_one
i've seen a few people in here who like their local x =
declare -x globale_ary_two
ewaguh
i already cant understand why people shorthand their varaible names so dang hard
only time I abbreviate a variable is when it's an iterator, index, or key=val (or similar instances)
they don't use an IDE?
and then I have nested loops and key=val is meaningless
Oh good lord that's the decompiler and not how the variables are actually named in the code.
Not this silliness all over again.
Nobody is doing anything deranged like using var1, var2, var3 as variable names but sure seems like people love jumping to that conclusion when they decompile. ๐
I thought it might have been at first, but I'm familiar with this kinda thing from javascript minimizers and C decompilers. I just hadn't seen so much of it from Java.
Now, that said, I have seen it A LOT in some of the mod lua code, so I think a warning is still warranted.
I guess its highly likely if the variable is strictly local or lacks any kind of formal declaration.
When mortals tred where gods play....
Mod lua code? Like other people's mods?
Yes. Workshop items.
Well, there is nothing keeping a toddler or an escaped insane dog from uploading workshop items to steam either.
Anyways, some people get mad about the variable names that RJ and I use in the code that you don't have to decompile, so yay.
meh, when they get mad just ask them to show you how they named variables in their game they released on steam...
Well, also a lot of mods are made by a twelve year old who was just learning for the first time as they went along, and some of them end up with more subs and on more servers than a mod made by a professional computer rocket scientologist coder person, so I just feel you have to have realistic expectations re the coding standards in mod.
if the code is beautiful only coders are gonna appreciate it, most people only care on what the mod does lol
Never seen a mod use var1, var2, var3, but hey, with the way people keep believing that that's the way TIS does it I guess someone must have tried it in a mod ๐
Likewise, worst case I've seen is stuff like local a = or worse yet making single letter globals
i cant remember where but 1 letter varialbes are
something ive seen
even if its local i just
I've used them in some cases
yea for loops its aight
or like something like x, y, z, i
theres nothing wrong with writing your variables whatever you want
only thing computer cares a bout is
"does code work?" "Yes?"
Most mods are not the issue when people "use over 200 mods"
It's configuring mods wrong, or using directly stated 'use only one' options, or using mods written several builds ago
If you run into issues it's almost always one or two mods
oh yea
thats the issues
its 1 out of like
200
that i gotta find
and man you cant control yourself
you get one
well why not get that one?
well if i have this then i need that?
and then your thousandddssss deep
most pz mods tho seem to be pretty well written that they dont conflict with each other unless, expressly doing the same thing
or similar
Pretty much
I've seen way too many posts of "what mod does this thing?"
Or comments like 'I spent hours trying to find what was causing this' left on my workshop lol
Not bugs either, to be clear, like actual mechanics.
The most common "mod is broken" advice I give is "you have 4 that do the same thing - pick one"
i canโt find westpoint expanded? was it remove or smth
Nope. I have it running on my server. Dunno the workshop id but the mod is WPE
okay now this is just ridiculous. how does this even work???
shaders are a different breed or something
if (alwaysfalse == true)
{
code runs???
}
Its a switch. This codepart will be ignored. The dev might kept it for testing purposes
no no, i made this
And it is working? I mean 0 == 1?
yes lmao
oO
im gonna say you have a mistake somewhere
this code
is entirely copied from the games source
except this one section
i added
and when i delete this section shown
it renders just fine
i have no idea
no matter what i do that line existing at all it runs no matter what, im assuming this is shader junk or gpu something that i just cant comprehend
I would wager that is the problem. If you have something which you presume is false, and == true code block runs, then that variable is not false
as far as im aware
0 is not 1
i know what you mean tho
i tried it with normal variables
yeh exactly, so somewhere you are failing to understand what the value of alwaysFalse is
i went to this as like a last resort like
"surely not"
no alwaysfalse was an example
this is genuinely how it is
#version 110
varying vec3 vertColour;
varying vec3 vertNormal;
varying vec2 texCoords;
uniform sampler2D Texture;
uniform float Alpha;
uniform float LightingAmount;
uniform vec3 TintColour;
uniform vec3 AmbientColour;
uniform vec3 Light0Direction;
uniform vec3 Light0Colour;
uniform vec3 Light1Direction;
uniform vec3 Light1Colour;
uniform vec3 Light2Direction;
uniform vec3 Light2Colour;
uniform vec3 Light3Direction;
uniform vec3 Light3Colour;
uniform vec3 Light4Direction;
uniform vec3 Light4Colour;
uniform float HueChange;
#include "util/math"
#include "util/hueShift"
void main()
{
vec3 normal = normalize(vertNormal);
vec4 texSample = texture2D(Texture, texCoords);
if(texSample.w < 0.01)
{
discard;
}
vec3 col = texSample.xyz;
float dotprod;
if(HueChange != 0.0)
{
col = hueShift(col, HueChange);
}
const float QuantiseLevels = 8.0;
vec3 lighting = vec3(0.0);
dotprod = max(dot(normal, normalize(Light0Direction)), 0.0);
lighting += Light0Colour * dotprod;
dotprod = max(dot(normal, normalize(Light1Direction)), 0.0);
lighting += Light1Colour * dotprod;
dotprod = max(dot(normal, normalize(Light2Direction)), 0.0);
lighting += Light2Colour * dotprod;
dotprod = max(dot(normal, normalize(Light3Direction)), 0.0);
lighting += Light3Colour * dotprod;
dotprod = max(dot(normal, normalize(Light4Direction)), 0.0);
lighting += Light4Colour * dotprod;
vec3 gray = vec3(dot(vec3(0.2126,0.7152,0.0722), col));
vec3 tintColour = TintColour;
if (0 == 1)
{
tintColour = vec3(mix(TintColour, gray, .99));
}
lighting.x = min(0.0, 1.0);
lighting.y = min(0.0, 1.0);
lighting.z = min(0.0, 1.0);
col = vec3(col.x * tintColour.x * lighting.x, col.y * tintColour.y * lighting.y, col.z * tintColour.z * lighting.z);
vec4 fragCol = vec4(col * vertColour, Alpha * texSample.w);
gl_FragColor = fragCol;
}
well that worked as planned
yea but that is literally everything
That's a debug pattern.
mm
There a missing semicolon or bracket that it's closing or something?
pshhh (like pssh of thinking)
i didnt see any and it seems to work just fine
and the fact that the code goes allll the way through
the character is only supposed to look black when 0 = 1
yet always looks black
and obviously 0 never = 1
And you've tried it without that conditional?
yes
when i remove the code that makes the character black
the character is not black
that single line
any ideas i had of fixing this have been fubar
its just entered into the realm of nonsensical
That's why I'm wondering if the conditional is buggy.
um, well in TintColour is black, it will always be black
Well, actually, if it's working how you say, we know it is.
The why... That's just odd
if you look, gray is the dot product between a fixed color (some grey i presume), and a hueshift from the texture
im aware of that
ok, so what is the value of TintColour as passed into the shader?
well without mixing it with the gray its just what makes it come out normal
i want it to be black, but i only want it to be black with conditions
the problem is that no matter what that condition is the code just always seems to run
what is the source image?
like, paste it in here
cause I'm like 99% positive what you think is happening, isnt what is happening. Not saying your not seeing the results you see, but Im not sure the code is doing what you think its doing when you think its doing it
left is with the line of code there, no matter where its placed
right is with the line of code removed
In order to check this, need the actual source image, and to know the actual value of TintColour as passed to the shader
i dont think i can give you the value of tintcolour
sure you can, make it the the output color real quick
like actually i cannot print it, nor can i directly communicate with the shader
screen grab, and check the color
ohhhhh
its not really the color thats the matter its the condition
im able to change the tintcolour just fine
no, but the color matters in the calculation of what you are seeing
the only thing I can think could be happening is because you have a bad conditional, the shader compiler is optimizing it out... but i have NEVER seen that happen like this
yea i just want to be able to tell the code to do different things, based off different conditions. and i cant get it to do that
um
is it possible that your condition is causing the compiler to throw an error, and the code is catching it, and loading the default shader?
which is why when you remove the "bad condition" it works... because its no longer reverting to a default shader of some sort...
the default shader is the right one
that seems more likely than if (0 == 1) always evaluating to true
as in right picture
that is possibleeee
but i dont know why it would automatic to running the condition?
if it couldnt find that out
it started out with me trying to make it actually care about what the condition was
but then i realized that it just didnt seem to even care
I can't code for shit but I just threw the idea out for someone else to make if they had the time or interest for it
Actually, doesn't seem prohibitively difficult. And it seems that's how guns should work while the weapon condition indicator for melee weapons should be default (for realism of sorts)
anybody have an example of how to make a quit to desktop error message?
Gonna have to elaborate on what you mean
That I know, those kinds of errors only pop up when an integrity check fails at the start of a server connection
As for the quit to desktop option, I also see those when someone is auto-kicked for various anticheat reasons
I think it may determine to give the quit to desktop option when the failure could be caused by steam or steam-related things
these seem relevant
function ISGameLoadingUI_OnGameLoadingUI(status)
function ISServerDisconnectUI_OnServerDisconnectUI(reason)
All speculation in the moment, as I don't know for sure
Definitley could be. Can't say from just the prototype.
/
You only can't do it because you don't know how to.
There are plenty of guides and videos on how to code for Project Zomboid, and a whole wiki page that shows the codes for each item.
All you need is patience and a willingness to learn.
You'll be fine, you can do it โบ๏ธ
Everybody who knows how to do something started off not knowing.
Its mostly just word of mouth tho, at least for me 
so look, I've literally never made a mod in my life, but I was wondering if there was a guide somewhere that helped with a simple audio replacement mod
Hello everyone (again). Is there a file that defines wall health somewhere? I'm looking to see if I can lift it and utilize it for some custom tiles that we have so they're much harder to break.
[Phobia remove cockroaches]
Hi people. My wife and I love playing, buy she has a serious phobia of the cockroaches.
Is there any mod where I can remove or replace this item?
I have a little knowledge on coding so if I had do addapt something that could work. If anyone could help that would mean a Lot. Thanks
I believe there is an option in the multipler settings for removing items from the pool
Great to know! Will take a look on that. Thanks!
If I get Lost I'll ask you to dumb down your answer by 15%. Lol
Hello, I'm trying to change values of an XP multiplier mod, but it does not seem to work. I found this file, and changed some stuff, but still dont work, HELP?!?
Guys, let me ask a question, do you know is it possible to gather player mod data from an admin instance? i tried to use remoteIsoPlayer:getModData() but no luck it returns with an empty table... or is it possible only if I send a command to the client through the server and sending back the data?
for such transfer we usually send a clientcommand to the server. the server updates the global mod data. clients that subscribed to that part of global mod data get the update.
Yup that would be my alternate approach but it seems like a bit overkill for getting some small user data.
Thanks for the answer btw!
where does dedicated server logs store the print results? from lua mod server part
im trying to print inside the server scope, and is not showing anywhere
like
if isClient() then
--do something
else
print("server log")
end
Could also see it as <installation_root>/Zomboid/Logs
Oh, it has its own log handler that I haven't dug into yet.
my server is dedicated server
Mine too.
With force_install_dir /opt/zomboid my logs are at /opt/zomboid/Zomboid/Logs
Iโm curious if anyone is working on a Union City map mod
On the other hand, is there a mod that adds favorite foods? Like you assign a certain food that in turn gives your character increased happiness and stress relieving stuff upon eating it?
Is there a way to reduce weapon spawns from a mod if there are no sandbox settings for it? Like what specifc numbers do i have to mess with in what file to reduce them
I felt this would be the best place to ask for it
Hey guys, trying to initialize a table that's updated by the server by initializing server side and the client requesting it when they join.
I tried sending the command from client from the OnGameStart event but it didn't seem to come through on the server side, is it possible that during this stage of loading the client does not have access to communicating with the server in this way, just about to try onConnected but any insight from someone with more experience would be greatly appreciated ๐
Ongamestart triggers before onload say what, by now I thought I'd know the answer to this question but.. is there any event that happens JUST before or immediately as the player clicks "click to start"?
Commands can't be sent right away to clients when connecting. However, if all you want is a data table that's held by the server which players can update check out my zonesAPI. It has an example, which I may expand upon as a server-side globalModdata API.
APIs for my APIs
I don't know if this is exactly what you want but it uses a system to update connecting clients with serverside data upon connection (and updates in realtime).
Linked the wrong mod, my bad
I'll definitely check this out, atm I've just resorted to this.. which isn't the best way of going about it I'm sure but it works 
function InitialLoadedArtifactLocations(player)
if not HasInitialArtifactLocations then
HasInitialArtifactLocations = true
local args = {}
sendClientCommand("Anomaly", "RequestArtifactLocations", args)
print("Client Requesting Artifact Locations")
end
end
Events.OnPlayerMove.Add(InitialLoadedArtifactLocations)
I've done something similar before, you're ok with using onPlayerUpdate and removing the function
oo I can stop this check from happening by removing the event can't I... hahahahaha
Bro's just gained 10 fps from 2 other mods I'm doing this with 
Events.OnPlayerMove.Remove(self) (I think should work, although I never tried self)
Thank you ๐
How are you storing the table?
Saving, rather
GlobalModdata on the serverside? Or a read text file?
local artifactLocations = {}
ServerShouldInitAL = true
local function InitArtifactLocations()
if isServer() and ServerShouldInitAL then
ServerShouldInitAL = false
for i = 1, #GlobalAnomalyZones do
artifactLocations[i] = { found = false }
print("Init Artifact location.." .. i)
end
end
end
Events.OnServerStarted.Add(InitArtifactLocations)
And then I'm just updating it through client command bounces
Whenever people find artifacts
How is it being saved?
It's not persistant across restarts if that's what you mean.. it's just stored in the table on the server side and sent to clients when they join now
Ah
Anytime that table changes on any client, it updates the server, the server then sends the updated table back to clients
Emissions also reset the table
I do pingpong updates too, but if you want it to be persistent check out the zones api
I've never heard of pingpong updates, how does that work?
Also if you're ping-ponging commands it won't work in SP
What you described, client > server > clients
Ahh well yeah that's essentially what I'm doing
Yeah but in SP it can't properly use server to clients cause nothing is connected
Aye that makes sense
So the workaround is to have it call a function first that checks for isServer send command otherwise do the contents of the command.
It's another thing to have to write around ๐
Haha yeah I'm still getting to grips with the server client communication stuff, got all 5 brain cells working overtime
Appreciate the help from the all mighty chuck ๐
No worries, it takes me like 2-3 days to setup network interactions cause I forget/don't make a general API for it.
And decide to change up how it works everytime.
function zoneEditorServer.pushUpdate(zoneType, zones, disableRefresh)
if isServer() then
sendServerCommand("zoneEditor", "loadZone", {zoneType=zoneType, zones=zones, disableRefresh=disableRefresh})
else
zoneEditorServer.loadedZones[zoneType] = zones
zoneEditor.loadedZones[zoneType] = zones
if (not disableRefresh) and zoneEditor.instance then zoneEditor.instance.refresh = 1 end
end
end
The worst part is needing to borrow some poor soul to make sure I've done it right lmao
This also needs refactoring cause I think I can get around using a separate variable for clients by just referring to the same variable - which clients have access to in server
The "server" code is still executed on "players".
For both SP and MP
Trying to keep things clear in setting up zones API I used one list for players and one for host. But I think it can consolidate it by just referring to the same variable for both.
hi there, could anyone tell me which event it's triggered when a player spawn? there are a few, but quite don't understand the difference between survivor, character, etc..
At least for SP
i.e OnCreateLivingCharacter OnCreatePlayer OnCreateSurvivor
OnCreatePlayer is the one you'd want, but related to the above topic, those events may not fire at all while connecting.
Or fire before connection is complete.
I'll definitely check this out soon, I was confused when you said zonesAPI, it's quite funny I actually have a mod called ZonesAPI but it's simply for triggering functions onupdate and just once when a player enters a zone, nothing fancy
Oh?
But I did manage to butcher together a custom spawning system used for my mutants instead of just adding them directly to zed distribution using at as a base
also radiation
thanks, i'll add my function there and see how it goes ^__^ @sour island
I thought the name was not used prior - and this mod lets admins edit zones in the server in real time. At which point you can do other things on your own.
And a teleport fade to black dealio
Bro nobody has seen or heard of my mods other than the guy in my project discord ๐ likely my mods won't see the light of day until I actually pack them up ready for our stalker collection
Also didn't realize vanilla zones were kind of a thing already lol
I've seen how other mods handle zones and it appears to just be copy pasting the vanilla methods. I want to see if I can incorporate vanilla zones into my UI.
It's just checking X, y, z's on update but to avoid ridiculous itterations on a fat table it checks every 2 ig hours for "zones" within 300 tiles and itterates on that table instead
It's still costly but allows me to have one table with 1000 zones with no lag
Knowing you, you could slap it together in an hour way better than I have ๐
I'd probably look into making it a matrix
I'd be interested to send you the code and see what you think optimisation wise? I'm still learning and really appreciate any tips I can get from experienced creators