#mod_development

1 messages Β· Page 294 of 1

bright fog
#

wdym ?

tranquil reef
#

Ah, I've been awake for like 15 hours so my reading comprehension is ass

#

Thought you two were talking about making custom flyers

#

Not drawing on them

bright fog
#

Yea I thought that's what he wanted

#

His original question definitely meant that, tho that's not what we wanted to know himself

long perch
#

I explained myself a little bit wrong I guess

tranquil reef
#

My guess is what writing on the flyer would be significantly harder than it's worth

long perch
#

it does not necessarily have to be a flyer, writing in general on an image

tranquil reef
#

The draw on the map mod only works because it basically takes the default game's symbol system and just makes it happen when you free draw. That's the only mod I've seen that has ever gotten close to custom drawing

tranquil reef
long perch
#

for now I guess using the tools in the game that allow me to write / put symbols will be enough for me

silent sky
#

Hey guys if i just wanted to do a simple retexture of something would I just put the retextured png in the appropriate texture directory with the same name

long perch
brittle geyser
#

this is B42, possibly a B42 issue

sour island
#

Did you set a blood texture?

#

Looks banded like a UV map

brittle geyser
#

I didn't change anything related to blood textures. I only added a texture that corresponds to the model

#

I'l ask in the mdoelling channel thanks!

quartz badger
#

Hello, I have a problem. I can't find FBX model for beer can. I assume that same model is used for diet cola, beer can and etc.

vast pier
#

Why did bro become skinward

vast pier
#

not seeing anything about
SetTraitDescription
What would the equiv be for professions?

#

nvm it's
SetProfessionDescription

#

taken from MainCreationMethods.lua

    local profList = ProfessionFactory.getProfessions()
    for i=1,profList:size() do
        local prof = profList:get(i-1)
        BaseGameCharacterDetails.SetProfessionDescription(prof)
    end```
weary matrix
silent zealot
#

nice.

weary matrix
#

Still have to find a proper name and poster for this mod by the way πŸ˜‚

silent zealot
#

I agree with TIS the context menu approach has become a huge mess, but right now the UI is still... quirky

weary matrix
#

yeah well, the whole game is a huge mess πŸ˜‚

hot plinth
#

Anyone know where parcel loot table is set? 😐
Or mailbox loot table for that matter?
I can find mailbags and postbox but not the houses mailboxs.

floral patio
#

Does anyone know how guns are coded in B42? Because in the media/scripts/items/items_weapons_firearms.txt, guns seem to have a Hit Chance just like in Build 41. I do notice that the closer the zombie, the easier it seems to be to hit the zombie, is there any file in the game that dictates how far is considered "point blank range" where I have a significantly higher chance to hit?

#

Also, by how much does the point blank range increase the chance to hit the zombie?

floral patio
#

This also makes me wonder, don't firearms function practically the same way they did in B41?

silent zealot
#

And they are very different to B41 - in B41 you point in a direction, the game pretends you have a really really really long melee weapon and highlights the zombie(s) you will hit.

#

Now you fire a projectile in 3d that hits the 3d zombie model. Or doesn't.

#

Tip: when using a shotgun make sure you car is not behind your target.

floral patio
#

Certain guns had a higher default hit chance than the others back in B41

silent zealot
#

that may still be the case, but more like guns in an FPS

#

i.e.: how close to they hit to where you aim?

#

instead of being like a taletop RPG when you have a X% change to hit, for percentile dice and decide if you hit.

floral patio
#

So where is the code for guns and how they aim and fire now? πŸ€”

#

I mean, this is probably a worthless question now since the whole gun hit chance thing is getting replaced with a damage chance next patch

#

So soon enough guns will always hit, but whether or not they damage the zombie is a different story

bronze yoke
#

the rework is that aiming is actually physically simulated so 'hit chance' isn't really a concept anymore, it's not a dice roll it's based on spread and stuff

#

i would guess that hit chance either doesn't do anything or is just reused to affect spread or something

sacred matrix
#

Are b42 mod dependencies working? In a test sub-mod, the mod names have a backslash in front of them, so the dependencies don't line up.

floral patio
#

And the reticle can get small enough to where all of it is on the target

sacred matrix
vast pier
#

@silent zealot soooooo how would I make the description use the language translation files so it's not hard coded english

#

Assuming it's not 3am for you again

silent zealot
#

getText("IGUI_StatsAndBody_Hunger")

#

that's it

#

so simple

#

it will return the string you give it OR the version of that string defined in the translation files.

#

Translation files are special - they're not really lua even though they are in lua\shared\Translate

#

make the folder media\lua\shared\Translate\EN

#

create a file with the same name as the equivilent vanilla file, which is normally something you want to avoid. In there you put your translation strings

vast pier
#

Ah I know how to do that, I just thought there might be a way without copying all the translations myself 😭

silent zealot
#

You only need to put the new stuff in your file

#

they get automagically merged

#

Like for this mod, I will have only one translation string in teh translation file:

vast pier
#

I know but it's an existing translation. It just doesn't get translated due to when it gets loaded I'm pretty sure

#

Remember? It was the description for the handy trait, it wouldn't translate due to it being injected with lua, so I hard coded it to be English.
It may just be cursed to be in english

bronze yoke
#

all translations are loaded before lua

#

if you can't get a string to translate i'm sorry to say it is user error

vast pier
#

It would load the translation under normal circumstances, but it has to do with traits displaying text.
I believe it to be a special case, as we have to reload the trait display for it to generate the stat display properly

#

It would add the stat properly, but would not display the text for it

#

I'm sure if I overwrote the trait it would translate fine without changing anything

#

Trying to avoid overwriting anything for compatibility

silent zealot
#

No, what you do is take that string you use

#

make it a new translation entry

vast pier
#

Wouldn't I need to do that for every language?

#

It's the same string used in vanilla

silent zealot
#

You do it for English only

#

If people want they can either send you translations for another language that you add, or make a mod that adds a translation

#

So for my mod, playing in EN will see "Lick Battery" but playing in FR will see "ContextMenu_LickBattery" because there is no translation entry.

#

If a french player says "the french translation file is ContextMenu_FR = { ContextMenu_LickBattery = "Lick Le Battery", } then I can add that to the mod.

bright fog
#

MDR

#

Lick le battery

#

Nah man what

silent zealot
#

And if I don;t respond, they could release Battery Licker: French Translation

silent zealot
#

back to the original question - it was a string that is already in the translation files?

#

In that case just find out what it gets called, and replace "My English Words" with getText("IGUI_Trait_Handyman") or whatever the proper translation identifier is

bronze yoke
#

if it's a vanilla entry you shouldn't need to duplicate it

silent zealot
#

yeah, I misremembered - I thought we added a new string

covert carbon
#

How do you re-open the command console in debug mode

#

Surprisingly this is the thing that stumps me

vast pier
#

Yeah I was using the vanilla translation string and you said this but I didn't understand it

#

So I just hard coded it to be English since the vanilla translation string wasn't working

finite scroll
#

can i replace .png textures with textures in a .PACK format?

silent zealot
#

Cheese:setDescription(getText("UI_trait_handydesc"))

#

SomethingThatTranslates:getTranslation was my 3am way of saying "put the translation function here"

bright fog
ancient grail
covert carbon
#

How do you know when a custom context option you've added has been selected?

bright fog
#

Just that weird part about scripts

#

But that has nothing to do with it

bright fog
#

So when you click, it triggers the function, and sends the arguments you set in addOption

#

It's a specific writting, I need to make a guide for it

covert carbon
#

Time to start digging lol

#

Oh also, I don't get if I am doing this right, but every time I change my code I have to restart my game in order to reload it. I've tried reloading the lua file in the debug menu, but it only works once before not being usable. Is there a way to reload lua without this issue?

bright fog
#

You can however reload all the lua files in the main menu

#

You can't have problems with that

#

But yeah reloading specific files, you need to be aware of stuff that might break in the caching of stuff for example

covert carbon
bright fog
#

Also

covert carbon
bright fog
#

Check the community debug tools

covert carbon
#

Where can I find it?

bright fog
#

There's a tool to reload multiple files

#

And without opening the F11 menu

covert carbon
#

This is going to split the time required for this mod in half

#

Thx

bright fog
#

Yup

south bear
#

Is it possible to get/setStats from server side with lua?

bright fog
#

It's client side

#

Should be at least

south bear
#

SO question -

#

If you send a server chat message, that is read by a client side mod and then do something on a local client...

#

Is there some sort of server sync that would then overwrite that change?

#

Like if I have a mod that changes my xp to max in Fitness, won't the server see that change and be like - ummm no chance dude. Nice try!

bright fog
#

I'm not familiar enough with it, but could be locked behind one of the anti cheat

#

Which can be deactivated by servers

#

There's different AC rules which are on/off options

south bear
#

Gotcha

#

Not trying to make cheats here - trying to understand just what all is possible to change/affect from serverside

#

It just so happens that the one thing I can think of as a workaround would likely be seen as a "cheat"

bronze yoke
bronze yoke
#

be aware you should expect most things to move to the server in b42 mp - very few mods designed for b41 mp will still work

vast pier
# vast pier πŸ‘
local function SaltyTraitChanges()
    local Hondy = TraitFactory.getTrait("Handy")
    Hondy:addXPBoost(Perks.SmallBlunt, 1);
    Hondy:setDescription(getText("UI_trait_handydesc"))
    BaseGameCharacterDetails.SetTraitDescription(Hondy)
    local Engiheer = ProfessionFactory.getProfession("engineer")
    Engiheer:addXPBoost(Perks.Maintenance, 1);
    Engiheer:setDescription(getText("UI_profdesc_engineer"))
    BaseGameCharacterDetails.SetProfessionDescription(Engiheer)
end
Events.OnGameBoot.Add(SaltyTraitChanges);```
Translates properly πŸ‘πŸ‘
silent zealot
#

