#mod_development

1 messages Β· Page 551 of 1

prisma wren
#

and im not sure if i should rename the 'firearmbooks' part to my mod name

drifting ore
#

Just use chrome 4head

cosmic condor
small topaz
#

Have a strange issue when trying to add a mod to a running multiplayer game: When I have the mod in my Zomboid/Workshop folder, adding it to a running mp game works fine. However, when I delete it from there and subscribe to it via the steam workshop, adding it to a running game does not work anymore. Ever heard about such an issue?

#

Is it possible that in this specific situation, the game handles stuff about overwriting vanilla function and load order of lua code differently? (Not necessarily related but could be an explanation in my case...)

cosmic condor
#

but you should not do that ever lol

small topaz
#

but this has still the effect that the game should execute vanillaFunction() from the modded code.

cosmic condor
small topaz
#

hmm???

#

i think this is the chat for modders asking questions about mod construction?

cosmic condor
#

yes it is, but in case those who encounter this issue can help

small topaz
#

maybe a misnderstanding...? it is one of my mods (already published in steam) which cannot be added to a running mp game. now I want to fix the mod so that it has this feature and therefore asking here in the technical/coder channel.

#

i always thought the mod_support is for people who have questions about using content from other modders...?

cosmic condor
#

oh, it's my fault then

thin zephyr
#

Hi, I'm Spanish. I have a problem, which is that the game is working fine, but when I go to create, after the character attributes, the game closes.

small topaz
cosmic condor
#

wait what is "running" mean?

#

I may misunderstood the things you are trying to imply

small topaz
#

thanks! but that's not my question. i know how a mod can be added. problem is that a specific mod of mine doesn't work when (correctly) added to a running mp game. does not produce erros but simply has no effect. i am quite sure that this is a technical problem related to my mod (or to the vanilla game itself).

small topaz
# cosmic condor wait what is "running" mean?

with running I mean that you add it to an already existing world where player run around and so on. so, the world has been created without the mod and then later, the mod is added without restarting the world or so.

cosmic condor
#

what is the function of your mod?

small topaz
#

aka occupations

cosmic condor
#

okay, that's maybe enough information

#

@small topaz Are you sure that you added your mods in both Workshop ID and Mod ID?

shadow geyser
cosmic condor
#

I assume that you said it work earlier. I thought you may have missed this part.

small topaz
cosmic condor
#

Steam workshop id is important, we just discuss this issue earlier today

shadow geyser
#

workshop id tells the dedicated server to download it for its files, to be used for the serverside.

small topaz
shadow geyser
#

atleast that is my understanding.

cosmic condor
shadow geyser
#

Im not saying that is 100% the solution, im just saying that is something you can try

small topaz
#

maybe i repeat my problem: for that specific mod, it works fine to add it to an existing mp game when i manually install the mod by putting it to the Zomboid/workshop folder. but it does not work when I subscribe to the mod in the steam workshop and then try to add it to an existing mp game. and that is quite strange imo...

cosmic condor
#

try edit the workshop list again, it should work

#

At first, I thought you meant a running game server where players are still playing in the game. lol

#

I was like... tf how can you do that?

small topaz
shadow geyser
#

yeah I read what you said, and understood the question. What Im saying is to check, did you also add the workshop number into the server ini, and not just the mod id. if you have, please say that, rather than just assuming others are misunderstanding you.

small topaz
cosmic condor
#

You should use the word "existing world" instead. lol

shadow geyser
small topaz
prisma wren
#

how can i test if a item spawns

cosmic condor
#

then test it

#

and if it works, lower its number as you want

static oyster
#

is there any lua command to check if the player is interacting with the world? like interacting with doors and windows etc

small topaz
static oyster
#

if theres something that checks like

#

"player interacted with this object"

#

or

#

player has opened a door

#

more like on the interacting side... let me see if I can find a better example... you know when doors makes sounds when the player interacts with it? or when the player opens a window and it makes the window opening/locked sound? There must be a check for it right? a boolean or something that detects that the player is indeed interacting with x objects

#

hm, I found getInteract

#

I wonder if thats it

small topaz
# static oyster hm, I found getInteract

not sure about that but maybe although I neither find it in the zomboid lua code, nor in the java doc. still possible that this is a function which can be used

#

alternative: the pz folder projectzomboid/media/lua/client/TimedActions contains a file ISOpenCloseDoor.lua and a similar one for windows. you could also try to use them

#

those luas usually contain functions which are used when the player is doing something (in this case probably open and close doors and windows)

steel locust
#

Hi, so I want to remove the recipes from vanilla for reclaiming weapons from spears. However, when I tried creating a recipe of the same name with "NeedToBeLearn" set to true, all it did was create a duplicate recipe, when I really wanted to overwrite the vanilla one.

Is there a way to overwrite recipes without overwriting a whole file it's contained in? Or would I have to create a copy of the vanilla recipe file and put back EVERYTHING other than the reclaim recipes, and overwrite it all?

static oyster
# small topaz those luas usually contain functions which are used when the player is doing som...

hmm indeed seems like that could be it tbh.. I'm trying to make blind zombies.. but after so much messing around seems like no one can help with that, and after looking on camouflage mods and what not, seems like the only way is either ghosting the player or setting the zombies useless.. both has their own issue.. with I think with some messing around with the zombie useless I can get something nice going on.. the problem is that I now have to probably do a check for a lot of things in the game like.. opening doors, sneaking, running, walking, attacking while sneaking

#

because setting them useless also just well.. disable their AI.. so I need to constantly enable their AI for everything that could potentially make a sound

drifting stump
#

use lua for that

static oyster
#

I have no library, I'm literally coding with notepad++ and guessing atm lol

small topaz
steel locust
drifting stump
#
getScriptManager():getRecipe("RecipeName"):setNeedToBeLearn(true)
steel locust
#

Ohhhh

static oyster
steel locust
#

You're wonderful, thank you!

small topaz
static oyster
atomic kiln
#

Is electricity handled over lua or java?

static oyster
#

setting to 0 makes no difference throws error I think even

small topaz
tacit briar
#

it’s by Konijima that’s here and goes in detail about getting it set up

#

very useful

static oyster
#

will look into it later then

static oyster
#

or making it nil

#

doesnt work

#

zombie target*

#

spotted, target, whatever else doesn't work which makes it not an option either

small topaz
#

the TimedAction folder does indeed contain some functions which are used when the player makes an action which makes sound (like door opening and stuff). if you don't find a better solution, you might have a look there. but not sure if everything which makes sound and should attract zombies can be found in TimedActions.

#

guess it could be quite some work

static oyster
#

indeed

shadow geyser
fiery pecan
#

odd question, but say I take the vanilla cop car, and make 2 new skins for it. One with an all-blue lightbar, and another with an all-red. Say I want to keep them in the same script file. As in, as the same vehicle, different skin index. How would I do the "Lightbar" category in the script?

small topaz
# static oyster hmm indeed seems like that could be it tbh.. I'm trying to make blind zombies.. ...