I don't expect a lot of security in B42 multiplayer either - it's a big piece of work to make a secure multiplayer game, and means loading more onto the server instead of trusting the clients.

vast pier
silent zealot
#

Limited anti-cheat to catch some blatent abuses is likely the best Zomboid will ever get.... and a bunch of that will need to get turned off for various mods anyway.

vast pier
#

Best moderation is self moderation!
Don't be a cheating loser outside of singleplayer or friend groups :)

silent zealot
#

But even really basic stuff like you can't stop the client spawning items because the client spawns items every time you take a battery out of a torch or reload a pistol.

bronze yoke
#

from what i can speculate from reading the b42 code, much of which has been restructued for multiplayer but of course the multiplayer code itself is removed, a huge amount of stuff has been moved to the server

silent zealot
#

Yeah, self moderation is the best for an indie game.

bronze yoke
#

this is something we know for a fact

silent zealot
#

Also, I think the learning curve keeps a lot of griefers away.

silent zealot
vast pier
#

Makes the experienced ones even worse. Cuz it acts like a filter

long perch
#

I asked before but well it's been quite a few hours and maybe there are other people. I would like to use the map functions to write/put symbols in a flayer/png/custom image, do you know if there is a way? Either make a map and actually the map is a custom png or do it by adding to a flyer the overlays of the map. I tried before with both ways and I couldn't, but I'm very novice so idk

bronze yoke
#

whitelisting and moderation is the only viable way to keep a pz server genuinely secure

vast pier
#

Even then, be aware what's in the mods you download. Could be a backdoor lurking.

#

That's a bit much to ask from the average player, but server owners should be more thoughtful about it

silent zealot
south bear
bronze yoke
covert carbon
# silent zealot

Prank your friends by licking their flashlight batteries when they aren't looking

silent zealot
#

I should re-record with out music playing so I can add that to the mod's morkshop page.

vast pier
#

Hey guys, any idea why engineer can't craft aerosol bombs or pipe bombs even though they're in the listed recipes they're supposed to know?

bronze yoke
#

typo LOL

#

Bomb should be capitalised in the recipe names

vast pier
#

oml you're right what

#

that's a vanilla thing btw

bronze yoke
#

yeah there's a lot of instances of this currently

covert carbon
#

Gotta love it

bronze yoke
#

blacksmiths had a typo in every single recipe they have iirc

bronze yoke
covert carbon
#

Does anybody know how custom context options are supposed to be connected to a function?

vast pier
#

when is the new patch supposed to drop?

bronze yoke
#

who knows

vast pier
#

so 2026, gotcha

robust locust
royal oyster
#

does anybody know why it says its missing mod.info?

robust locust
covert carbon
#

Keep the mod.info inside of the folder named "42" but move the mod.info file that is inside of "common" to the "mods" folder

#

From what I know about build 42, the common folder should stay empty

royal oyster
#

doesnt work still

weary matrix
#

for me I had to keep the mod.info at the root of the mod, and also add it to common folder (I'm targeting compatibility for B41 and B42)

robust locust
#

is the file contents correct?

#

i have it in all of them and it works lol

silent zealot
# covert carbon Does anybody know how custom context options are supposed to be connected to a f...

here's an example: ```local doDIYContextMenu = function(playerNum, context, items)
print("##### doDIYContextMenu()")
local primaryItem = items[1]
if not instanceof(primaryItem, "InventoryItem") then
primaryItem = primaryItem.items[1]
end

if primaryItem:hasTag("DIYSchematic") then
    print("##### It's a DIY Scematic")
    local playerObj = getSpecificPlayer(playerNum)
    readOption = context:addOption(getText("ContextMenu_ReadDIY"), items, DIYonLiteratureItems, playerObj);
end

end

Events.OnFillInventoryObjectContextMenu.Add(doDIYContextMenu)```

#

You add your function to the OnFillInventoryObjectContextMenu event, it checks if the item is the one you care about, if it is then it calls context:addOption() to add an option.

finite scroll
#

that's so cursed

#

it has like inconsistent pixel size

#

some areas are just completely smooth

silent zealot
#

It matches the quality of the mod's code.

covert carbon
#

Everytime I see an update on the battery-licker mod it makes me giggle

silent zealot
#

The workaround for geting rid of the charge from the battery tooltip is so stupid.... but it works.

#

Like a magician doing slight of hand... I swap the real batter for a fake one, let java make the tooltip, then swap them back.

#

The accessor function is so I can create one fake battery and re-use it over and over, since I suspect making and destroying items every frame would be bad for performnce.

tacit pebble
#

little weird question here, is there any way to update my workshop mod but not thru zomboid?
like via web or something..? I can't use steam at my work but i want to update.. :/

silent zealot
#

You can edit the description on the Steam website

#

I'm sure there are API calls that will technically allow you to update without using the game, but in practical terms I don't think you can.

tacit pebble
bronze yoke
#

you can upload through steamcmd but the structure is different

dull moss
tacit pebble
covert carbon
#

1 hour of search for a missing parameter

frank elbow
#

@white briar re. #1318920979581501502 message: That thread isn't for requesting mods; it's for modders to request stuff from the developers for modding purposes. There's a community modding discord where people accept commissions (and maybe ideas?), though

umbral raptor
#

Can someone help me with smthin?

white briar
#

Sorry about that.

frank elbow
#

No worries

umbral raptor
#

Im trying to add new furniture into the game, but i don’t know how to work with TileZ to make it. Does anyone know how to use it? I have the textures and code so all you’ll do is implement them as new tiles thro the program.

#

or whatever the name of the PZ modding tool used for that purpose

robust locust
# umbral raptor Im trying to add new furniture into the game, but i don’t know how to work with ...

add your tilesheets to the tileset (toos>tileset), make sure they are in the correct folder (2x and also a folder outside of that). then go to Tools>packfile>create pack, and create the pack file directory in the top bar, and then the + to give the directory for the tilesets (point it to the folder outside of the 2x folder, put your tilesheet png in there), then create the packfile.
You will also need to add tileDefinitions, so go to Tools>tileset>tile properties and create a file, then add your tilesets from the list that should show. this will show all your tiles, you just need to pair them up and set their properties.

#

there's a youtube tutorial (by daddydirk i think) that goes through this

solar briar
#

Today I created and uploaded my first mod to the workshop, I subscribed to it but it doesn't appear in my list of mods in the zomboid project, does anyone know if because I am the creator I can't use it that way and I have to use it directly in the mods folder of my game?

ebon dagger
#

Nah, you should be able to download it.

#

Drop a link, I'll take a look.

ebon dagger
#

Just checking, because its always the first thing to check. Are YOU on build 41?

solar briar
#

Yeah the build 41

ebon dagger
#

Np. First checkbox checked πŸ˜„

#

Hmmm

#

Nothing is downloading.

#

It MIGHT be an issue with steam at this moment.

solar briar
#

I use this mod donwolader to see if theres files and downloaded all correctly

#

well i wait tomorrow to see if works, thank u so much for ur time

ebon dagger
#

It won't let me download other mods either. I don't think its your mod lol.

solar briar
#

That's good, for me at least

ebon dagger
#

Ok, I'm working on a mod to add special ammo types (HP, AP, HEI, Breaching Rounds, etc.). So far everything is going well, other than one little issue.

Anyone have any idea how to force the tooltip for a weapon to update? The type on the weapon HAS CHANGED. Reloading uses the changed types, debugging on firing and on hit verify that the weapon is using the new ammo type, but the tooltip doesn't reflect that. Is the tooltip based on the script item and not the item instance?

I tried the following with no results:

  • syncHandWeaponFields(character, weapon)
  • and I tried update() as inherited from inventoryItem
abstract cairn
#

Just got my mod on server for testing, I'm getting this error at line 99, thoughts?
ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: attempted index: 1.0 of non-table: null at KahluaThread.tableget line:1689.

bronze yoke
#

PlayerToAdd doesn't come from anywhere, you probably meant PlayerArray

#

also for arraylists make sure to loop from 0 to size() - 1, not 1 to size()

outer crypt
#

does anyone know if findandreturn works on fluids other than water?

bronze yoke
#

and you should index them with :get(i) not [i]

abstract cairn
bronze yoke
#

like arrayList:get(0) returns the first element in the array list, :get(1) would be the second element

abstract cairn
#

my friend lied to me

#

told me LUA arrays started at 1 T_T

bronze yoke
#

that's true but that array isn't a lua object

abstract cairn
bronze yoke
#

yeah

abstract cairn
#

and just set it to 0 and then -1 from the size?

bronze yoke
#

yeah!

#

that's right

abstract cairn
#

ty T_T mfw I realize I was using a made up variable for literally 90% of this because i coded this at 4 am lmao

#

not that it was the only issue but smh would be nice if i didnt do that

outer crypt
silent zealot
#

Not sure if it will help, but I saw that a in a few places in reload code after changes were made to a weapon

bronze yoke
#

that's for networking, it shouldn't actually do anything in singleplayer (one of the reasons i mention occasionally that i believe b41 mods will not work at all in b42 mp)

abstract cairn
ebon dagger
#

Yeah, when I looked into the decompiled Java for syncHandWeaponFields it was all packet data transfers.

bronze yoke
#

i'm mostly guessing what you're trying to do here but you may want table.insert(PlayersToAdd, PlayerArray:get(PlayerTempNumber))

#

you can remove from the arraylist but i wouldn't recommend doing that as i'm not sure if it's a copy or not, and if it's not you're messing up some internals

abstract cairn
#

i am intending to remove it from that array, then move it to the other one

#

as I do not want to repeat players in the playerstoadd

abstract cairn
silent zealot
#

Since I have the decompiled code for tooltips handy - (from B41 but probably didn't change) - DoToolTip is using getAmmoType() on the live item.

abstract cairn
#

ty albion the goat πŸ™

bronze yoke
# silent zealot

yeah, i'm looking in b42 and they do the same kind of caching there

silent zealot
#

what does print(getPlayer():getPrimaryHandItem():getAmmoType()) show?

bronze yoke
#

i can't see any way to reset this

#

it seems like it should be impossible for that text to change after the tooltip has rendered once

ebon dagger
#

Ok, it might just be easier for me to make several dummy guns to swap back and forth.

#

Copy the durability etc.

silent zealot
#

Does the whole tooltip get cached, or just that specific line? Because you might be able to force an update with something like gun:setCondition(gun:getCondition())

bronze yoke
#

the problem here is this.bulletName

#

the first time it draws the tooltip it'll assign that and then never change it because it's already assigned

silent zealot
ebon dagger
#

Oof.

#

Good point.

silent zealot
#

Or you add somthing else that can be changed and need 25 of every weapon to cover both choices.

#

And then one day...

ebon dagger
#

And I've already discovered there is no way to get "MountOn" from attachments, so I can't dynamically add the new wepons to the attachments.

#

Omg, wow.

#

setCondition totally worked.

tacit pebble
#

Isn't there getMountOn and setMountOn?

ebon dagger
#

There is a set, but no get.

#

Its in the Java, but not Lua

tacit pebble
#

I remember I tried this once
print(part:getMountOn())
and it returned like
[Base.Shotgun, Base.Pistol, Base.AssualtRifle, Base.AssualtRifle2]

#

as arraylist

ebon dagger
#

I can test here real quick lol

tacit pebble
#
local MountOn_ArrayList = part:getMountOn()
print("First: " .. MountOn_ArrayList)
MountOn_ArrayList:add("Base.NailGun")
print("Second: " .. MountOn_ArrayList)
First: [Base.Pistol, Base.Shotgun]
Second: [Base.Pistol, Base.Shotgun, Base.NailGun]

I didn't go further than that because I wanted to see only if i can add something in arrayrist
and it worked, maybe 1weeks ago?

bronze yoke
#

the script doesn't have this but you can get it with field access and add to it

abstract cairn
#

this is in my lua shared NPCs folder... I don't think my trait is being initialized cause I'm getting null errors when trying to determine if a player has a trait [by this ID]

what am I missing ?_?
(I also have trait_PreyTrait.png in the ui Traits folder)

ebon dagger
#

I'm probably smoothbraining why I stopped trying to change MountOn that way, aside from that @silent zealot idea totally worked.

abstract cairn
#

this is what I've used in my other mod im working on to init the traits (and it has worked in that mod...)

ebon dagger
#

Now time to go hunt through mods and search the post history to figure out how to save item data lol.

vast pier
#

Okay but I find it hard to believe that just because it's illegal would automatically mean a professional farmer wouldn't know what season it grows in.

ebon dagger
#

Hotwiring cars ain't exactly legal either. lol

vast pier
#

yeah I also take issue with that.
An electrician, engineer, and mechanic have no concept of hotwiring a car's ignition

#

but a random burglar does?

#

🀨

ebon dagger
#

I mean, its a vocational skill for nocturnal vehicle aquisition technicians.

vast pier
#

I feel like at minimum the mechanic would understand how to do that

#

Can rebuild an entire car, ship of theseus style. Can't connect the ingition to the power.

ebon dagger
#

Can't fix the glovebox either.

#

hahahah

vast pier
#

Need an engineer for that, clearly

#

😏

#

But it's things where they maybe haven't done it before.
Growing hemp, and hotwiring a car

#

but surely though they would understand it??

#

Like maybe the mechanic knows how, but needs to gain a level in electrical first to utilize it?

floral patio
vast pier
#

Like I know the basics of making a gun, but I'm sure if I tried to wing it the thing would blow up in my hand due to an oversight

floral patio
vast pier
#

A mechanic with no experience in electrical should know it's possible.

whereas the average person with no car knowledge might not even know it's an option to begin with.

#

idk man this is the same game that makes pipe bombs deal like no damage at point blank and sets stuff on fire..

tacit pebble
floral patio
#

In the end, it's still mainly RNG-based

#

and in my opinion, I like it that way

vast pier
#

I love shoving the barrel of my gun into the mouth of a zombie and the zombie channels their ultra instinct to dodge it.

tacit pebble
floral patio
#

I installed this mod called Point Blank that instakills a zombie if you shoot it when its incredibly close to you (like 1 tile away I think)

vast pier
#

I know, just funny cuz it's cause by the rng I'm pretty sure.
At least partially

floral patio
vast pier
#

I don't like that our characters are so inherently bad at aiming

#

Humans are ranged hunters naturally, we evolved to kill things with projectiles

#

Our anatomy is literally designed for it

#

A lot of people won't be great at it at first, but they would not miss as much as we do in game.

floral patio
#

Don't forget that this is aiming with a firearm

vast pier
#

We shoot like toddlers

#

Yes but the concept of lining up your arm with your target still crosses over at least partially

floral patio
#

Aiming level 0 is the equivalent of never picking up a gun, nor knowing anything about how a gun should be handled in the slightest

floral patio
vast pier
#

I think most people picking up a gun would hit a human sized target 2 arm lengths away

#

Hell, even down a hallway

floral patio
#

So you'll still stun the zombie and make it stagger for a bit

#

So I think the next patch will make it more "realistic"

#

as in

#

you can actually hit a target

vast pier
#

Also are there any plans to make projectiles like molotovs and various grenades not so damn slow?

#

Like half the time it just hovers in the air

floral patio
#

because, again, level 0 aiming means i've never held nor handled a gun in my life

vast pier
#

If you aim straight at the ground outside, the grenade will just hover in place for a bit

bronze yoke
vast pier
#

You aim at the ground in a room, explodes almost immediately

floral patio
#

This will save your ass

#

Many many times

floral patio
#

Yep! That mod

vast pier
#

I wish your poor aiming skill was better displayed with your animations, or possibly having the crosshair itself shake to make it harder for you to aim it yourself

#

leaving it up to a number generator just feels unfair

floral patio
vast pier
#

I think the crosshair shaking but being more accurate than the current rng based system would be nice, and could reward player skill

#

Like the player skill would almost be like your character's inherent talent, being able to overcome a lack of skill with intuition

#

Just seems silly to aim directly at something, and then roll low on a die and so it just shoots into the sun or something

floral patio
#

Although I think the next patch solves it

vast pier
#

I hope so, I hate it when player action becomes heavily disjointed due to your character's skill

#

Stuff like that works fine for text based or tabletop where you're roleplaying

#

but when you're actively denying a player's action, that they are literally watching themself do. It just feels frustrating

#

Having the character's bad aim be displayed in a game mechanic would feel less cheaty

#

This would also be able to be used for other things that affect player aim.
Like panic/anxiety

#

Imagine a straight shooter gun build who forgot to smoke, aiming dead on their target. The bullet just evaporates because they're too anxious.

abstract cairn
#

how would I get the traits of the player to remove it?
[this is on the client] [the self reference does not work, but im pretty sure the getplayer returns the isoplayer... so maybe the isoplayer.character?]

vast pier
#

I'm repeating myself a lot, idk if I need more caffeine or less

bronze yoke
#

have you played abiotic factor? they use aim shake to represent skill instead of inaccuracy and i find it turns out kind of annoying

vast pier
#

No I haven't, but that seems to be an fps. I feel like the mechanic would translate differently due to it being isometric third person

#

I could easily be wrong of course.
I'm not a game dev, so it's not unlikely that a shake mechanic wouldn't work well.
I would still prefer a mechanic that represents the inaccuracy in some way that isn't just a dice roll, and has some player involvement

lapis moth
#

getPlayer():getTraits():remove(TraitType) will work

abstract cairn
tranquil reef
#

Any way to remove the ability to craft with an item without swapping it out with a duplicate custom item?

#

Someone also needs to find a way to change item textures in-game lol

#

Being able to just change the texture of a weapon when painting it vs. having one copy pasted weapon per color

silent zealot
silent zealot
split summit
#

Hello,

Is there anyone that can explain to me how to merge multiple mods ID on the same Workshop ID? I see some modders doing that like AuthenticZ

Edit. I created a hotfix for a older mod and I'd like to make other versions with different balances for different tastes, but I'd like to merge all under the same Workshop ID instead of creating many different mods on workshop

slim swan
#

Whythe translate didn't work

bronze yoke
#

Say(getText("UI_ElectricWeapon_Mode_On"))

split summit
slim swan
tacit pebble
# split summit Yes!! exactly

mods/myMod_Core/media/...
mods/myMod_Fix/media/...
mods/myMod_Misc/media/...
all you need is different MOD IDs in mod.info files for each folders.

split summit
tacit pebble
split summit
#

Yes, it shows both, and the mod2 is crashing the game, I am trying to reinstall the game again just to be sure

#

Honestly is just a mod for my server, we downloaded a mod that had a bug and we fixed the bug, so I wanted to upload so the server can download directly from the workshop, and then we thought about of nerfing the mod, but I want to keep both version and if possible under the same workshop number

tacit pebble
split summit
#

The game crashes when I open the game in debug mode

split summit
silent sky
#

Anyone done posters? I have recently learned Melee weapons and helmets but now I would like to learn posters as well if anyone could get in touch and help plz lmk

sly monolith
#

i was told that there shouldn't be any spaces in crafting recipe names in b42, how do i separate words then?

bright fog
#

Underscore

#

Always

#

Spaces are usually defined with underscores

sly monolith
#

oh ok thanks!

#

one more thing, would it be overly complicated to have corresponding icons in the crafting menu in b42? like i have an item with 2 texture choices, 2 recipes with getTexture lua, but they both have the same icon in the crafting window

silent sky
#

@winter bolt

silent zealot
sly monolith
#

nah i mean in the crafting icon, both red black and white versions are using the same icon

#

only after you craft them they are using the proper one

winter bolt
split summit
#

Do you know how can I add a description for the item of my mod, so people can know how it works when hovering over?

silent zealot
#

To the tooltip?

split summit
#

Yes

silent zealot
#

Easiest way is the Starlit API, it has an easy-to-use function to add stuff to tooltips.

#

You can also just put what people need to know in the mod description.

#

"use a turbo encarbulator by right clicking it and select "embiggen" from the context menu"

split summit
#

I see, because I see some mods like snake's modpack where they have some sort of instruction when you hover over, didnt think would be that complex for a dummy like me

#

I thought would be just an extra line on the item code using item tweaker API

silent zealot
#

The Starlit library is easy - the second link I posted has an example of adding to a tooltip

#

You just copypaste that into your mod, change the item name and change what you want to add.

split summit
#

I see, interesting seems like an option

silent zealot
#

then make Starlit a dpendency. If you want to avoid that... tooltips are not fun to work with. You can see how Albion to them in Starlit with horrible (but perfectly functional) hack, and for Authentic 1990s Battery Charge Detection to remove the charge meter on batteries I ended up making a whole new FakeBattery object that doesn't hold a charge and I quickly swap that in when a tooltip is being made then put back the original item after.

split summit
#

Awesome, I will see if it's viable to do, because it's many items

silent zealot
#

Lucky for you computers are good at repetative work.

#

set up a table with the item names and text to add, then the tooltip function just looks at the item type and pulls out the needed text.

split summit
#

I wonder how this works to have small description like on the snakes mod

#

seems even more complex than using starlit

winter bolt
split summit
#

Not sure, but how could I add something simple like this on a item mod

hushed hound
#

Do you guys know if there is a way to remove occupations entirely, or organize ones you add instead of the modded occupations being at the bottom?

winter bolt
lavish pond
#

Is there mod for B41 where you can change weapon damage ?.

split summit
naive crescent
sick ermine
#

hi! do you know which person that was, or where i can find this program?

winter bolt
#

i have no idea who it was, i dont think they ever released it

sick ermine
#

bruh moment πŸ˜”

#

allright thanks for the response

#

@sour island how long did you ban me from pz modding discord? πŸ‘‰ πŸ‘ˆ

silk wadi
#

b41: is there an easy way to hide a recipe from the context menu without hiding it from the crafting menu?

naive crescent
split summit
#

Is it easy to add a funcion like a trait into a item, for example, adding the trait dextrous to a backpack when equipped?

sick ermine
#

is it possible to read the world environment from lua? i want to scan a x by x area to check if it contains some specific piece of furniture

naive crescent
#

This part of the UI is it scalable or is this a TBD feature?

silent zealot
#

Look like they are all created in lua\client\ISUI\ISEquippedItem.lua

#

At a guess that was made for the top two icons and they just added everything else to it.

#

There' s no neat "scale" parameter though.

bright fog
naive crescent
#

I had asked in another channel to no avail, its my first day back to playing/tinkering with PZ and I had forgotten that any place besides this channel could be a cess pool sometimes

sick ermine
#

whats zomboid tps

bright fog
#

It's not constant

sick ermine
#

allright thanks

#

if i print() in lua, where does it show? (where can i find the printed text)

naive crescent
#

The consol in debug mode

#

its at the bottom left of the screen

sick ermine
#

thanks

#

🫑

sour island
sick ermine
#

ill never interact with the bots again i promise i will be a very upstanding citizen πŸ‘‰ πŸ‘ˆ

sour island
#

You could have stopped a few messages in, this is also not the place to ask.

sick ermine
#

where should i ask? i stopped the moment i saw it actually went along with my suggestive vegetable consuming requests

worthy sorrel
#

Let's not forget you tried to feed it some racist crap too

sick ermine
#

did i?

#

not sure about that one

naive crescent
#

What discord are you guys talking about?

sick ermine
#

pz modding

#

i got a bit carried away trying to break the ai bot

silent zealot
#

There's another PZ modding discord? What a way to find out.

sick ermine
#

lol

wicked crane
sick ermine
#

but i got carried away and thats 100% my fault lol

#

im asking for humble forgiveness here and idm if you guys say no

naive crescent
bright fog
#

I mean

#

It's open

#

If that's what you meant

#

It's a public modding Discord for PZ where we share much more resources and have better categories for modding

wicked crane
sick ermine
naive crescent
#

Naw I ment like private society kind of thing. I wasnt aware of this exsisting but looking at the date of when it was that link was posted it was right after I stopped tinkering and playing PZ like a full time job

bright fog
#

Tho the wiki has been updated only recently

#

So people don't automatically go to it

#

And a lot of people think this channel is basically the main place for modding

#

But when you get to technical stuff I find the non-official Discord way better, which is why I'm more active there now

naive crescent
#

I havent been around in a hot minute back when this was the main spot, im still refamilarizing myself with whats new with the game/community

bright fog
#

Here tends to be recurring questions about the same stuff over and over imo

naive crescent
sour island
#

There are also channels for every facet of modding, and we have a weekly discord-broadcast event (messages get sent to participating discord) for user generated mod suggestions.

Also, a commission board- neither of which (I assumed) TIS would want to risk facilitating here.

#

I'd also like to do another modJam πŸ˜… the last one didn't pop off as much as Id like

naive crescent
#

Oeuf a jam...im gonna have to brush up and knock the rust off.

#

Havent done a jam in a super hot minute

sour island
#

There's none planned rn

naive crescent
#

Thank god πŸ˜…

sour island
#

Now that B42 is out maybe there's a theme that could stand out

wicked crane
#

we kind of kicked around the idea of having a partner based event

naive crescent
#

Its more doable with the new skills and end game mechanics

#

Or something horror. The light propagation was honestly my most hyped new feature and it didnt let down at all.

sour island
#

That's a good point - and Jvla has been working in new features to his Forge API

naive crescent
#

Ive done a few game jams in my time so I got couple of good ideas left to bring to the table πŸ˜…

naive crescent
quick forge
#

hello I just started pz modding and I would like to learn via a doc or something, and if you can tell me how to increase the sickness of a player thanks a lot spiffo

bright fog
#

Oh to make custom zombies you mean ?

naive crescent
sour island
sour island
naive crescent
# quick forge via a mods

if your just starting off modding then familiarize yourself with the debug side of the game youll be in there a lot

sour island
#

The wiki has been updated, and has a getting started guide

quick forge
#

I'm already in debug, but how to add sickness via code

naive crescent
#

uhhh youd have to look at the guide and doc

#

I dont remember off hand

quick forge
#

can i have a link ?

#

i dont find

naive crescent
#

heres a good place to start

quick forge
#

thanks a lot !!

naive crescent
#

im sure the others have more precise information to documentation on hand

naive crescent
# quick forge thanks a lot !!

if you click the pinned button on the workshop shop channels it will show you pinned posts with relevant links and important information to help you get started.

bright fog
bright fog
#

Once I document it, sure we can make it a thing

#

I completely rewrote the framework for B42 to take into account the various improvements

#

And I improved it by a massive amount just by having that OnZombieCreate event

naive crescent
#

Is the current state of the documentation for it public?

bright fog
#

I got more planned, like Bandit does to override the control of zombies

bright fog
#

I have the doc for B41 version, and even then I really didn't put the work needed for it

#

It's very easy to use tho, simply check out TLOU Infected to see how I use it

naive crescent
#

I knew once 42 dropped the flood gate for these types of mods were going to burst

bright fog
#

I had already made it before

#

But B42 brought me one or two tools to improve it a lot

#

And I myself learned a lot

#

So rewrote it with all my new knowledge, and since I had already done the work on understanding how to do things I didn't lose my time on it, while the first time I developed it it took me a while

naive crescent
#

If May 17th was the date you dropped it for 41 then thats why its so new and fresh to me. I was on a PZ sabbatical

atomic hare
#

Guys, where in the wiki i can find info about overriding vanilla gear stats? I cant seem to find. (I want it to because i want to disable the overriding that a mod a does)

dark spear
#

hi, idk if this is the correct place to ask this, but maybe someone here has experience with making such mods and could provide help
I'm trying to make a true music addon using the true music b42 mod
I'm guessing it works because there is a lot of such mods popping up in the workshop. I've tried loading it by itself, and it seems to work , as I can find the new items in the debug item list

#

But it's not working correctly for me? Specifically, when I load my custom true music addong alongside ture music b42, it "unloads" , because the new items or cassettes are just not present, even in the debug item list, does anyone know why could this happen?

#

oh and I just noticed that all the item categories in the debug item list disappear too.. does it unload all of my mods?? why would it do that

atomic hare
sharp plinth
#

Hey guys! Finally made video showing my Project Zomboid server manager! https://youtu.be/lfyC6VQr0XU this is the next update Mod Manager πŸ™‚ any feedback be great ❀️

Hello everyone,

I’ve spent the past six months developing the Modix game server panel to compete with Pterodactyl and TCAdmin, all without costing a penny and with bringing features no other game server has yet. Much more on the way! and it's all free unlike other panels.

MODIX – GAME SERVER MANAGER BY OV3RLORD

Modix is my personal project, b...

β–Ά Play video
dark spear
# atomic hare Check your debug.log, it might give you hints

thanks, no idea why it was doing this, but I managed to fix it.
for some reason, when loading the mod, it referred to the path /home/sidoka/Zomboid/mods/home/sidoka/Zomboid/Workshop/mymod instead of the correct one /home/sidoka/Zomboid/Workshop/mymod, which, I guess, forced it to unload all the mods due to a path mismatch, or smth, I dunno
point is, I uploaded the mod to steam workshop and subscribed to it, and then removed the mod files from the Zomboid/Workshop folder. After doing this, it actually loaded fine without errors

naive crescent
naive crescent
#

Most likley its a null reference pointer or a conflict

slim swan
#

is this right in B42

#

I try to locate an item from all container

bright fog
slim swan
#

only in the inventory can work

bright fog
#

Should be findItem or recursed find

#

Check findItem methods

frank elbow
naive crescent
#

Thank you for the correction. This PZ troubleshooting my own thing is fatiguing me.

hot plinth
#

Question relating to fileGuidTable, do I need to include the entire base guid table with my additions? I noticed it in Authentic Z it basically starts with base games Guid then below starts adding their custom clothing.
But if its a matter of the mod overwriting the entire table how do different clothes mods remain compatible with each other? 😐

bright fog
#

Hell no never do that

bronze yoke
#

if you're adding outfits, you need to include the guid for every vanilla item you use in the fileguidtable

hot plinth
#

Oh if you touch a Vanilla item? Guess that makes sense. But yeah AZ seems to do that. Granted maybe they have a reason for it but I never dived into much of AZ other than getting it for the miniskirts lol.

oak hornet
#

Hello, I'm new to modding here, where do you find the "Events" Lua / Listener/ Broadcaster ?

bronze yoke
winter bolt
#

otherwise the zombie will just be naked

oak hornet
bright fog
#

I'd really like that we push to share the wiki, so it becomes an habit to modders to check the wiki for some info or resources on the subject

undone elbow
#

The wiki is good for not saying the same thing over and over again.

bronze yoke
#

in this case they just contain the same information anyway

bright fog
# undone elbow The wiki is good for not saying the same thing over and over again.

I do hope to improve it further, add new stuff, got a few bits planned but some of these I still need to learn how to do, like UI I hope to do that one day but I don't know much I need to fuck around with it, and timed action which I know well enough to be able to write something about it.

However my main goal is to actually have people share it so it becomes a centralized documentation that anyone can add to, but even more importantly is to actually have modders start documenting on it

bright fog
#

I've explained it already and already debated it, but this separation of guides and plateforms to write guides on, different gits etc is just making documentation for modding terrible

#

Everyone's fighting to repeat the same shit over and over, like Star said

Like cool you have this guide that talks about that, this guide that talks about that but at the end of the day all keep repeating the same shit over and over

bronze yoke
#

i just don't really see copy pasting existing reliable resources onto the wiki as consolidation, imo it's further fragmentation

bright fog
#

Yea no shit bcs no one's working on it besides me and maybe Chris who did some few bits etc

#

ANYONE can modify the pages

bright fog
bronze yoke
#

how so

#

idk about other resources, but i only created resources that didn't exist yet

bright fog
#

Seriously

bright fog
patent adder
#

you guys got any tips for starting to make pz mods? ive made a couple of mods for some other games but im really lost when it comes to pz lol

bronze yoke
#

???

bronze yoke
winter bolt
#

perfect timing lol

bright fog
bronze yoke
#

that's correct

#

however should i disappear it is completely possible for anyone to fork it

bright fog
#

Then that's not open, I'm sorry but that's not an open project. What if you disagree with someone wanting to add info about something, you're the one blocking the roads to the documentation

On the wiki, anyone can add on to stuff, and if we don't agree, we're forced to discuss to coexist

bright fog
#

If you're not fine the wiki, tell me about it so I can work on solutions

silent sky
#

When you mod in items like helmets and melee weapons is there anything i have to do to make sure they spawn in the world or have the chance too

winter bolt
patent adder
bright fog
# bronze yoke however should i disappear it is completely possible for anyone to fork it

I'm trying to push community effort in documenting and I don't want to have to constantly fight modders who are already big in documentation stuff to push for a global sharing of documentation that can be modified by everyone without forced limitations and leadership. That's why I didn't want to force myself onto the leader slot when I first started to look at the wiki and how we can actually use it for modding, because I'm not YOUR chief on what should be or not on the wiki. I just want to push easier documentation available for every new and older modders + it's an official website for PZ, what do you need more

#

If something is not right to you with the wiki rn, please tell me

#

Please really tell me what you need if you do need something to start getting on the wiki

#

Or tell me what you think we should do completely differently

bronze yoke
#

i haven't done anything to oppose the efforts of the wiki

#

i've contributed to it myself and i let you use the events data collected and maintained almost exclusively by me over the last two years

#

i just sent a link to a resource that answered a question and you got mad at me

bright fog
#

I know you're not opposed by it, you've accepted to help me more than one time to clarify stuff. But I'm really trying to push to use the wiki and you just never link it when it comes to event, so I just don't get why

#

You've mentioned "fragmentation" of documentation but if you accept to help the wiki to develop good documentation for modding, don't you think doing that is exactly "fragmentation" ?

#

So it just felt like you don't consider the wiki the go-to in a way and if you think that's because of how it's presented or stuff, i'd rather you tell me

#

Anyway sorry I'm not mad, just confused

bronze yoke
#

there's nothing to my knowledge wrong with the wiki version

vast pier
#

Is there a way to make it so explosives deal more damage to players? feels weird to have the pipe bomb I'm editing instakill zombies but the player can just face tank it and walk away with a few scratches

bronze yoke
#

there's probably a better way than this but there is an event when they explode so you could check if they're in range and fuck them up

bright fog
#

Maybe also detect when they take damage probably

#

I think there's an event that gives the type of damage

#

Also I just remembered I forgot to update the formating for that one on the wiki

#

Yeaaa that one lol

#

I'll fix it

vast pier
mellow frigate
#

how many pipe bombs have you throw ?

quiet plank
#

is there still a tag or flag to make a recipe hidden?

#

(in B42)

vast pier
frank elbow
# bright fog You've mentioned "fragmentation" of documentation but if you accept to help the ...

I know this exchange is over, but fwiw: I agree that just having the same info on the wiki isn't all that useful & I think it'd make more sense to just link to albion's event doc on GitHub (perhaps too late, since there's already multiple event pages). If there's a worry of it disappearing, it can always be archivedβ€”it's not uncommon to see references on Wikipedia, for example, include a live link as well as an archive link

quiet plank
#

cuz the other alternative would be to not have anything in outputs and have the onCreate put the easter egg in their inventory

bright fog
#

My point is that no one can modify Albion's guide

#

Same with every single guides

frank elbow
#

It is not a point that is true, but I understand that you're saying it's not as easy to do so

bright fog
#

Again and again and again and again and again, always people doing things on their side, yea it's github and what if you disappear or disagree with people, no cooperation, no communication

frank elbow
#

That's just my two cents anyway, not trying to put down the wiki. I think your work there will be helpful

#

I'm just talking about events in particular

bright fog
#

If we keep this argument, no pages on the modding Wiki makes sense to exist

#

Literally

frank elbow
#

Not necessarily. An events page that just explains what they are and has a list with links to further reosurces wouldn't be as duplicative

#

But I don't think there's really an issue with duplication anyhow

bright fog
#

It already links Albion's guide, the wiki already links external stuff

#

And no one can modify albion's stuff

#

NO ONE

frank elbow
#

I don't know why you keep saying that but okay

bright fog
#

always people doing things on their side, that's the number one enemy of modding documentation rn

#

The wiki, everyone can come and add to it, there is no ownership of stuff

#

I've started modding start of 2024, came into here trying to find resources, and I'm pretty sure more than a few new modders had the same experience of having to constantly ask for everything because there's never a centralized place for everything

frank elbow
#

Yeah wikis are great

bright fog
#

Or it always involves skimming through hundreds of links that were on the main Wiki modding page

#

Or stuff that are left everywhere, in idfk how many channels

#

At least 30 channels I know of that have pinned messages with important resources

#

Bcs no one wants to centralized shit

#

Let's count together how many pinned mesages alone in this single channel exist

#

Now do that x30

frank elbow
#

People can choose to contribute info where they want

#

🀷

bright fog
#

What's a good documentation if it's not easy to find

bronze yoke
frank elbow
#

It's me, I'm no one

bright fog
#

The wiki, no one can say your shit doesn't matter, you are forced into debate with others to know how the wiki should be

frank elbow
#

I didn't really intend or desire to add fire to an argument, just gave my two cents

#

This doesn't seem like a productive discussion at the moment

tidal geode
#

hello is there anything to follow on how to make clothing for pz

bright fog
bright fog
frank elbow
#

I've seen you sharing your work & I'm sure it'll inspire others to contribute as well

bright fog
#

I'm not an expert in every fields rn, and while I'm learning a lot to try and document stuff, it will take years

naive crescent
#

If you just starting to build and consolidate all the information for proper documentation especially something as complicated as how to code a game engine it would be better to get it all in one spot first then sift through it all to stream line it.

#

Its rather common in game engine documentations to see duplicates of information when looking at things.

#

calling it a Wiki is not doing it justice when its honestly a manual

bright fog
#

The main problem is that there was never a community effort to even get a centralized documentation for modding

bright fog
#

Not really

#

I mean sure for some few bits

#

The goal is to document everything that exists for modding

#

And yea some stuff are literal guides currently, but the goal is to just explain every bits

#

What's available, document stuff that exists for modding

#

I feel like that fits more the definition of a wiki than a manual ?

#

I started listing everything that's possible

#

And there's probably other ways, listing all the different ways is good too

frank elbow
bright fog
#

Yea

frank elbow
#

Guides seem well-suited for it

bright fog
#

Bcs each modders can be expert in a specific field

#

And come and tell about cool things you can do for various Java objects in this case

#

But that will be the case for UI stuff too for example

#

Timed Actions too

#

That's lua stuff

#

Later down the road, animation stuff, what could thing can you do with AnimSets

#

To trigger specific chain of animations for example etc

#

Another example

frank elbow
#

I realize after looking at that one that I didn't put the distinction in my mind into words earlier: to me, events feel more like "annotation"-type informationβ€”something that'd live in type annotationsβ€”whereas the above is more like details on what you can do with this. So, for example, a page about events used for timing (EveryX, OnTick, OnTickEvenPaused) & their differences feels more guide-like to me

bright fog
#

It'll be both, there will be guides yeah

#

We can't deny that

#

Bcs at the end of the day, people need a line to follow sometimes to get started, and guides that tell every steps are needed at some point

#

The wiki is still likely to change how things are ordered in Modding

#

Maybe guides should be put in their own categories

#

Also page names

#

Should we name those like that ?

#

Or more like this ?

#

Should we normalize it in a way ?

#

Lots of examples

frank elbow
#

Could always normalize it one way & have the others as redirects (How to make a clothing mod β†’ redirect to "Making a clothing mod" or whatever)

bright fog
#

But a lot of these pages are also leftovers of before stuff

winter bolt
#

i prefer it like "Custom Clothing Modding"

bright fog
winter bolt
#

i think they should start with the same word so theyre all grouped together on the page

trim quartz
#

Hey all, before I reinvent the wheel, is there any pre fab code to create a table in the UI, a bit like how the inventory pane works.

I've poked around the code for the inventoryPane and inventoryPage but it obviously has worlds more functionality than I need.

Just looking for a basic table system that I can add rows and columns too to show data

frank elbow
#

Applies to mediawiki too

bright fog
#

Oooh wait

#

Ok I think I see what you mean

#

And that would be amazing

#

But currently the wiki doesn't have much systems like that

frank elbow
#

I believe it does?

#

Hold on, let me find an example

bright fog
#

Redirects are used for pages that were moved elsewhere

bright fog
frank elbow
#

They can be manually added too

bright fog
#

Yea, probably

#

But that depends on how the wiki should be handled

#

@sudden lichen might know more in detail about that

#

Or what can and can't be done

#

But that's also the reason the main Modding page exists, to easily link to existing guides

#

Tho it still needs a bit of cleanup imo

frank elbow
#

All you have to do is put in #REDIRECT and the page, I believe in double square* brackets

bright fog
#

Notably at the end, I need to go through the various resources and order them

winter bolt
#

i think its mainly just to make sure old links to the page arent broken

bright fog
frank elbow
#

Redirects are pretty common on Wikipedia for linking similar terms, could be used similarly

bright fog
#

Oh I believe you lol, but yeah that'd have to be seen with Faala who's a wiki admin

#

Bcs currently I don't know a single example of it used to find more easily pages

#

But I agree it'd be great to have that

frank elbow
bright fog
#

Yea

#

At the end of the day, we can and should work with the wiki team for the Modding wiki

#

And I've been working with them

#

To apply some standards, and proper organization

#

Today we've even renamed and reorganized some Lua events wiki pages/categories to clean it up a bit

#

I also made a summary of the changes on the wiki for December

#

Was looking for it lol

sly monolith
#

I asked about this earlier but it seems the answer I got didn't solve my issue, so I have those recipes here that let you craft certain items, I was told that I shouldn't use spaces in the recipe names, then how am I supposed to separate the words without the ugly _s between them? I checked the base game recipes and they just have the whole recipe name in 1 word, so i guess it's separated somewhere else?
Another question, is it possible to have different icons for crafting the same item but with different texture choice? The recipe itself uses getTexture from a lua file to pick the correct texture choice, it works for the crafted item, but it doesn't affect the crafting recipes, is it possible to somehow affect that too?

bright fog
#

Every recipes should link to a translation file

#

didn't I rework that page a bit?

sly monolith
#

could you point me to the correct game files path so i could copy the file xd?

#

ooh ok found it on that wiki page thanks

bright fog
#

You probably don't want to do that lol, you're better off starting with a fresh file

sudden lichen
sly monolith
sudden lichen
#

Redirect in wiki are mostly for the users that search a different term

bright fog
sudden lichen
sly monolith
#

what about the other half of my question tho, any ideas? πŸ₯Ί

sudden lichen
#

oops, old link https://www.mediawiki.org/wiki/Help:Magic_words (search for DEFAULTSORT)

MediaWiki

Magic words are strings of text that MediaWiki associates with a return value or function, such as time, site details, or page names. This page explains only the standard magic words; for a technical reference, see Manual:Magic words .
There are three general types of magic words:

Behavior switches: these are usually written as uppercase words ...

bright fog
#

Like you have a "Custom Clothing Guide" and it could be found by searching "How to make custom clothings"

#

For example

#

And add many many other options I guess

#

Is what @frank elbow had as an idea I think if he can confirm

sudden lichen
#

I think I mentioned renaming the "How to" guides? But yeah, can set up redirects too

bright fog
#

But like I told him, currently the pz wiki doesn't do that

ebon dagger
#

TIL: There is a search on the wiki lol

bright fog
#

Or it doesn't use it that way

sudden lichen
#

πŸ˜„

bright fog
frank elbow
sudden lichen
bright fog
#

If you search "How to make custom clothing", it just won't find the page name I mentioned

#

Unless there's a specific redirect

ebon dagger
#

The UX doesn't mesh with my brain, more than likely a me issue lol

sudden lichen
# frank elbow This is essentially what I had in mind

These are fine, yeah. Though keep in mind that modding is pretty much the only area where any kind of guides are present (there used to be gameplay guides, but they basically had been removed as outdated; Steam serves a better place for them)

bright fog
coarse sinew
bright fog
sudden lichen
sly monolith
#

yea i went to sleep after i asked that last time heh

#

i have 3 texture choices in the item, red black and white

bright fog
sly monolith
#

when i craft the item using each recipe, it has the correct in-game texture, and the correct inventory icon, but in the crafting menu they all have the same 1st texture choice

bright fog
#

Hmm

#

So like you'd like something that cycles through the various textures ?

#

In a way ?

#

So visually it animates with the different available icon textures ?

sly monolith
#

i'm bad at explaining stuff lol, so i have those 3 inventory icons for ankle holsters, i have recipes that let you craft each of those, but in the recipe window, they all use the same red texture, because that's the 1st texture choice in the XML

oak hornet
#

Ok I'm getting dumber than a wet cake by the minute, is there a way to implement the CraftRecipe_OnCreate Callabacks here? I Keep encountering error using the normal Events.[EventsName].Add([Func])

bronze yoke
#

you can set the recipe's icon with (i think) Icon =

#

these callbacks aren't events, they're just the signatures for when adding a function to a recipe

#

e.g. in my craftrecipe OnCreate = myFunction, myFunction should be a lua function that expects these arguments

#

if you have umbrella then these names are the ones you can use as a type e.g.```lua
---@type CraftRecipe_OnCreate
function myFunction(recipeData, character)
...
end

bright fog
#

Or do you mean the craft result ?

winter bolt
#

they mean the icon that appears for the recipe in the menu

bright fog
#

Yea

sly monolith
#

the craft result is ok, i only mean the crafting window icon

bright fog
#

And that's what I've been saying lmao

#

Visually only

#

Not a question of result

#

Just have the crafting show there's different variants ?

#

So it could be like a cycle thing, animated gif showing every variant icons ?

sly monolith
#

no no no

sly monolith
#

i didnt think about even trying that heh, gonna see if it works

#

yea it does lol, that was simple xd

#

thank you very much !

winter bolt
#

i just tried looking in the code and i thought it wasnt possible

sly monolith
bronze yoke
#

yeah in b41 it was impossible

#

b41 always used the result item for the icon

sly monolith
#

oh really wow, nice, that's some QoL fixes haha πŸ˜„

ebon dagger
#

In case anyone ever uses the search to try and find the same info in this discord as I was working on yesterday.

Setting the "AmmoType" of a weapon and using setCondition(weapon:getCondition) to update the tool tip.

It works. But only once. Then, as Albion surmised, the tool tip is cached and cannot be set again until the game is loaded again.

I have chosen a third option. I am adding to the tooltip with an additional line noting the ammo type loaded by hooking into ISToolTipInv

sly monolith
#

one more question, where can i find the base game texture icons? are they bundled together in ProjectZomboid\media\texturepacks ?

ebon dagger
#

Also, if you swap the ammotype of a weapon to a custom ammo you have created, a gun must exist that fires that ammotype via script. Otherwise, Java has no idea how that ammo type is supposed to work.

winter bolt
sly monolith
winter bolt
#

i have all of the item icons ripped already if you want me to send them

sly monolith
#

great thank you !!

#

oh yea that would be even better

bronze yoke
#

you can also grab them off the wiki

sly monolith
#

oh true lol, that's even easier

oak hornet
sly monolith
#

thanks yall rock!

ebon dagger
winter bolt
#

wiki wont have the filenames though i think?

bronze yoke
sly monolith
#

don't really need the names anyways, cuz i gotta recolor them for my custom colors anyway heh

winter bolt
#

the other ones should all just be in media/textures

sly monolith
#

thanks!

slim swan
#

How to get the weapon hit sound into mod data or get the script sound

oak hornet
slim swan
#

Try lots of way but always buged

dull moss
#

Is it possible to have scripts interacting with lua? Like lets say I want to have a mod with multiple levelup sound options, to overwrite it it's easy, you just throw

module Base
{    
    sound GainExperienceLevel
    {
        category = Player,
        clip
        {
            file = media/sound/sound_1.wav,
        }
    }
}

in scripts. But is it possible to check something in game code and play different sound based on lua logic? I can't find relevant either playSoundLocal or GainExperienceLevel in lua files in pz

winter bolt
slim swan
#

I want to like press a key then change the weapon damage and sound,make it happen in lua but the sound

bronze yoke
#

literally speaking though it is a comment so doesn't affect in any way how the code actually executes

bright fog
# bronze yoke

What tells you how many times your function is referenced ?

dull moss
#

vscode, no?

bronze yoke
#

that isn't something i had to set up or anything yeah

#

apparently it's code lens

winter bolt
#

and then you can run whatever code you need to do and play your own sound scripts

sly monolith
# bright fog Translation files

one more question, so in that recipes LUA i gotta just start the file with: RecipesEN { drop my Recipe_blablabla,'s close with } and i'm good?

bright fog
#

Kind of yes

bronze yoke
#

these are my global lua settings, umbrella automatically changes some other things that aren't as subjective

sly monolith
#

like it's not going to overwrite anything in the base files if i have a different name for that file right

bright fog
#

It's forced

#

That's why prefix are listed on the wiki that way

#

Because you NEED to use the right file naming

#

(actually do we have to? @bronze yoke)

bronze yoke
#

yes

bright fog
#

Alright good to know

sly monolith
#

i dont really get what you mean here, can i have my translation file named "Recipes_Evil_EN" ?

bright fog
#

You're forced in using Recipe_EN

#

And that won't cause problems

sly monolith
#

but isn't that going to overwrite the base game file with all the recipes?

bright fog
#

It will cause problems if you don't name it that way

bronze yoke
#

translation files aren't loaded through the virtual filesystem so they won't override each other

#

if you name your file differently it won't load at all

bright fog
bronze yoke
#

yes

sly monolith
#

oh ok so i just name it the same and only type in my translation names and that'll work fine?

dull moss
#

I don't see a definition for LevelPerk event anywhere in game files

slim swan
winter bolt
dull moss
#

Yea except that is adding to event

#

not changing default behavior that happens when players levels up the skill which plays the sound

winter bolt
#

yeah its not possible to change it so you have to just stop the sound from playing and then replace it with your own

bronze yoke
#

what they mean is you can most likely just stop the already playing sound on that event

oak hornet
winter bolt
#

player:getEmitter():stopSoundByName("GainExperienceLevel")
might work but for some reason stopSoundLocal() doesnt let you use a string

bright fog
dull moss
bright fog
#

I never actually fucked with the settings of lua in vscode

bright fog
#

You can change the level up sound tho

dull moss
#

Yea I know it's possible

bronze yoke
#

you could also replace the sound script with one that doesn't actually have a clip so it doesn't play anything

#

and then just play whatever you want on the event

dull moss
#

Oh that might actually work

#

AHAHHAAH

winter bolt
#

ive even done that before and didnt even think of it πŸ’€

slim swan
#

But how to replace item’s script sound like hit sound name in lua

bright fog
#

DoParam

silent zealot
#

To clarify: DoParam is like editing the script file, if you want to change one specific instance of an item while playing you need to get the item as a variable and use whatever methods it has to change it.

#

Since I saw mention of press a key/change damage and sound in the chat.

vast pier
silent zealot
#

Wtf syntax is [[{}]]

#

Crazy lua

bronze yoke
#

[[ ]] is multiline string

vast pier
#

It's originally a script someone here helped me with to edit fluid values on items without overwriting the item.
I messed around with it and is now my go to for editing items that I don't wanna overwrite

#

It was albion actually

#

I think

silent zealot
#

So same as DoParam() but different syntax for changing multiple parameters at once?

vast pier
#

Edits existing parameters, and can also add in entirely new ones

vast pier
bronze yoke
#

DoParam("Key = Value") is far more common for editing/adding one parameter, but it wouldn't work for a fluid container since that's a component

vast pier
#

"Big Cunt Belle is typing"

#

πŸ’€

#

God mode was not used during this, I fr thought I was about to have to start the scenario over because of that trip. To demonstrate a use case for buffed pipe bombs

silent zealot
#

The old "throw super bomb in front of you and run past it trusting a cheap interior door to protect you" strategy πŸ˜‚

vast pier
#

I mean a pipe bomb is just a shrapnel bomb, a door would probably protect you decently

#

Based off how I threw it, it looks like it would have been the wall protecting me anyway

bright fog
#

I never use these

vast pier
#

Before, it would do like zero damage and set everything on fire πŸ’•

silent zealot
#

That actually does make pipe bombs useful

#

More like a grenade

vast pier
#

I mean yeah, the US military has an official munitions guide for making pipe bombs because they're effectively just frag grenades

silent zealot
#

Plus carrying them on your belt

vast pier
bright fog
#

That shrapnel bomb might interest us @tranquil kindle @past radish

silent zealot
vast pier
#

currently the issue is I don't feel like the bomb does enough damage to players, it just kinda scratches you up a bit

silent zealot
#

And "home defense frag grenades" sounds very Kentucky

silent zealot
vast pier
#

idk how to make it effect players more tho, as it doesn't have a separate damage value

vast pier
#

It's mainly targetting the engineer at the moment, because the bombs SUCK at doing anything other than causing a fire

#

I also want to make it so the bombs can be learned from a military magazine

bright fog
#

We're working on The Last of Us mods, and for nail bombs that'd be very useful

vast pier
#

I have the damage set high enough to just instakill zombies, but you could set it lower and just deal a lot of damage to em

#

Also I'm definitely getting put on a watch list due to how much I've been googling about IEDs

#

πŸ‘ πŸ‘

bright fog
#

lol

bright fog
#

I think we might interested in that in the future

inner seal
#

hey, does anyone know where do i found the sound files for weapons swing sound effects ?

vast pier
#

Maybe they're used to it though, they saw me googling a bunch about making guns at home and improvised firearms, and how matchlocks/flintlocks/wheellocks work

tranquil kindle
bright fog
#

Nice

bright fog
vast pier
#

well I posted it a bit ago, but this is what is changed about the pipe bomb to have the effect shown in the video

if item then
    item:Load(item:getName(), 
    [[{

        MaxRange = 10,
        ExplosionPower = 0,
        MaxDamage = 60,
        ExtraDamage = 150,
        AttachmentType = Hammer,
        
    }]])
end```
#

You could just copy the pipe bomb from items_traps and then change it as seen above

#

Setting explosion power to 0 makes it no longer catch stuff on fire, I'm not actually sure if max damage does anything itself for explosives.
And ExtraDamage is what gives it actual damage?

#

I'm not entirely sure myself, I just know it works

#

Like an ancient viking knowing that crushing chicken bones into their iron made it stronger.
But not actually knowing why

#

(The carbon from the chicken bones would smelt into the iron, creating rudimentary steel)

#

They thought it was the chicken's souls making the iron stronger

hollow rock
#

Hi I'm new to PZ modding

#

I am currently working on a mod that messes with zombie behavior

#

specifically their sight

#

would anyone know how to config zed characteristics through mod tools?

bright fog
hollow rock
#

Blind

#

Mainly

#

I've been trying to run a preset where zombies are superhuman yet blind as bats

bright fog
#

I'm planning on doing that with my clickers

hollow rock
#

But neither the base game nor the steam workshop supports this to my liking

hollow rock