just in case you are interested (and not already know): whether the player is running or sneaking can probably be found out by java methods player:isRunning() and player:isSneaking(). (for running, see here for example: https://zomboid-javadoc.com/41.65/zombie/characters/IsoGameCharacter.html#isRunning() ) don't think that those things are also controlled via timed actions. but not sure..

fiery pecan
#

Sorry for interupting

shadow geyser
fiery pecan
#

alright

open ravine
#

Wish it was possible to reinforce player made metal/wood fencing or walls to make them far stronger or even unbreakable by zeds (at a cost fitting to the strategic gain)

I know there is one mod that allows this with metal walls but it doesn't appear to work. I reinforced it with the plates but zombies still break them down.

Anyone know a good mod that might help. Just want to put up chain link fence/gates to fill holes that act like the ones in the world. Like how do the Zeds know the difference from my single segment of chain link from the rest that are apart of the map. I have lvl 10 metal working. If anything my fence should be indistinguishable from the maps fencing next to it ..

burnt escarp
#

Having an issue with the Elbow Pads from Shark's Law Enforcement Overhaul.
The model "spikes" out from the player when you aim with a weapon or gun.

Anyone have this issue at all or even better, found a fix?

rare berry
#

whats the mod that makes it so the longer you're exposed to zombies, the less you get panicked?

static oyster
#

makes sense if the target system is tied to their sight

#

since they will always see you and target you back if you set to nil

static oyster
latent orchid
#

Is the sendClientCommand necessary when taking liquids between item and IsoObject on servers? (for example gas pumps, water cooler)

I noticed that taking water calls the command (sendClientCommand(playerObj, 'object', 'takeWater', args)), but taking fuel from a pump does not.

Ask as I am worried that there might be issues in MP if this command is not performed

jagged ingot
#

@thin hornet I'm still interested in doing an allnighter for a script editing software.

thin hornet
#

hehe

jagged ingot
#

Others I spoke with said this would be a very desirable thing to make.

thin hornet
#

yeah thats for sure

jagged ingot
#

Also, I was thinking about an idea to make more examples for TypeScript modding with PZ.

thin hornet
#

More tools is never a bad thing

jagged ingot
#

It would be cool to template this as a wizard plugin for a IDE.

#

I might get caught up in writing my own SASS

#

Always happens when I do any web app.

#

@thin hornet Can you provide me with the scripts you'd be interested in me working with?

#

A wiki or some list?

#

I can do insight research on them using Java decompiles I have. Just want to make sure I'm looking at the right ones to start.

thin hornet
jagged ingot
#

I'll take a look in a bit. Thanks.

thin hornet
#

Some sort of base mod that can be used to create mod and abstract some stuff that usually needs to be done.

thin hornet
#

i have to check these global object system

jagged ingot
thin hornet
#

to learn how to use it

jagged ingot
#

Oh.

#

What do you want to do?

#

Calling a global table is also callable as ```lua
local globalVarReference = _G.MyGlobalObject
-- OR
local globalVarReference = _G['MyGlobalObject']

#

Global is its own table basically.

#

Usually people require and then call it without the _G.

thin hornet
#

nah im talking about something else

#

brb

jagged ingot
#

Am curious.

#

Ok.

thin hornet
#

CGlobalObjectSystem & SGlobalObjectSystem & JSGlobalObjectSystem?

#

I have yet to discover those two pieces

#

seem to be used with farming and campfire

jagged ingot
#

Oh something entirely unrelated to Lua global

#

Finally got my grunt watcher / sass compiler working.

#

@thin hornet Ever used SASS?

thin hornet
#

yea but mostly scss

jagged ingot
thin hornet
#

i prefer scss coz of the syntax

jagged ingot
#

Nesting is just the best.

thin hornet
#

but yeah thats much cleaner than writing your css yourself

jagged ingot
#

Yeah that's the best thing about SCSS.

#

I mean you are writing your CSS just as a transpilation of it.

thin hornet
#

mixin and variables πŸ˜„

jagged ingot
#

Huh.. items have hundreds of settings.

#

Didn't think it was that much.

thin hornet
#

xD

#

told you

#

the "edit items" part will be the most complex part of it

jagged ingot
#

I'll need to figure out which settings are used for what category.

sour island
#

Anyone know if Cosmic Cat or M13 frequent here?

jagged ingot
sour island
#

They're both breaking ISReadABook... hopefully they check out their comments before I bypass their mods in favor of mine.

jagged ingot
#

@thin hornet Here's my first work so far.

#

I'll dig to see what settings are applied to what item types.

sour island
#

Can you use require with a modID? πŸ€”

jagged ingot
sour island
#

was afraid of that

jagged ingot
#

All files are loaded in a scope that's inside of client, server, and shared.

#

so if you have a mod with client/myfile.lua, use require 'myfile.

thin hornet
sour island
#

yeah, I just finished closing their mods

#

now I have to open them all back up

thin hornet
#

That is why i suggest using subdirectory with mod id

#

hehe

#

would make thing clear

jagged ingot
#

I'd be making loading & saving item scripts ignore unrelated settings.

sour island
#

well I'll be damned

#

this guy named his files the exact same thing in two different mods

#

does that break anything?

jagged ingot
#

Overrides.

sour island
#

yeesh

#

I'll let him know in the comments

jagged ingot
#

=))

#

Found what I needed

#

@thin hornet zombie.scripting.objects.Item#InstanceItem(..)

#

Shows what settings matter for which type.

thin hornet
#

oh yeah

#

zombie.scripting will be your friend

jagged ingot
#

Already knew that. I was looking in InventoryItem because I had a hunch that the init code for instancing would be there.

#

I'm right, but it refers to Item's static methods for instantiation.

#

Now I can toss in the ts fields I manually typed into separate containers.

sour island
#
local crossRefMods = {
    ["CatsWalkWhileReadMod"]="ReadFasterWhenSitting",
    ["CatsReadMod"]="ReadFasterWhenSitting",
    ["CatsReadMod(slower)"]="ReadFasterWhenSitting",
    ["M13ReadingTweaks"]="M13Reading",
}
local activeModIDs = getActivatedMods()
for i=1, activeModIDs:size() do
    local modID = activeModIDs:get(i-1)
    if crossRefMods[modID] then require (crossRefMods[modID]) end
end
#

This should work in order to force load their mods first so I can overwrite them right?

thin hornet
#

ya

#

if the path are correct then it would work

#

do something like

#
local crossRefMods = {
    ["CatsWalkWhileReadMod"]="ReadFasterWhenSitting",
    ["CatsReadMod"]="ReadFasterWhenSitting",
    ["CatsReadMod(slower)"]="ReadFasterWhenSitting",
    ["M13ReadingTweaks"]="M13Reading",
}
local loadedModIDs = {};
local activeModIDs = getActivatedMods()
for i=1, activeModIDs:size() do
    local modID = activeModIDs:get(i-1)
    if crossRefMods[modID] then
      require (crossRefMods[modID])
      loadedModIDs[modID] = true; -- keep track of which was loaded
    end
end```
alpine scroll
#

Is there somewhere in the saves files where I can check what is in which container?

thin hornet
#

so that you dont have to loop all over again later

sour island
#

ah

alpine scroll
#

Btw, hello everyone

#

Also, other then checking the containers, is there any file on /media/ folder that has the vanilla loot tables?

alpine scroll
jagged ingot
#

Felt like showing progress and what design choices I'm making for the data.

#

I'll be importing the script format to Json and then writing Json to the script format.

#

I'll complicate it to have module instances and then maybe template or super item definition attributes as I go forward. Small steps.

#

It would be cool to have an item extend another and when changing a value that isn't set for the sub item the sub item receives the change.

sour island
#

The rightside is a mod I spent like 3 days on to get right, the one on the left is something I wrote in like 15 minutes.

#

as is life

#

alternative moral: always put vin diesel on your mod posters

jagged ingot
#

That's my entire career.

#

lol

thin hornet
#

loool

jagged ingot
#

It's midnight. Making coffee.

thin hornet
#

haha same

jagged ingot
#

BTW I already have a module class setup.

thin hornet
#

to process the script files?

#

into blocks?

jagged ingot
#

I can push it if you want to see it.

#

I have the IO code for project file data.

#

Having a project to store data that will be compiled in any way that losses data needs a project format.

#

So I know that item extensions isn't supported with script.txt format, but I plan to have extension inheritence support.

#

So if I want to have two weapons, say baseball_bat and spiked_baseball_bat, I could have the spiked one import values from the basic one and override certain ones.

#

If I change a value in my editor for the basic baseball bat, then the spiked one also changes for settings it inherits.

#

Make sense, @thin hornet ?

#

If I only load and save from the script.txt format, I wouldn't know the next time whether or not the spiked one extends the basic one.

#

Hence project files. πŸ™‚

thin hornet
#

make sens yeah

jagged ingot
#

Would be better to modify a base item once than cloned copies x amount of times.

shadow geyser
shadow geyser
# sour island was afraid of that

you could make your code "load last" by putting it all into a function which you add into a event. Thats how I made a change to make sure one of my plant compatability codes loads after any and all mods that add crops. it puts a function that is meant to fix all the missing variables into the OnGameStart function. that makes sure that the code runs last. you can probably have a function that redeclares the function you want to override.

#

its not the best kind of solution, forcing it to load that much later, as maybe in the future, someone else will need to overwrite your stuff, but for now it could work. and its alot easier than writing 100 require statements to make sure that code runs after another mod

drifting ore
#

im trying to set up base in a modded military outpost but i cant place stuff inside am i not allowed to build in it on purpose or is there a fix pls help

jagged ingot
#

@thin hornet Ok I've made good progress on detailing the codebase for Screwdriver.

#

Project -> Modules -> Items & Recipes -> Properties that are inheritable or set.

#

Items & Recipes now have parents and getters for properties checks the set value of the property and then based on that grabs either the parent's value or the set value.

thin hornet
#

Neat cant wait to try πŸ˜›

cosmic condor
#

Screwdriverℒ️

#

You'll never know what it can do until you take 3 minutes to read the descriptions.

thin hornet
#

i hate that the clock only show time minute by ten

#

00, 10, 20, 30, 40, 50

#

if a server uses a very slow time speed its not cool to lose precision

jagged ingot
#

Starting to feel tired.

cosmic condor
#

get some rest 😴

#

coding requires a significant amount of mental energy

jagged ingot
#

I definitely know that from experience.

jagged ingot
#

I'm now at the part of the project where I'm copying over all properties for base items and specific too.

thin hornet
#

Wheres the UI

#

πŸ˜›πŸ€£

jagged ingot
#

lol

thin hornet
#

Its due for next weekend or you are fired

#

Client is waiting

#

Almost finished my new mod

jagged ingot
#

Wrote base-level item properties.

toxic walrus
#

Hi all. Would anyone be able to explain to me the difference between adding something to Suburbs distribution and just adding it to procedural?

thin hornet
toxic walrus
#

OH. From what I understood from it was that Procedural feeds into the regular Distribution.lua

thin hornet
#

procedural are lists, and you feed the distribution with it

#
local distributionTable = {

    -- =====================
    --    Room List (A-Z)
    -- =====================

    aesthetic = {
        isShop = true,
        counter = {
            procedural = true,
            procList = {                    <<------------------------------
                {name="SalonCounter", min=0, max=99},
            }
        },
    },
toxic walrus
#

Ye I understand that part

thin hornet
#

So instead of cluttering the distribution with bunch of items you assign them procedural list

toxic walrus
#

But what does the actual SuburbsDistribution.lua do that the regular Distribution doesn't do for it?

#

Sometimes I see mods do like Table.insert to ProceduralDistribution.list or sometimes that do Table.instert to SuburbsDistribution

thin hornet
#

so when people add to the procedural, it mean everywhere that procedural is plugged in the suburb it will be there.

lets you create a new mechanic item and want to add it in every mechanic place

#

instead of adding it to the suburb of each location

#

you add it to the mechanic procedural

toxic walrus
#

OH OKAY

#

So Suburbs is like the call type or tile or zone

thin hornet
#

yeah mostly is a container, wether its a zombie or an object

toxic walrus
#

I seee

#

Because I seen a few mods do the same to Inventory lists, like adding to zombie inventory. They will sometimes do Procedural or do Suburbs

thin hornet
#

if you want it only on zombies specifically, then dont add it to the procedural cause that procedural might be plugged into other containers

#

or create your own procedural and plug it into the zombies

toxic walrus
#

Ahh I see

#

Makes sense

#

thank you

thin hornet
#

np πŸ˜„

toxic walrus
#

you're my hero

#

OH ANOTHER QUESTION SORRY

#

How does Zomboid handle loot rarity settings

#

Does it change the rolls or weight chances

thin hornet
#

its probably multiply it yeah

steel topaz
#

Hi guys, do you know about the water freezing in the winter season to be able to drive?

#

Or a mod to create a raft to transport a car to Kingsmouth Island

atomic kiln
#

Does anyone know how I should go about making my batteries fit in electronics? I can edit RWMPower:verifyItem to recognise them, the box lights green when dragging them in, but letting go of the drag doesn't add the modded battery to the item.

thin hornet
#

@atomic kiln you might have to verify the java source to see if anything is hardcoded to use the vanilla battery

atomic kiln
cosmic condor
#

daily mod

thin hornet
#

hehe

#

just happen that i needed that mod for a friend

frosty falcon
#

yea cheat menu got one too

#

that mod is way better tho, nice

cosmic condor
#

that or that that

#

πŸ˜‹

frosty falcon
#

I said though, so it wouldn't be the cheat mod I was talking about

static oyster
#

Ye i saw there's a OnGameStart function which is kind similar to the Awake function on unity i think (which happens before the game starts or a scene is loaded) but what would be the equivalent for the end on zomboid? OnGameEnd? As if now I'm just blindly coding with no library, had no time to set up the things from konijima

shadow geyser
#

I guess? im not so familiar with the Unity. Im not exactly sure exactly when OnGameStart happens. I haven't looked into it. If I had to guess, it probably happens after everything has loaded and you press any key to start the game. But anyways, it happens after all the lua files have been loaded and read, so it works to be able to "delay" the loading of the lua file by rather than actually executing any code on load, it just declares a function that does all that when the lua is loaded, and the function is only executed at OnGameStart

static oyster
#

I see, seems pretty similar to awake function.. "Awake is used to initialize any variables or game state before the game starts. Awake is called only once during the lifetime of the script instance."
I guess for the zombies since they seems to reassign the target every frame i need the to reassign the target on the end of every frame to overwrite it.. I'm gonna go look to see if I can find anything

#

It's also my first time coding lua too, getting used to the differences from c#, I'm not an experienced coder but I think this is not hard enough to make it work

thin hornet
#

you are out of luck

#

target is set after OnZombieUpdate

static oyster
#

Welp

#

I guess i could just use setGhostMode, my only problem are the goddamn sounds

#

Or just switching between zombie useless a lot enough to still make them move by themselves

thin hornet
static oyster
#

Would not there be a way to decompile and recompile the game codes with the new changes ?

thin hornet
#

Its possible but you cannot have java mods on the workshop

#

people would have to install the modified files manually and you would have to update the mod every update if anything changes

#

its not recommended the only java mods worth are for the server side since clients dont need them

static oyster
#

I see.. well sometimes there's a price to pay to achieve something good, but i guess i would not go that deep into modding as I don't have the time to learn every single possible bit.. nor enough knowledge on the matter. As of now I will keep trying with whatever was given to work with Lua, and it it works then it works

thin hornet
#

i think there is a mod that camouflages you from zombies when covering yourself in blood.

#

might be worth checking what technic been used there

cosmic condor
#

you may have to consider a lot of things; human blood, animal blood, zombie blood

#

Another idea that isn't lore-friendly, but would be cool to have is an invisible cloak from HP 😹

static oyster
#

Checked it yesterday

#

As well as one called stealth camouflage

#

That one uses ghost mode

cosmic condor
#

perhaps set an active and cooldown time to limit its power

static oyster
#

Something like the last of us

#

Setting them useless makes them inactive they can't hear or see, but with a bit of coding you can make a "fake hearing system"

#

Best option would be ghost mode

#

But it removes all the sounds from the player and doors and windows

alpine scroll
#

Is there a way to load different translation settings, based on client settings for the same translation files?

alpine scroll
#

I would like to make a client toggle that either shows in the start, or in the end

#

But I still haven't found an example where it does conditional translating for the same language

cosmic condor
#

The best way I can think of now is to create a mod that contains multiple mods. Each mod contains different translations. LetΒ them choose from there. Since the translation files load when you boot the game up and when you save the mod selection settings.

alpine scroll
#

But that doesnt work for MP, right?

#

This toggle would be more useful in a server, since different people have different ways to play

cosmic condor
#

I mean, if you want to change translation, you have to quit the session and reload the game

jaunty marten
alpine scroll
# jaunty marten check `Named VHS Tapes` in workshop

I thank you for your sugestion, but this is not exactly my problem. My problem is 2 different translations for the same language. Where you could choose between [Carpentry] VHS: Woodcraft E1 or VHS: Woodcraft E1 [Carpentry]

alpine scroll
#

My problem is not with single player. My problem is multiplayer

jaunty marten
#

but I could be wrong

alpine scroll
#

The problem is that translation files are a txt, and not a lua

jaunty marten
#

yea

cosmic condor
#

You can offer those who want the alternate translation to manually download the mod on their local side

thin hornet
#

Not sure if you are just doing translation or if you are doing the code too

thin hornet
#

But if so you might want to use
%1

#

getText("My_Text", variable)

#

but still

#

doesnt fix the problem

#

lol

#

sorry

alpine scroll
#

Ideas are welcome

#

I know that the vhs "problem" is not a problem per-se and doesnt add much to zomboid

cosmic condor
# jaunty marten ❓

I mean the server has to choose main translation and who prefer other than that, go download the mod to fix the translation

jaunty marten
#

@thin hornet :DoParam on DisplayName works in already running world?

alpine scroll
#

However, if there is a way to change the text of an item dinamically, you could alter things name when a player is drunk, for example

jaunty marten
#

won't work

thin hornet
#

i dont think DoParam on item name works

cosmic condor
#

Oh, I'm inexperienced with mp

thin hornet
#

last time i tried to simply rename the Money to Cash and it would work

jaunty marten
#

single way it's rename all items on change settings like
:DoParam(string.format("%s [%s]" or "[%s] %s", item.DisplayNameToFormat, item.VHSCategory))

#

rip

thin hornet
#

xD

#

right but i doubt it

jaunty marten
#

?

thin hornet
#

An other way would be to hook into the inventory pane to add some hackish code

jaunty marten
#

override defualt item tooltip? XD

thin hornet
#

most likely not worth it

jaunty marten
#

yea

alpine scroll
#

Why do I do this with me

#

I could just iron fist the thing because its for my own server

#

But nooooo, I have to think about the other users

thin hornet
#

You dont have to

#

but if you mean users in your server thats an other story

alpine scroll
#

Its for my own server

#

If it works I could release as a standalone

thin hornet
#

make a poll and the majorty of vote define if its left sided or right sided

#

lol

alpine scroll
#

But for now i have a workshop item that is an amalgamation of little things

jaunty marten
thin hornet
#

yeah pretty hard to guarantee compatibility

cosmic condor
#

It's funny how lots of players don't bother moving the 'V' button of the clothing UI mod and let it stick to the middle of their screen

jaunty marten
#

xp

thin hornet
#

lol

alpine scroll
#

Well, I'll leave the translation project for another time

#

Btw, anyone knows of any example on how to add a custom command that can be triggered with Rcon?

thin hornet
#

custom command and server chat commands would be dope

#

without needing to hack into the chat code

alpine scroll
#

I would like to make a createhorde3

#

Where instead of x,y,z it asks for a player name

thin hornet
#

D:

alpine scroll
#

It would be fun to spawn a horde of santa's on christmas, for example, via console

cosmic condor
static oyster
#

Konijima, could you by any means look into the ghost mode ? I want to know what it does to the sounds really, because I wonder if it just stops the sound engine or something and if could be forced back on

alpine scroll
#

I mean, I do have it

#

Not sure if a Mod added it, but I think not

static oyster
thin hornet
#

there is no way to bypass it

static oyster
#

I see, i was also curious about the documentation saying that setGhostMode has a boolean and a ghost mode mode or something

thin hornet
static oyster
#

setGhostMode (boolean, aGhostMode)

#

With the description

#

A ghost mode to be chosen or something like that, let me see it again

sour island
#

I feel like this should be pinned tbh. Would help avoid alot of early issues / let people get the ball rolling.

static oyster
thin hornet
#

haha

static oyster
thin hornet
#

Yeah there is limitations, but its improving with time

#

if you are stuck with an idea, try to find an other idea until you can come back to it

sour island
#

If you set ghost mode wouldn't everyone be invisible to everyone else?

static oyster
#

Makes your character invisible

sour island
#

Oh, hm

static oyster
#

Ghost mode removes the sounds and zombies ignores you afaik

#

But you are still rendered

sour island
#

Out of curiosity how does very poor eyesight play like? Can you basically walk up to zombies?

static oyster
#

I never tested it but a guy here was complaining that they can still see you from a certain distance, he wanted them to be purely blind, and thanks to him i have a desire to make them blind as well

#

To the point of being able to hit them on their face as long as you are not doing certain actions that supposedly would make sounds

sour island
#

But how does he know he didn't make noise?

thin hornet
#
var4 *= 1.2F;
                           if (SandboxOptions.instance.Lore.Sight.getValue() == 1) {
                              var4 *= 2.5F;
                           }

                           if (SandboxOptions.instance.Lore.Sight.getValue() == 3) {
                              var4 *= 0.45F;
                           }

                           if (this.inactive) {
                              var4 *= 0.25F;
                           }

                           var4 *= 0.25F;
                           if (var1 instanceof IsoPlayer && ((IsoPlayer)var1).Traits.Inconspicuous.isSet()) {
                              var4 *= 0.5F;
                           }

                           if (var1 instanceof IsoPlayer && ((IsoPlayer)var1).Traits.Conspicuous.isSet()) {
                              var4 *= 2.0F;
                           }
sour island
#

Even when sneaking people make a little bit of noise

static oyster
#

With code limitations i would have to just set zombie to useless with certain actions based on a distance

thin hornet
#

plus that could count as smelling

sour island
#

I'd look at IzoZombie's public void spotted(IsoMovingObject var1, boolean var2) {

#

there might be valuable info there

static oyster
#

For example if player is sneaking and distance is greater than 1.0 don't set useless to false

#

But if player is moving and not sneaking and distance is greater than x amount, set to false, reacts

sour island
#

that could work

#

but what happens when one is sneaking close by and another is screaming like 15 feet away?

static oyster
#

My only problem with useless is that they don't move around.. that can be countered by setting useless to false from them off screen or fr a certain distance from the player

sour island
#

you can tie into ZombieUpdate

#

and compare it's current target to what ever you want and clear the target

static oyster
thin hornet
sour island
#

that's good no?

static oyster
#

Idk how it works per player even tho I'm getting a player Index and what not

thin hornet
#

its not

#

what ever you do

#

it will be set right after you

sour island
#

oh I misread

static oyster
#

Ye tried to setting the target multiple times even trying to check if the target is back at the player to them change back to nil, not possible

sour island
#

I guess I got lucky as my code was setting faraway targets

#

What if you set zombies to poor sight and award everyone extra sneaking points?

#

Not perfect by far

#

Surprised there isn't a blind setting for zombies

#

there's a toothless

static oyster
#

Does sneaking works on their cone of vision tho ? Because sneaking in front of them still makes them see you

#

Behind them works great but the problem is on their cone of vision

#

So far the best option seems to be either ghost or useless.. and it's ironic how both of those 2 options have a huge con

#

One doesn't play sound and one make them literally useless so they can't even react to sounds

sour island
#

In IsoPlayer setbCouldBeSeenThisFrame

#

Going to check if this applies to everyone and zombies or just zombies

static oyster
#

Uuuh that could be something, alright

sour island
#

seems to be used only in IsoZombie and NetworkPlayerAI

#

might only apply to zombies

static oyster
#

Interesting, gonna see if I can experiment with that

sour island
#

seems like it's setting them invisible while logging in in networkAI

#

which is smart lol

#

You also have setbSeenThisFrame

#

you could tie into playerupdate

#

@thin hornet Btw, have you noticed that global libraries sometimes doesn't work? I've been including the sources into the project libraries.

thin hornet
#

hum

#

i never had problem with the global libs yet and i use em in multiple projects

#

what kind of problem you got?

sour island
#

Just doesn't stick

#

can't refer to it in scope

#

once I slap it on project libraries it works right away

#

Also, do you need EmmyLua in order to generate a lua project?

#

Talking to M13 atm to help him with his mod

#

says he doesn't see lua as a generator

thin hornet
#

i suggest installing the plugin

#

But you dont have to generate a lua project

#

i basically make a mod normally and just open that folder in idea

#

it will generate the .idea dir

#

then add the libs to the deps

#

and all should be good

sour island
#

I think the issue may be that you have 'generate lua project' as step 1, and install emmy lua as step 5 πŸ˜›

thin hornet
#

emmylua probably a good thing for the annotation of lua

#

hum

#

let me see

#

Right

#

why did i put it so far

#

hehe

smoky pelican
#

Is there any mod that lets you exit a moving vehicle at low speed

smoky pelican
#

Oh yo
thanks!

sour island
#

If it's going faster than your skill you fall hard

#

but it requires you to spam E

smoky pelican
#

all good, I just need it for low speed because of impatience KeroppiHAHA

#

car takes a few milliseconds too long after holding space

sour island
#

you have a threshold of 5 to start with

static oyster
#

I don't have much experience with zomboid and lua, but if I want to add a boolean here that can be used by 2 functions I can just do
local boolname = 0 and use then set it as 1 and 0 for true or false right?

#

just to be sure, I'm not used to lua at all, on unity we would just do private or public boolean bool name and false / true and what not

sour island
#

you can use true or false

#

However, I found sometimes not only works if you're checking with ==

#

i.e.: if not X when X is false sometimes comes back as true, because it is something

static oyster
#

that if not thing is really new to me, I'm used to do if bool / if !bool

sour island
#

@thin hornet I'm still helping with M13, he has a timed action overwrite in server for a timed action found in client - he has to move it over right?

thin hornet
#

if he overwrite something in server, the overwriting script must be also in server

#

it wont be able to require it otherwise

sour island
#

That's what I figured

static oyster
#

I guess isbSeenThisFrame and isbCouldBeSeenThisFrame doesnt work

#

or maybe im doing crap anyway, gonna keep trying

sour island
#

I would try setting isbCouldBeSeenThisFrame to false

#

on player update

static oyster
#

did that

sour island
#

hmmm

#

maybe it's a networking thing

#

you could suggest a bBlind for IzoZombies

thin hornet
#

I updated the tutorial

sour island
#

Is there a way to add a sandbox option only in single player?

static oyster
#

I have an idea, idk if this happens or if this is a glitch but

#

sometimes, some zombies that are sitting down, they dont go after you even if you walk on their line of sight

#

I wonder why and I wonder if that could be used for every zombie

#

does anyone here have any idea if this is a behavior ?

thin hornet
sour island
#

Ah well

#

his mod adds minutes per page as a sandbox option - but I'm worried about user error

thin hornet
#

wdym

sour island
#

his sandbox option will apply after the vanilla code grabs the server setting

#

meaning his option will supersede the server setting

#

I imagine some users won't read carefully, apply changes to the server setting and not his option

#

equally bothersome is only making his setting SP only

#

cause people will change it and not see results in MP

#

Now why someone would install a sandbox option for minutes per page for a mp server....

thin hornet
#

i do wonder at what step the remote sandbox options are transmited

#

i know they arent transmitted while creating a character so clearly thats after that

#

but at the character creation game time is synced with the server game time already

sour island
#

The fact server settings sandbox doesn't get updated when you add mods bugs me

#

you have to add the mods on the main menu for them to register on the host menu's settings

thin hornet
#

yeah that part is bugging me too but its alright when you know that lol

#

the host meny could be improved, like adding mod dependencies when selected in the list

#

preset i guess also

#

Also sandbox options in single player in the dev options somewhere

#

would be great haha

#

the mod i use for changing sandbox options doesnt register changes sometime so i still have to reload

#

Alright time to improve that Random Sound Events mod

alpine scroll
#

If I want to supersede an item property, do I need to pass all the old properties too?

#

Or can I do something like WalkieTalk{weight=0} and call it a day

sour island
#

Via script yes, via lua no

alpine scroll
#

I see

#

Thanks

sour island
#

np

queen leaf
#

There’s a mod that I’m dying to have, but I can’t mod and neither can I find anywhere

#

Is it possible to make it so that the little icons for shelves/lockers/containers could be color coded

#

That would solve a lot of head-scratching if I just need to remember that, say, the purple shelf holds boots, the yellow shelf holds jackets, etc

#

It could even be a little colored background or star or whateverβ€” done way to distinguish one from the other

prisma wren
#

can someone tell me how to set items to spawn in gun cases

#

and how i can find the other containers items can spawn in

#

to add as spawn locations

alpine scroll
jagged ingot
#

- createhorde3 [player] [amount=[1->500]] [inner_radius=[0->infinity]] [outer_radius=[inner_radius->infinity]]

#

Is a server mod that creates a generic command, sending all the arguments to a Lua API. That's how that works but it's a thing.

#

It requires a mod with a Java patch.

alpine scroll
#

I cannot believe there is a mod with exactly what I need haha

#

And exactly the same command I though

#

I think I need to search better

jagged ingot
#

It was made for RCON integration for Twitch streamers.

alpine scroll
#

Thats EXACTLY what I need for hahaha

#

I do stream, and I do have interactions that make zombies show up near me

#

But for now I am using only the regular createhorde

jagged ingot
#

Well let me know if you need some commands made. I'm in contact with the author. A lot of stuff is locked down in the server's Lua code and a helper is made to expose that to Lua to fix this issue.

#

Oh yeah. I also have notes on createhorde2

alpine scroll
#

To be fair

#

I would like a command that interacted with that expanded heli mod

#

That doesnt use a hotkey to trigger

jagged ingot
#

It's argument syntax is -argName [value].

E.G: /createhorde2 -x 10000 -y 10000 -z 0 -radius 10 -count 40
This spawns 40 zombies in a 10x10 radius at 10000,10000 on the ground level (z=0).

The args are:
-count (integer)
-radius (integer)
-x (integer)
-y (integer)
-z (integer)
-outfit (text ID of outfit)
-crawler (true/false)
-isFallOnFront (true/false)
-isFakeDead (true/false)
-knockedDown (true/false)
-health (decimal value)
jagged ingot
alpine scroll
jagged ingot
#

It's in the mod's steam description.

#

This one.

prisma wren
queen leaf
opal jolt
#

Has anyone seen a mod to tie a bandana around your neck?or can anyone make it?cold

cosmic condor
#

it's called riflecase

prisma wren
#

yeah theres different cases for each type of gun

#

riflecase1-3

#

pistolcase1-3

#

revolvercase1-3

#

shotguncase1-2

#

very nice file

#

it says preview.png format is invalid

cosmic condor
#

check the size if it's 256x256

prisma wren
#

it was

#

and still is

#

its a png and its the right size

#

not sure whats happening

#

now its saying there there are unrecognized files

jagged ingot
prisma wren
#

i need to have contents then mods then my media folder?

jaunty marten
#

check c:\Users\user\Zomboid\Workshop\ModTemplate\

jagged ingot
#

@thin hornet I see your fork haha

prisma wren
#

figured it out

thin hornet
#

Working on a sick update for Random Sound Events

jagged ingot
#

Nice.

thin hornet
#

I should have named the mod Random Events

#

cause it wont be just sound now

jagged ingot
#

Rename the mod but not the ID?

thin hornet
#

nah it will still be random sound events but those sound will have a real effect now

prisma wren
#

my mod is not appearing in my modlist

#

or i am blind

jagged ingot
#

Might not have power today to have the PC to mod. 😦

#

Would like to get to the UI portion of Screwdriver today.

prisma wren
#

the file version of my mod is there

#

but not the workshop version

prisma wren
mystic hazel
atomic kiln
#

So how would I go about checking the java for something that could be hard coded? I'm not even sure where to start

sour island
#

IntelliJ would let you parse the entire source for terms - not to mention look up class files by name

#

useful for researching leverage points for complicated mods

atomic kiln
#

Thank you!

#

Also, I seem to have misunderstood part of the game behaviour when I started making this mod.
I believed that any battery that was drained was automatically deleted, but that only seems to be the case if it's used in a flashlight?

wooden falcon
#

Anybody know if there is a way to make an ISButton object "click-through"? (As in, when you click it, it behaves as if you are clicking on whatever is behind it so that it doesn't block normal game behaviour.)

jagged ingot
#

Maybe the ISButton cancels the click in the Lua side.

rare berry
#

why does debug load me into a black screen interface with 4 options on the top left of my screen?

fringe ridge
#

cuz something is throwing an error

atomic kiln
#

It's the debugger, does pressing F11 close it?

#

I had an issue with this the other day, f11 didn't close it, but verifying files on steam fixed it

fringe ridge
#

I have to press Shift+F11 i believe, since F11 opens my steam overlay, Could be CTRL+F11 though, not sure

atomic kiln
#

Overlay is Shift+Tab for me

fringe ridge
prisma wren
fringe ridge
#

it shows for me, do note that it takes a few minutes after every edit/upload cuz steam is checking your content for phishing/scam crap

lusty nebula
#

A question: If I set to an item ChanceToFall = 80 it will have the 80% of chance of falling, if instead I don't insert the line ChanceToFall at all, it will never fall, correct?

atomic kiln
jagged ingot
jagged ingot
#

See the list directly to the left of that terminal output?

#

I see something above saying zombieVersion

atomic kiln
#

The error is just zomboidVersion non-zero exit value 1

jagged ingot
#

Might be more related to your gradle setup.

#

I know I had these issues when working with gradle in general.

#

Mine was more to do with Kotlin. Not sure what your issue might be,

#

Maybe customize the template for what you've imported to be unique. Maybe double-check libraries?

#

Also JDK version.

atomic kiln
#

I hate java angery

jagged ingot
#

Hope you find out the cause though. Errors with no description can be irritating.

#

Also you can run a full stack debug flag to gradle when running it.

#
-S, --full-stacktrace
Print out the full (very verbose) stacktrace for any exceptions. See also logging options.

-s, --stacktrace
Print out the stacktrace also for user exceptions (e.g. compile error). See also logging options.

--scan
Create a build scan with fine-grained information about all aspects of your Gradle build.
#

Run your command with this.

#

Might show you your issue.

#

Hope that helps. Contact the author of the template you're using if you can't find a fix.

atomic kiln
#

Stacktrace just tells me the exact same thing WEH

jagged ingot
#

Hmm I'd try to help but my gradle files are in kts

#

@thin hornet Is this your template?

#

I saw io.pzstorm.capsid

toxic walrus
#

HELLO

#

Does anyone know if the attached weapon definitions global chance is per list

#

Or is there 1 file that will define the overall global chance

unborn citrus
#

So

#

A mod that adds in gender dysphoria as a trait

#

And it causes stress a lot of the time but has ways it can be mitigated

#

And throughout the map testosterone and estrogen spawns in hospitals and stuff

#

And if you take enough it changes your character to whatever you took respectively

#

This is a dumb idea but whatevs

jagged ingot
#

@alpine scroll Did you have any issues with that mod?

#

Oh he's streaming. mb.

drifting ore
#

Hey all. Me and a few friends are working on a 300-years-into-the-future desert/swamp map. If anyone wants to help with mapping, modding, or modeling, please contact me--we have a lot of resources and time available, as we're part of a dedicated community with 550+ players. ^^

#

ah, and you'll get some rewards. not money, but power 😈

#

(money's better but eh)

jagged ingot
#

Looks like fallout.

drifting ore
#

that's a lot of the inspo hahah

#

one of our factions :)

rancid verge
#

I think I've found how to change the global setting for how much zombies are slowed down by trees but does anyone know how I could give a specific zombie their own tree speed modifier?
I'm looking to make a sprinter special infected that isn't slowed down in the woods

jagged ingot
rancid verge
#

Ah that'd be a shame :(
I feel like it could really add to the fear of being in the woods at night

jagged ingot
#

Was excited to see & try out night-sprinters recently.

#

Mods being able to do more with zombie behaviors would be epic. I know we can do some stuff. I don't know the list of things we can do though.

rancid verge
#

Hopefully more functionality for special zombies will come with the animals update
If they need to keep track of animals even when not loaded that system could be used for keeping track of 'boss' zombies and their stories, which would be brilliant

foggy salmon
#

I'm in the "Firearms" mod code right now. I'm assuming the higher the number the more likely an item of the type is to spawn. Would just like clarification from someone who'd know.

rancid verge
#

Yeah that's correct, this should explain a bit more

#
foggy salmon
#

Thanks.

jagged ingot
#

Interesting guide.

alpine scroll
lucid spindle
#

Has anyone seen a document, tutorial or explanation of how to code so that a mod works in both single player and multi player with things like getPlayer() vs getOnlinePlayers() ??

#

Or have any advice?

jagged ingot
lucid spindle
#

Yes but I need the list of players 😦

#

getOnlinePlayers() returns a non-arraylist in SP

jagged ingot
#

Yes. If it is a client in multiplayer it returns a list.

#
return GameClient.bClient ? GameClient.instance.getPlayers() : null;
lucid spindle
#

So to get the "list" of player sin SP I have to put getPlayer() into an ArrayList. I did a warpper function. But now I feel like I am missing all kinds of things 😦

jagged ingot
#

isClient() is a boolean call you can check

#

You can also make a method to compile a list regardless, say a table.

lucid spindle
#

Yeah I use that and isServer() in my wrapper.

jagged ingot
#

well isServer() would work on the server itself.

#

This flag is set to true only if loaded as a full server.

lucid spindle
#

if not isClient() and not isServer() then -- executing in SP

jagged ingot
#
function getPlayers()
  local table = {}
  if isClient() then
    local players = getPlayers()
    for i=1, players:size(), 1 do
      table[i] = players:get(i)
    end
  else
    table[1] = getPlayer()
  end
  return table
end
#

Just wrote it here so didn't test it

#

but could be something you can do if you want to simply have a list for either case.

lucid spindle
#

What I actually have is... lua function GetPlayers() if not isClient() and not isServer() then -- Single player - return getPlayer() as an array list. local retAL=java.util.ArrayList:new() retAL:Add(getPlayer()) return retAL else -- Multi player - return the list of players. return getOnlinePlayers() end end

jagged ingot
#

That'd be more flexible yes.

lucid spindle
#

I guess there's a bunch of places I am missing things like this 😦

#

At least I have this Discord... er... when people are awake lol

thin hornet
#

Not exactly what is discussed here but i use this function for getting a specific player

---Get a player object from a username
---@param username string
---@return IsoPlayer
function Utils.GetPlayerFromUsername(username)
    if isServer() then
        local players = getOnlinePlayers();
        for i = 0, players:size() - 1 do
            local player = players:get(i);
            if player:getUsername() == username then
                return player;
            end
        end
    end
    return getPlayerFromUsername(username);
end
jagged ingot
#

I'm a Java modder so I get away with so much shit.

#

Oh, hello GameServer.getAnyPlayerFromUsername(..)

lucid spindle
jagged ingot
#

The logic should work

#

Just thought maybe I mis-typed something.

#

I just noticed something funny about the scripts for the game.

#

So there are commas in the script schema for properties for items.. The last one has a comma too.. I wonder if this is rendered using a private, in-house tool made for TIS developers..

#

It looks like rendered text because in most languages, a comma for the last line is optional and not written manually.

#
    item Dogfood
    {
        DisplayName = Dog Food,
        DisplayCategory = Food,
        Type = Food,
        Weight = 0.8,
        Icon = Dogfood,
        CannedFood = TRUE,
        CantEat = TRUE,
        Packaged = TRUE,
        Calories = 498,
        Carbohydrates = 77.56,
        Lipids = 12.58,
        Proteins = 16.04,
        WorldStaticModel = CanClosedDogFood,
    }
#

Just a thought..

lucid spindle
#

Yes I have noticed that before too. It's something humans don't tend to do unless they do it intentionally to copy generated code.

jagged ingot
#

I'm about to write a compiler for it so yeah definitely noticed it.

#

Curious about the whole in-house software thing.

lucid spindle
#

Can the debugger actually be used for examining variables, etc? It looks like it can but I can't see anyway to do it.

thin hornet
lucid spindle
#

I mean like when you put a breakpoint in your code and it breaks in there. How to see what's in the actual variables.

#

(i.e., including local variables)

thin hornet
#

use error()

jagged ingot
#

Doesn't the UI for debugging have a stack?

thin hornet
#

it will open into the F11 debugger and then you can double click the fields to see its value

lucid spindle
#

Yeah I mean in the F11 debugger

cosmic condor
jagged ingot
#

The debugger gets fun when you error out before loading the AngelFont textures.

thin hornet
#

well its no joke, error( var ) will let you examine an object in the F11 debugger

jagged ingot
#

I actually found out how to include my own fonts.

thin hornet
#

as in a mod? or java mod

jagged ingot
#

The sad part is that PZ locks their ISUI code to use exclusively UIFont enum.

#

Lua mod.

thin hornet
#

hum

jagged ingot
#

I think that using UIFont is limiting.

thin hornet
#

tell me tell me i wanna know everything

jagged ingot
#

It's a bad limitation in the game and personally see it better to use string identifiers instead.

#

The modder that made the TS stuff, Jab is making a big mod that is Java modded, however uses a custom AngelFont.

#

In any ISUI object, you can't quickly use it because of UIFont being the parameter passed in most functions.

#

Overriding those functions are the only option, unless you pass the font itself IIRC.

cosmic condor
jagged ingot
thin hornet
#

im tempted to add fire at the nuke location lol

#

but that might be a bit too much

#

whole map going to burn in 5 minute

lucid spindle
#

Is there a reference for the debugger? Trying to figure out the keys for step in, step over, etc.

jagged ingot
cosmic condor
thin hornet
jagged ingot
#

Still, should we be limited to only using UIFont enums?

#

Personally I think it should support both the enums and custom font IDs.

#

Just my opinion.

thin hornet
#

UI that should be rendered in lua [ LoadingScreen, Watch Clock ] really would be great

cosmic condor
jagged ingot
#

Oh yeah.. the clock in the top-right is done in Java.

thin hornet
#

custom loadscreen would be great and that stoopid clock need to show minutes and maybe even year

jagged ingot
#

πŸ™‚

#

No release yet but it's the mod for that project I just mentioned that'll contain access to modifying GLSL shader uniforms from Lua, music, and things like the login screen.

thin hornet
#

well im staying away from java mods as i want to have the same experience as the standard users to dev/test mods etc

jagged ingot
#

Heh. Yeah no that makes sense.

#

It's good to have the option though.

thin hornet
#

otherwise i would have made java mods already haha

#

but java mods are cool and would be great if it was more supported imo

jagged ingot
#

I'm more on the side of "Mod first. Ask questions later".

#

hahaha

cosmic condor
#

Is this why no one creates custom watch faces mods?

thin hornet
#

yeah

#

that clock need to go

#

straight into a garbage

#

xD

jagged ingot
#

The Java class for the top-right panel uses color gradient OpenGL calls IIRC to create the effect

thin hornet
#

we need to have arma3 watches

#

hold a key to watch your watch

jagged ingot
#

zombie.ui.Clock

thin hornet
#

hold key to watch your compass

#

lol compass in isometric world

#

clock not showing the minutes -.-

#

make since with a fast pace game

#

but when setting Day length to real time it make no sens anymore

jagged ingot
#

Ah I see it now

thin hornet
#

also could add the year at the end 14/07/22

jagged ingot
#

AngelCodeFont.drawString

#

You have to handle internal instantiation and manually call methods.

lucid spindle
#

Year should be 1993 right?

thin hornet
#

i set it to system sync with my mod

jagged ingot
#
local font = AngelCodeFont.new('media/fonts/strong.fnt', 'media/fonts/strong_0.png');
local text_width = font:getWidth('Continue');
        font:drawString(
          center_x - (text_width / 2.0),
          center_y + 150,
          'Continue',
          1.0,
          1.0,
          1.0,
          alpha
        );
#

This is how you draw your own font.

thin hornet
#

also GameTime doesnt have a second setter so basically cannot achieve real real time

#

will always have a couple seconds delay

jagged ingot
#

@thin hornet, you could add that to your tutorials.

jagged ingot
#

The code block I just posted shows how to draw custom AngelFonts.

thin hornet
#

Ah my tutorial is just about setting up the workspace and decompiling tho

jagged ingot
#

Oh. Thought it was broader.

thin hornet
#

does this snippet work out of the box?

jagged ingot
#

I use the tool fernflower CLI directly for my decomps btw.

jagged ingot
thin hornet
#

does fernflower generate jar libs?

jagged ingot
#

It's from Jab's prototype code.

#

Fernflower is what IntelliJ uses.

thin hornet
#

ah ok

jagged ingot
#

I don't repackage using fernflower.

#

I do that with a custom injector.

thin hornet
#

i use capsid cause it does a couple thing out of the box

jagged ingot
#

This creates a JAR and runs an injected environment for servers.

#

It's built to inject jars as patches.

thin hornet
#

hey wheres the readme

#

πŸ˜›

jagged ingot
#

I agree. Needs one.

thin hornet
#

also descriptions

jagged ingot
#

It uses a JavaAgent to dynamically inject all native and third-party dependencies for the PZ environment then allows for custom patches by people.

#

(If you wanted to know)

thin hornet
#

so that we get a general idea what woodglue and other item name are

cosmic condor
#

instruction unclear. Nuclear missile launched ☒️

jagged ingot
#

Hehe. You talking about JARing PZ reminded me of this tool. πŸ™‚

#

It does that though.

thin hornet
#

get into a shelter asap

jagged ingot
#

This is what the dir for WoodGlue servers looks like. πŸ™‚

#

Well without the src folder

thin hornet
#

i know pzst does offers java patching on the server side plus many other tools

jagged ingot
#

I saw that.

#

Looks nifty.

thin hornet
#

i wonder how hard it would be for my nukes to blow up some random windows

jagged ingot
#

You'd have to locate the windows in the area and calculate the chance, breaking them.

#

πŸ˜„

thin hornet
#

yeah but im not sure if the area will be loaded

#

nuke have a pretty big range

jagged ingot
#

BTW why does IsoCell:getWindowsList() only populate for client instances?

#

Is empty on server. Have to crawl for them manually. 😦

thin hornet
#

theres alot of stuff that doesnt work on one side or the other

jagged ingot
#

Well it's mostly server-side.

#

I can definitely say this for zombie.iso

thin hornet
#

its always unclear what is two sided

jagged ingot
#

@thin hornet I have goodies

#

This utils is built for server stuff that's missing.

#

(Alongside other general helper functions)

#

Works to compensate for the issues regarding server not having lists to access like clients.

#

I don't think anyone codes Lua for the server folder though.

#

Not since build 40 probably.

drifting ore
fresh notch
#

Hello, I need a small help

#

How can I use base game tiles (let's say, a brick wall)

#

and use that in a mod?

eternal garnet
#

Question.

If I am making a helmet, is there a way to make it where, when you wear the Helmet, the base game model does not pop through the helmet?

Kind of looking for the same mechanic as what Fallout 3 and New Vegas does where the helmet essentially overwrites the base games biped.

TL;DR If you wanted a small helmet, don't want the base games biped to pop through.

winter bolt
#

oh i thought there was one that hides the head but i'm not sure

winter bolt
#

apparently not? I think the full invisible one does hide the head though

eternal garnet
#

I will give it a try, thank you anyway πŸ˜‰

smoky vine
#

Anyone know if theres a mod that stops the saplings from either spawning or slowing down cars?

late hound
#

Mask 0 hides head

frosty falcon
#

can you change zombie scale/height at all?

drifting ore
#

Sadly no

#

They use the normal player model mesh

#

With a different texture and animation set

#

I think a few people here found a way to kinda spoof it using custom clothing and stuff

frosty falcon
#

ah I see, thanks for explaining

queen leaf
#

I’ve asked this question before, but I’m hoping to learn more β€” is it possible to change the icons for various containers within the game?

#

I would really, really like to have the option to change the icon of , say, a wooden crate. Give it a green star in the background, or make the crate itself yellow

#

A little blue square in the corner of the icon

eternal garnet
rare berry
#

why am i still getting partial debug options after disabling debug in the launch options?

winter bolt
eternal garnet
#

Ah, I did not see this. Thank you ❀️

normal barn
#

For WorldEd, is there anything I have to do when setting up mod tools in order for BMP to TMX to work? It will generate the files, but refuse to display them in WorldEd. If I save the world and restart the program, nothing will be shown. If I click on the cell, it will show the generated cell in a new tab.

I tried to do this from scratch on my laptop, but it wouldn't give any different results from my PC.

Edit: I've tried png and BMP file types on paint.net and gimp with no difference.

eternal garnet
#

@winter bolt Sorry to @ you again.

It's just made my characters head "Black"

This is what I have in my code

late hound
winter bolt
#

it might only work if the item is static?

keen cape
jaunty gate
normal barn
sage bluff
#

Hi, I want to learn how to make mods for project zomboid but am struggling to find any good tutorials, does anyone have any suggestions for how I can learn?

sage bluff
#

No, I’ll watch him. Thanks

spark vector
#

I think part of the reason for the repetitive comments is my fault, though. I only updated the English title and description. So anyone who is using Steam in other regions was still seeing the old info and had no way of knowing that the mod was obsolete, unless they checked the comments.

#

Rather than just continue hope for the day that the last person eventually figures out that the mod is obsolete, I am now thinking it might be funny to instead update the mod so that literally all it does is automatically check the "select all clothing" option in the sandbox options 🀣

#

I haven't actually done it but I'm considering it

timber river
#

is a mod that lets you return the power and water to the entire map possible? I know the commands exist, but I was thinking something more along the lines of Save Our Station! but to get the utilities back up for a bit

drifting ore
#

Been talked about A LOT but idk if anyones ever done anything mod wise

broken briar
#

like you can put 0-5 years

#

this can give you a lot of time to prepare for any time if the power goes out or the water is cut off

true hollow
#

Hello, I'm trying to learn to program in lua for the zomboid project, I was trying to configure my INTELLIJ but I got confused in a part where I couldn't find some files, here are some prints (if anyone can help me or point out what I'm doing wrong I'd appreciate it) .

#

The tutorial

#

my files

#

I don't know if this is involved with step five (I didn't do that step because I didn't understand)

timber river
drifting ore
#

Could just do that as admin

#

Have your players fight off a giant horde at a power station

thin hornet
#
  1. Create a directory to keep it organized
    Anywhere in your computer, create a directory named zomboid-decompiled.
    In that directory create a new directory named with the current version of the game.

Copy the 3 jar files into that new directory and optionally copy the build/generated/sources directory.
You can rename the files to append the version for later.

true hollow
winter bolt
#

i'm ready to update my mod but theres an empty slot in my preview image that's going to destroy me if i don't make something to fill it lmao

lucid spindle
#

Do some screenshots of your mod in action and use those?

tranquil reef
#

how am I supposed to find the guids for items lol

blazing vine
tranquil reef
#

Is there a tutorial for this clothing.xml file lol

#

Literally have no clue what I'm supposed to write in it

blazing vine
tranquil reef
#

that doesn't explain this file though

#

Unless I'm blind

blazing vine
#

If you open it you can see how it pulls from the fileGuidTable to get clothes into a outfit category

plucky junco
#

maybe i'm wrong, but I think the guid it's just a random code for identify the object

tranquil reef
#

How can I change zombie speeds during run-time

tranquil reef
#

is it even possible in build 41?

cosmic condor
#

Ctrl+Shift+[

#

save a lot of time

mystic hazel
true hollow
#

why does this error happen?

thin hornet
true hollow
#

πŸ‘

rustic cosmos
#

i noticed theres this distinction of lua-based zomboid mods and java mods? are all the pz mods on the workshop purely in lua?

frosty falcon
ivory bolt
#

im having a lot of trouble with mods atm. i cant seem to get any to work (only using workshop mods)

shadow geyser
static oyster
#

so

#

this game an interesting result

#

zombie:postupdate(zombie:setTarget(nil))

#

not useable tho

#

still interesting

#

sometimes they see me sometimes dont and then they move with a weird animation and then stops randomly lol

#

with no attack animation

#

it was just me trying to find a way to still set their target to nil anyway

drifting ore
#

where can i find the vanilla profession names for adding them to a custom map?

#

or are they the same as in the character creation screen?

thin hornet
#

probably a better place too look for but real quick thats what i found

small topaz
tranquil reef
#

for some reason the zombie is spawning naked, it spawns with the Token_Tank item but it's just naked lol

viral notch
#

help me

tranquil reef
#

Lol I don't really ever play with any of my mods

smoky meadow
#

can someone help me, i have this crazy bug when you attach some scope to your gun, it get's rejected.

tranquil reef
#

Now I need to figure out if it's possible for a zombie to give you a fracture once it grabs you lol

silver dove
thorn cipher
silver dove
#

@thorn cipher
thx

vivid imp
#

Hello, I'm doing my first mod. It is just adding some popular drinks from my country. But I'm having an issue when I refill with water the emptied bottle. The "Drink" option does not appear in the submenu. Am I missing a property?

thin hornet
#

cause the option doesnt show if not thirsty

#

make sure u not godmode

vivid imp
#

not godmode

thin hornet
#

does a regular water bottle show the option?

vivid imp
#

let me check again about the thirsty

#

I'll check that too

thin hornet
#

yeah lets just discard this possibility

vivid imp
#

thanks

thin hornet
#

cause your script look ok to me

tranquil reef
#

Is there a way to do something once a zombie grabs a player

#

Also I'm assuming there's no way to add custom animations to individual zombies lol

vivid imp
# thin hornet cause your script look ok to me

I checked, the character is thirsty and Drink option is still not available, but I took a Water Bottle and the option is not available from that item too, so, I'm overwriting something

#

I tried setting it as DisplayCategory = Food, testing right now