#mod_development
1 messages · Page 351 of 1
Prime wheel spinning location
Regarding a proper Hello World example, if you mean simply setting up a mod this is what my first video guide is about:
https://youtu.be/MUGQ647o5M4?si=qXtP2JAaJjsHyvyN
If you mean a Lua mod or specifically a script mod, I will make a video about it in the future but I'm the start of video guides rn
If you mean specifically something inside the wiki for that, yea that could be done too, but that'll have to wait for me to find time for it to do it too
You have to consider that there will be more in the future but that there wasn't even a single generalized documentation like that until I came along and shaped up the modding wiki to what it is rn at the start of this year. Before like you REALLY had no choice in term of learning than ask others or check inside existing mods on how they work
This guide goes in detail on setting up a basic mod to work on for Project Zomboid.
WIP: this is currently my first ever video guide for PZ modding and serves mostly as a concept currently. It's likely I'll rework this video in the future.
Relevant Wiki pages:
https://pzwiki.net/wiki/Mod_structure
https://pzwiki.net/wiki/Mod.info
https://pzwik...
More will come but it's normal that the documentation is imperfect rn
Especially as I'm basically the only one writing Wiki pages rn
I mean, rather than digging up a weapon, a simpler example could be used, just to get something/anything showing up in the mods...
This isn't as simple as "Hello World" (sorry, I'm busy writing mods now! 😆 ), but point being, rather than digging around in files and pulling up long weapon definitions. IDK.
module JimsUpholstery
{
craftRecipe RagsToThread (SpinningWheel)
{
timedAction = Sew,
Time = 3,
Tags = SpinningWheel;
category = Tailoring,
xpAward = Tailoring:5,
inputs
{
item 1 [Base.RippedSheets],
}
outputs
{
item 10 Base.Thread,
}
}
}
Definitely
For recipes see there's a wiki page that documents what everything does and if I remember correctly I've put some examples there too
https://pzwiki.net/wiki/CraftRecipe
It's not lost on me that you're the only one working on the wiki and videos ... and thank you for doing it. Sorry if I started off on the wrong (grumpy) foot.
Yea 😅
My problem with your early remarks was that it sounded a lot like "this is bad" without any explanation of what/why it's bad, which really doesn't help anyone here to improve things
Np happens to me too sometimes, thankfully I was in a good mood 😅
It's important to bring up what is wrong, and to not hesitate to say what works and what doesn't
You had mentioned that Mod structure is long to read and has a lot of information, but the page really is the most optimized that it has ever been, it went through different reshapes to improve things, to give information in a very concise way without removing any information
Tho of course it's not perfect
And in reality the page is really short compared to a lot of other pages out there imo
I think a lot of that was probably me thrashing around cuz I was in the wrong Zomboid directory... going WTF??? I've got this the way they said????
Something I was thinking about is making a sort of difficulty indicator to reading pages, so like "this page is: red (hard), orange (medium), easy (noob level)"
This could ease new modders going in and realizing they can't understand jackshit
Yeaaa sadly this is a common mistake, but see, this is an indicator to me that this is probably something that needs to be clearer in the relevant pages
Usually this ends up as notes
The moment I searched for the example mod and it didn't show up, it was a lightbulb ... "Oh... something's changed in the structure of things".
Yeaaaaa
Video guides will tend to age badly, especially in B42 unstable where there's a lot of different changes that can happen to some systems
Once I had my "Hello World" mod up, then it was happy times... cuz I wasn't trying to fix something, but rather "try something and see if it breaks".
Even worse, there's constantly new information being discovered about some stuff, from me or from the modding community
Yeah, you're dealing with a changing environment... very hard to keep "up to date"
And I have to make pages about new stuff, pages to document various stuff that aren't documented yet
Like for example, if you look up entity scripts in the script files of the game, you'll see this is a massive rabbithole
Yeah, cuz this is your full time job... right? Right?
I'm trying to map it to properly document it but it's actual fucking hell
Worst thing is that I'm slowly having less and less time to do all of this, the deeper I go in my thesis the less time I have to give to my passions like modding. Like the past month has been rouuuugh lol, I felt September was already really light in terms of modding wiki, but this one is going to have barely anything in it I feel like (tho I say that every month and realize I actually did a lot)
I make summaries every end of the month for the wiki about the modding wiki section, so that next one should be light
And then you get some random asshole coming in and complaining about it all [looks around avoidantly]
people do still stumble on mod structure a lot (but it's far less bad than before sim's work on the wiki), do you think a 'mod structure checklist' could help? it'd be an easy thing to point to for any issues and the full detailed explanations can be elsewhere
Wdym by a checklist ?
"common folder is undercase"
"Mod.info is in both places for b41 and b42"
etc
the full explanation is good, but a lot of people just assume they already know everything and don't read it and then complain to us when they're wrong
Pointing out a few of the common windows/linux case sensativity pitfalls would be nice too (Iv still randomly struggled with those)
I did think about this, like I experimented with a page about "common mod problems", but I realized the page would be so fucking massive that it would be unreadable
But listing it in the pages of the unique subjects could maybe help yea
I want to do something like that but I literally don't even know why ones are case sensitive
Like I know one or two that's it
Maybe a checklist could work
I need freaking post-it on my desk, I have too many ideas here and there I feel like I'm going to forget half of those lol
Obsidian.md and Trello are two tools that have been very helpful for me to not have all the ideas just bouncing around in my head
expect nearly everything to be case sensitive, the major exception is things that are checksummed (lua and scripts), that was fixed because otherwise it was basically impossible to play modded multiplayer on linux
One thing I'm bad at, which is why a getting started page is really hard for me to properly make, is list every common things to do
Mod is in the cache directory (NOT the game directory)
[link to what the "cache directory" is]
I do have Obsidian and while I think it's a great tool, I think it's not good, for me personally, to note things to do later
I had started to do that, as a replacement to me sending my to-do list inside the modding Discord wiki channel back then, to have a better tracking of things to do, but I haven't gone back to it in ages
One thing I do for my thesis however is use post-it, and that works really well for me, where I have post-it of ideas and things to do and I cross them when I'm done
Tbh it's kind of in the first sentence of mod structure page 
honestly it would be good to leave some guidance somewhere to say treat EVERYTHING as case sensitive, because if it isn't, it doesn't matter either way, but if it is, it obviously causes major issues
I added Trello bc Obsidian isn't the best for to-dos for me either lol—glad post-its work for you
Trello is the same problem btw
Proof with the horse project lmao
We haven't updated that shit in ages I think no ? @bronze yoke
Interesting, I find that easier to check personally
Our new task tracking is now Github issues 
Yeah, Trello fan too... but any way that skins the cat... post its get it done just as well for small independent things.
Post it does it better to me bcs writing it takes more effort on my side I'd say, since I don't write that often compared to typing on a computer that I do almost constantly everyday
That makes sense
I used to swear by physical writing and never do any digital notes
But I've given up my unc status for syncing
I even have a tiny note book for my thesis that I try to carry around to write things in too, tho it's usually more temporary notes I'd say
Access from anywhere can be concern for sure, in my use case that's fine bcs my thesis I never change desk, and modding is almost entirely done at my home desk
What are you studying, if you don't mind my asking & care to share?
Water waves damping with flexible structures
i don't think trello was the issue with the horse mod's organisation, i think we were just quite poor at using it consistently
Yea
I know just about nothing about that, but sounds interesting
personally i'm more at home with github issues anyway, they make more sense for most code-related tracking which was all i needed to worry about
Fluid dynamics, fluid structure interactions overall
I see, makes sense
I like GitHub issues for tracking in larger/ongoing projects but I'm simply too lazy to write a well-formatted issue most of the time 😅
My issues are proofread, my notes-to-self are “implement Thing in This Way no punctuation stream of thought you'll know what you meant by this later”
for me, sometimes an entire issue is just the title and that's okay
I could never (even if the title alone is absolutely sufficient)
https://steamcommunity.com/sharedfiles/filedetails/?id=3596317718 some new professions and traits pd: need updates like some more traits and translations
do i want Base.Vest_Hunting_Khaki (item name) or Vest_Hunting_Khaki (clothing name) when giving an item to the player. ive tested
Base.TentGreen,Base.WalkieTalkie3,Base.Bag_HydrationBackpack_Camo, and these work. but not sure what path for the vest.
also Base.TentGreen is wrong as it gives an unpacked tent that takes up a ton of space. not a packed tent.
you want the item name
would that be Base.Vest_Hunting_Khaki?
yeah
i def need to mess with it more. i dont like how im using player:getInventory():AddItem("Base.Hatchet")
and such
can i use setCondition() after giving the item to the player to instantly set it to the value i want?
😁
I already have a Portable Sewing Machine that can sew sheets from rags, but only when placed on a surface. It acts as a container, but not for liquids and thread for it can be spun at the spinning wheel. And I've got it up on the Workshop so that my crew can use it on our dedicated server in B42.
Still need to work on some sounds and 3d models, but we're away laughing already.
I'm over the moon here.
Thanks again for putting up with my shit and getting me started.
😁
you can
eg item:setCondition(2)
nice!
Just remember its outta <maxCondition> and not 100 or anything.
would GiveItem("Base.Hatchet", 0.50) work?
I don't see any 'giveItem' global function used in PZ, so no?
mmm so i have to use player:getInventory():AddItem("Base.Hatchet")
then call
setCondition() after
giveitem != additem
declaration: package: zombie.inventory, class: ItemContainer
See the API.
See what variables the API takes.
I made a mod that adds items to the players inventory upon spawning in the world.
If you need to see the code
Do note there is like 10 different addItem(s)/AddItem(s) (yes some are capitilized because reasons)
That script puts a bunch of clothing inside of a suitcase and puts the suitcase in the players hand
Moved this section over to this:
https://pzwiki.net/wiki/Spiffo's_Workshop#Installation_folder
And improved the explanations a bit
@willow tulip yo around. put your test version of relistic car physics in
C:\Program Files (x86)\Steam\steamapps\common\ProjectZomboid\mods
nothing.
put it in
C:\Users\Emily\Zomboid\mods nothing. did i miss something?
seems fine.
thanks. that did it
But yea, test the towing, and offroading
and running over zombies... the vehicle mass is now dynamically scaled so ragdolls should work 'good enough'
New super smooth towing based on rolling friction/aerodynamic drag, with slight 'autosteer' of the towed vehicle
Oh, and offroad efficency now affects offroad rolling friction (and traction)
so how is it?
i give up
really bad understeer for some reason.
thats weird, didn't change steering except for towed vehicles, do you have a trailer?
(shouldn't have affected trailers, but dunno)
is your power steering pump bad/fanbelt?
steering is fine in reverse. only forwards is weird. if anything the car has slight oversteer in reverse. steering is borked with and without trailer.
that looks pretty much how the game normally has bad understeer?
weird, it feels weaker
I dunno how you'd accelerating offroad like that with the latest version though..
I think you copied the wrong zombie folder over or something
ooooohhhhh i still have vehicle tuner lol
its because i use this grid square lol
wut?
when i did my map lol. i used an existing but empty location.
Anyway, just alter offroad rolling friction/plant impulse instead -_-;
and offroad traction if desired..
but try default values first
yeah that feels really good
and yea there is zombie impact impulses now too (adjustable in sandbox)
Can't wait for some car modders to put out some heavy duty trucks for it
like the W900 semi truck, but with 4000kg weight and 1000hp+ or something.
local function giveHatchetOnCreate(playerIndex, playerObj)
local player = playerObj or getSpecificPlayer(playerIndex) or getPlayer()
if not player then return end
local inv = player:getInventory()
if not inv then return end
local item = inv:AddItem("Base.HandAxe")
if not item then return end
if item.setHeadCondition and item.setHandleCondition then
local headMax = item.getHeadConditionMax and item:getHeadConditionMax() or 10
local handleMax = item.getHandleConditionMax and item:getHandleConditionMax() or 10
item:setHeadCondition(math.floor(headMax * 0.80))
item:setHandleCondition(math.floor(handleMax * 0.35))
if item.getHeadCondition and item.getHandleCondition then
local usable = math.min(item:getHeadCondition(), item:getHandleCondition())
if item.setCondition then item:setCondition(usable) end
end
else
if item.getConditionMax and item.setCondition then
item:setCondition(math.floor(item:getConditionMax() * 0.50))
end
end
end
Events.OnCreatePlayer.Add(giveHatchetOnCreate)
hand axe fired item was given.
handle condition worked great.
head did not.
um, stop letting AI write your code?
A: hooking wrong event, going to test every crafted item ever, if a lot of mods did this it would be horrible, override the recipes onCreate callback instead
B: Telltale signs of AI is checking for functions existing before they exist. if vital functions don't exist... Well, you have REALLY horrible problems, and checking if they don't exist is masking hallucinations the AI is having.
https://demiurgequantified.github.io/ProjectZomboidJavaDocs/zombie/inventory/InventoryItem.html <- check your inventoryItem API's and try again.
declaration: package: zombie.inventory, class: InventoryItem
You would be honestly better off erroring due to functions not existing, because at least then you'd know they didn't exist.
ai writes code that detects errors in advance and gives up before trying to do anything so that you don't get an error instead of writing code that actually works
instead of just.. some code silently not executing, or being randomly set to the value of '10' instead of the value you expected.
it literally tries to 'fix errors' instead of any flawed logic
its like some intern that's been yelled at so many times about error reports they finally 'fixed the errors' but still didn't learn to actually program.
protip: you can fix every bug in your entire codebase by starting every line with --
--[[ fixes more bugs with less code! I win! /s
Even the first 2 lines are amazing dubious
local function giveHatchetOnCreate(playerIndex, playerObj)
local player = playerObj or getSpecificPlayer(playerIndex) or getPlayer()
if not player then return end
So its got a function.. that takes both the index AND player obj?
is that how that callback works?
Interestingly, it is how that callback works
however... Neat description on that event
ive tried using getHeadCondition() / setHeadCondition
using my own code with https://demiurgequantified.github.io/ProjectZomboidJavaDocs/zombie/inventory/InventoryItem.html#getHeadCondition() as the referance.
but its not valid.
local HandAxe = player:getInventory():AddItem("Base.HandAxe")
if HandAxe then
HandAxe:setHeadCondition(3)
HandAxe:setHandleCondition(8)
end
end)```
declaration: package: zombie.inventory, class: InventoryItem
it should be valid
ok but hold up
how so?
Oh, your adding things to a new player?
I thought you where overriding a crafting recipe for some reason
attempting to add an item with custom handle/head condition yes
Still, the first line:
local player = playerObj or getSpecificPlayer(playerIndex) or getPlayer()
... why not just.. playerObj?
surely thats valid, or would defeat the entire point of the function
i mean with mine
local HandAxe = player:getInventory():AddItem("Base.HandAxe")
if HandAxe then
HandAxe:setHeadCondition(3)
HandAxe:setHandleCondition(8)
end
end)
i used
yes, you can't create a player that doesn't exist
i see these kinds of nil checks even in human written code 😅
condition isnt set https://demiurgequantified.github.io/ProjectZomboidJavaDocs/zombie/inventory/InventoryItem.html#getHeadCondition()
declaration: package: zombie.inventory, class: InventoryItem
wait two ints?
No
what is the error
in your console.txt
the stack trace
because, you have one
it has a single int parameter called int0
See your calling functions that don't exist
and if you look at console.txt it will tell you that.
Object tried to call nil in HandWeapon
Yes, on what line?
11723
HandAxe:setHeadCondition(3)
ERROR: General f:0, t:1761869810232> ExceptionLogger.logException> Exception thrown
java.lang.RuntimeException: Object tried to call nil in Add at KahluaUtil.fail(KahluaUtil.java:97).
Stack trace:
se.krka.kahlua.vm.KahluaUtil.fail(KahluaUtil.java:97)
se.krka.kahlua.vm.KahluaThread.luaMainloop(KahluaThread.java:769)
se.krka.kahlua.vm.KahluaThread.call(KahluaThread.java:166)
se.krka.kahlua.vm.KahluaThread.pcall(KahluaThread.java:1754)
se.krka.kahlua.vm.KahluaThread.pcallvoid(KahluaThread.java:1582)
se.krka.kahlua.integration.LuaCaller.pcallvoid(LuaCaller.java:60)
se.krka.kahlua.integration.LuaCaller.protectedCallVoid(LuaCaller.java:131)
zombie.Lua.Event.trigger(Event.java:62)
zombie.Lua.LuaEventManager.triggerEvent(LuaEventManager.java:317)
zombie.gameStates.GameLoadingState.exit(GameLoadingState.java:430)
zombie.gameStates.GameStateMachine.update(GameStateMachine.java:70)
zombie.GameWindow.logic(GameWindow.java:346)
zombie.GameWindow.frameStep(GameWindow.java:790)
zombie.GameWindow.mainThreadStep(GameWindow.java:552)
zombie.MainThread.mainLoop(MainThread.java:68)
java.base/java.lang.Thread.run(Unknown Source)
LOG : General f:0, t:1761869810232> -----------------------------------------```
```function: Add -- file: Oncreateplayer.LUA line # 6 | MOD: hatchettestb42
ERROR: General f:0, t:1761869810232> ExceptionLogger.logException> Exception thrown
java.lang.RuntimeException: Object tried to call nil in Add at KahluaUtil.fail(KahluaUtil.java:97).
Stack trace:
se.krka.kahlua.vm.KahluaUtil.fail(KahluaUtil.java:97)
se.krka.kahlua.vm.KahluaThread.luaMainloop(KahluaThread.java:769)
se.krka.kahlua.vm.KahluaThread.call(KahluaThread.java:166)
se.krka.kahlua.vm.KahluaThread.pcall(KahluaThread.java:1754)
se.krka.kahlua.vm.KahluaThread.pcallvoid(KahluaThread.java:1582)
se.krka.kahlua.integration.LuaCaller.pcallvoid(LuaCaller.java:60)
se.krka.kahlua.integration.LuaCaller.protectedCallVoid(LuaCaller.java:131)
zombie.Lua.Event.trigger(Event.java:62)
zombie.Lua.LuaEventManager.triggerEvent(LuaEventManager.java:317)
zombie.gameStates.GameLoadingState.exit(GameLoadingState.java:430)
zombie.gameStates.GameStateMachine.update(GameStateMachine.java:70)
zombie.GameWindow.logic(GameWindow.java:346)
zombie.GameWindow.frameStep(GameWindow.java:790)
zombie.GameWindow.mainThreadStep(GameWindow.java:552)
zombie.MainThread.mainLoop(MainThread.java:68)
java.base/java.lang.Thread.run(Unknown Source)
LOG : General f:0, t:1761869810232> -----------------------------------------```
both lines are wrong?
Base.HandAxe the item name is fine https://pzwiki.net/wiki/Hatchet
Have you guys ever experienced steam successfully updating your item, doing the whole review process thing and hiding the mod for a minute, but then just... not updating the mod page at all?
what for review? yeah. ive had one sitting for review for nearly 9 months now on the stationeers workshop.
Ok weird, im pretty sure it should only error on the 2nd line, on account of setHandleCondition not being a real function but an AI hallunication]
The review ended, the page isn't updating.
You also can't have it error on a line and then error again o nthe very next line, so now your looking at errors from multiple versions of the same script?
so your likely looking at the wrong line and/or error entirely
save your script file, restart zomboid, cause the error, look at zomboid log for the exact line
it will point out that I have wasted the past 5 minutes trying to explain to you why using AI code is bad because it hallucinate functions and then you wonder why they don't exist.
was trying to explain it in a way that would let you figure this out again in the future but...
now go check every function call the AI gave you against the actual API docs and stop using functions that don't exist.
in most cases umbrella will also just tell you if a function you try to call doesn't exist
that'd be the real big brain move too

not trying to ignore you, just haven't ever seen that before no
Is there a thing where steam will block your updates (or review them longer) if you put out too many updates too quickly?
That's the only thing I can imagine, I'm shadow banned or some shit
how many updates did you realise in what time period?
i wouldn't be shocked if there was something like that but i feel like it'd have to be really excessive
I mean iv done like 10+ updates of my description in an hour that each trigger that 'review' (for like 30~60 seconds)
Well, it was 3, but technically one was a revert for the other and the next was to fix that. The fourth is the one not going through and this was spread out from 12am to 8pm now (US EST)
My bugzapper mod description is now an excercise in 'how many forum links can I have in one mod description before steam worries?'
oh no way, that's not spam at all
thats more likely steam shitting itself then steam caring about you lol
when i was a baby modder i updated a particularly broken mod several times in like thirty minutes and it was fine
lol yea, always sucks when you find those bugs 5 minutes after hitting commit
It’s not brother
My face when people are black screening because I put 2 lines out of order
i learned quickly:
- test those changes before uploading
- test the LATEST version of the changes
- test the style changes
"I only made the tinyest of changes! I don't need to test if they work!" - famious last words
no matter how simple the change is, if it's 'one last thing before i upload', you somehow fucked it up for sure
yeep
is this happening with More Car Features? it says it last updated about two hours ago for me
I literally tested every other update, it was just late and I said fuck it lol
Not only will you have fucked it up but you'll have somehow bricked the entire game in the process lol.
EXACTLY
It's supposed to say like, not that long ago. Not the 2 hour ago one
its never 'oh no, I screwed this up and this thing is 10% off'
The worst part about my situation is I think steam is so desynced that people have different versions of my mod rn lol
nah, its 'oh no, I screwed this thing up, and now this healing spell is instant kill and then erases your savegame'
that'll happen if you ever rename a file, btw.
this just happens even if you do everything right
steam just sometimes doesn't feel like updating them
yea lol
validate files in steam, randomly re-downloads like 5 files from various mods, wtf?
That's why I sent out the 4th update that never actually got sent apparently
I stopped after the 5th where I just put "STEAM PLEASE UPDATE THIS" in the patch notes lol
I'll look again tmrw
that's why i always clearly mark mod version in-game, have some in-game pop warning about mismatched library versions, and when i fix a major bug i leave a comment telling people not to report it unless the mod has actually updated -- because otherwise people will have the wrong version inexplicably and report a bunch of stuff that isn't actually relevant anymore
mmmm
local HandAxe = player:getInventory():AddItem("Base.HandAxe")
if HandAxe then
HandAxe:setHeadCondition(5)
HandAxe:setSharpness(5)
end
end)```
is error free. but does nothing.
the same with just HandAxe:setHeadCondition
yet ```void
setHeadCondition(int int0)```
maybe
```void
setHeadConditionFromCondition(InventoryItem item0)``` is a better option.
Pretty sure setHeadCondition works just fine.. for setting the head condition
Ya lol
did you mean: setCondition, for the handle/main condition?
not sure.
also not sure what i did to get that encumberance lol.
sticks weigh more ?
Hmmm that is weird.
Is this on server or client?
client
Weird, should be working AFAIK
You could maybe try SpawnItem instead of AddItem? Dunno.
Something not quite right that it has 0 sharpness/head condition
does it have 0 if you don't try to set them?
I wonder if the player is created before itemScripts are fully loaded? that'd cause some.. real fun issues?
Hu.
local HandAxe = player:getInventory():AddItem("Base.HandAxe")
if HandAxe then
HandAxe:setSharpness(5)
HandAxe:setHeadCondition(5)
end```
Not sure if that was a problem, in my brain it made sense
is your still an onCreatePlayer event?
Yes
Are you testing with other mods loaded?
shouldnt be. https://pzwiki.net/wiki/OnCreatePlayer its the way to do items.
I do also check for the player at the start of the function but besides that and the other stuff I add for my mod, everything else should be the same
Sorry didn't mean to ping
your fine.
local function ReeferMadness_OnCreatePlayer(playerNum, player)
if not player then return end
local modData = player:getModData()
if player:HasTrait("Stoner") and not modData.ReeferMadness_StonerSpawnItemsGiven then
local HandAxe = player:getInventory():AddItem("Base.HandAxe")
if HandAxe then
HandAxe:setSharpness(5)
HandAxe:setHeadCondition(5)
end
modData.ReeferMadness_StonerSpawnItemsGiven = true
end
end
Events.OnCreatePlayer.Add(ReeferMadness_OnCreatePlayer)```
That is the whole function with the extra items I add for my mod removed, in case the other stuff would make a difference somehow
the fact even the mass is wrong makes me believe something has screwed up your handAxe item. try it with Katana or something?
(and make sure no other mods are loaded?)
like if the max sharpness/head condition was also 0...
it would always set to 0
that works
Weird
Weird.... also still the weight
indeed
Yeah I was gonna say, why tf is it so light
idk im gonna verifiy the game and reinstall moons mod after.
pretty sure i messed up something i shouldnt have when i was digging through the files last night.
always a good idea
im 99.99% sure my mods have nothing to do with it, but doesn't hurt to do your tests before reinstalling java mods
oh im sure they dont. but i was digging around in the game files when i was messing with generators. was trying to find a better way to pull fuel use. turns out the game literally has a L/H caulation you can just call. and convert to days/hours in b42/
ah lol
42.12 added a litres per hour value
actually found that out from https://steamcommunity.com/sharedfiles/filedetails/?id=3576056135
nice
there we go
dont even remember what i changed in the game files to do that lol.
lol
what we need: customizable melee weapons.
Screw addons for guns, I want lead weights for my crowbar.
and spikes.
Unironically this but melee:
#cs2 #counterstrike #play #gaming #popular #viral #short #shorts #trending. #reels. #viralshorts. #shortsvideo. #subscribe. #Youtubeshorts. #dailyshorst
and mini crowbars.
then again 1 handed crowbar would be pretty op
Crowbar fan attachment: -10% less endurance used to swing as it propells the crowbar (and cools you off with a nice breeze)
Oh yea, try towing a vehicle @livid haven with my mod :0
I think iv made it both realistic and terrifying (as towing another uncontrolled car with a rope should be)
I really need to have someone upload a youtube video of my realistic car physics vs normal or something..

Nice
Incidentally, the new high rolling friction means some low HP vehicles (especially those with tons of weight) might end up stuck offroad, or vehicles with very poor tires
but somehow I feels thats fine too
(as opposed to vanilla, EVERYONE gets stuff offroad)
feel free to adjust plant impulse down too if your gonna do much offroading (its the slowdown thing when you run over trees and stuff)
Also made it so the towed vehicle now slightly turns towards you so it will follow directly behind if you drive in a reasonably straight line
Iv also removed the stupid bull where towed vehicles are magically super light (yet have a ton of drag)
That's easy to make in B42, now that you can tag the item as "crowbar, pliers, hammer" instead of everything being hardcoded to specific items only.
I don;t think there would be any way to adjust those tags based on attachmnets though, since (from memory) the tags just falls back to the item script rather than being saved with each item, and you can't override the various getTag functionsthat used by other java functions.
Ehhh, Iv been doing some really shitty theorizing on such subjects
in that, as long as we are stuck in SP, we can actually do completely horrible things like changing the fabric of reality (item script definitions) to meet the needs of what the player is currently doing
ie: there is technically nothing wrong with adding a 'crowbar' definition to a 'gun with crowbar bayonet' or whatever your plan is so long as the player has one of said guns
though the other flip side of that, is recipes that depend on tags are cached on game load
so while changing the item script will satisify things using hasTag, it won't for recipes.
Yeah, that caching is a problem and I'm not sure there is any way to rebuild it.
The new recipe system has a lot of promise but is very lacking when it comes to mod interactions
yea if they could just move the cache till after initglobalmoddata
How can I add my tile to my custom entity? How can I set default flags for my tile, for example, making it a door or setting hasDurability = false?
I believe flags need to be defined in tilezed no ?
It's likely I'l mistaken
I would ask in the mapping Discord linked in the pinned messages of #mapping
Yeah, I saw it, thanks — but could you tell me how to add the tile to the entity? Do I need to add it to the vanilla tiles.pack or create my own .pack file?
i would review how https://steamcommunity.com/sharedfiles/filedetails/?id=2879745353 and https://steamcommunity.com/sharedfiles/filedetails/?id=3346506593 package and publish tiles for others to use in there maps.
thanks, i'll try it
@bronze yokehow do i correctly give a packaged tent? Base.TentBlue gives the unpacked tent. and ive had some real trouble working out how the game handles items with different states.
TentBlue_Packed
god i feel stupid lol. i was sure it was an item state or something.
Are you running in debug mode? The "items list viewer" (item spawner) shows the types of all the items, their display names, a lot of useful info
no i still get a hard crash when i try and start in debug mode. ive been using an item spawning menu to get items an find types.
eg
that and the wiki.
i just mentioned this in that channel.
Does that happen with no mods enabled? I think that can happen with outdated mods
Base.TentBlue_Packed
nope.
So you can launch in debug with no mods?
yeah im planning on making a second copy of the game. so i can run one with nothing but the base game. soi i can use debug. and have my modded testing version at the same time
Ah yeah, I don't actually play the game anymore so I only ever have the mods I'm working on installed/enabled lol
that worked great.
Yes you need a pack file
Yes, I added a .pack file, but as far as I understand, it also needs .tiles and .tiles.txt files to work, right? If so, could you please tell me how to create them correctly?
@bronze yoke Just wanted to let you know that I think that reverting an update using steam's button breaks updates. I had to revert it a second time and THEN update it for it to work again.
i seeee, i've never used that
but i'm glad it sounds like you've got it sorted out now
Also as a side note, during that entire time, my mod was not on the workshop page, even though people with the link or the mod already installed could still visit it.
Such a weird situation
Never using that button again
has anyone used this before?
isPlayerAllowedOnSquare(IsoPlayer player, IsoGridSquare sq)
I'm trying to add some sort of fix to harvest action where if it's a safehouse player does not belong to, then the action is blocked
@placid tulip https://theindiestone.com/forums/index.php?/topic/87949-42123-rev31595-mod-minimum-version-shows-wrong-error-message/ well that would explain why I get reports from B41 users to 'update my mod' -_-;
huh?
Never tested, but I suspect it shows similar in B41 if your mods min version is set to B42?
Before I just had my mod set to requires=\Build42
but someone was like 'omg you can't do that, use minversion instead!'
Now im wondering if that bug has existed since B41 and its actually clearer to do 'require=\Build42'
that's not the right albion
... Doh!
@placid tulip Sorry. misping.
No I added a B41 mod.info that has a minrequired version of B42
just because I got tired of B41 users going 'I subscribed to your mod but can't find it, help its broken'
(generally with no mention of what version they are on)
If anyone has B41 installed, id love to see what it says for this mod https://steamcommunity.com/sharedfiles/filedetails/?id=3564950449&tscn=1761926530 in the zomboidversion part
that message was added in b42
it probably doesn't show anything interesting in b41 but idk
meh i'll go check myself...
Nope, People are just... really.. thicc.
Im not sure how I could make this any clearer except maybe coding in some kind of jumpscare sound effect when they click it that screams it at them?
i havent had comments or anything about it yet, but seeing people add my mod into collections labled "b41" makes me so upset
Have you considered changing the title on the workshop to “[B42] Project [B42] Summer [B42] Car [B42] for B42”?

Might be a good idea. Can I make steam mod descriptions like flash the [B42] text too?
Maybe throw a couple hundred [h1]B42 ONLY. THIS IS ONLY FOR B42.[/h1] in there
Boy got that zomboid 2 action
hi guys. Do you have a doc for link vscode & pz functions ?
package index
I would like VS Code to recognize the game's functions
Magiq ! TY VM
Hi all, does anyone know how to create a proper explosion? Like the type that makes ragdoll zombies go flying. I thought IsoFireManager.explode() might but it just creates a square of fire.
Would I have to spawn a pipe bomb or something
pipe bomb definately causes a nice blast, dunno if you can do the same via lua
I meant maybe see what the code behind it exploding is
I think I hate curbs
how u make mods
Depends on what kind
Putting in the extra time to do road stuff properly is always so amazing to me though!!! Genuinely love road detail
out of curiosity, noone has made a mod to put in a clothing/hoodie add on for the pz makeship hoodie yet right?
i didn't see anything specific in the workshop for it, so i figured it either hasn't been made yet or it's in a clothing pack somewhere
anyone know why my windows look like this (in reference to that strange top bit)
Access the container, access its current distri table. I think you should be able to do something like that
@willow tulip
Regarding #1318920979581501502
Im not seeing a function to get a containers distro table?
np
There's an event that triggers when a container gets filled
Sure, but that means your now checking every container everywhere, instead of just that one time your item gets spawned
I'd be surprised if the distri table isn't stored somewhere. Unless the loot respawn doesn't always spawn the same distri table
Ok but I don't need to do it right now
Sure but it's not like that's less efficient than checking every single item spawning 😅
im just saying, passing that to onCreate or whatever would be magical
onCreate already exists, it just doesn't get any cool parameters about why the item was created.
Yea then turn your suggestion around that I think. Also that thread is useless, I've barely seen anything there being added in
Gn
It's the best we've got (for things other than bug reports), even if it truly is a void 😅 personally I'm holding on to hope that addressing stuff there is just not a priority compared to regular features and fixes, which would be reasonable
Can someone tell me what I'm doing wrong here: ```local function hasLastLaughTrait()
local player = getPlayer()
if not player then
return
end
local modData = player:getModData()
modData.hasLastLaugh = player:HasTrait("LastLaugh")
end
Events.OnPostMapLoad.Add(hasLastLaughTrait)
The goal is simply to register if the player, upon creation has the trait LastLaugh. That way, I can call upon it in a secondary function that triggers an explosion OnPlayerDeath (since onplayerdeath seems to not be able to check traits)
but the problem is modData.hasLastLaugh always returns false
It returns false or nil ?
Maybe use a different event
Also did you make sure that your code actually reaches the point of checking the traits ?
Add a print in this code to test things out
I tried OnCreatePlayer too. And many others that load after the player has been created and the prints show it has checked traits but then always registers that the player doesnt have the trait
nil when I use OnCreatePlayer or other events that seem to fire too soon. False for OnPostMapLoad
Make sure your code actually runs
ok, stupid me. I figured it out
In the code I was using, hasTrait wasnt capitalized 
I went with OnGameStart event and now everythign works
Hey guys! Is the anyone who comissioned some vehicles from ki5?
Does anyone know if you can control a bot on a server without actually loading the game? So, just the server would be running and the bot could interact with the game
Yeah in theory, have to code some rcon commands into the bot and add functionality user side, potentially have to hardcode the rcon password in the bot and use the both authentication so only authenticated people or with certain role could do but yeah doable i think
what do all you think of my hot lap mod?
records players lap times around the races tracks in knoxx, well functioning Redstone Raceway currently
need to work on the ui icon
thanks, but I was more curious if the server would actually function if the only "player" is a bot that is being hosted on the same machine. I wanted to mod the server so I could control a character through a python script and train ai agents on the game, without actually rendering graphics. would you happen to know?
Hi dudes. Does anyone know how to properly upload soundtracks to the ".bank" format so that they work properly and replace the vanilla music?
If anyone knows, please write to me. I would be happy to hear any ideas from those who have already done similar work)
I haven't seen any proper detailed explanation on how to do it, all I know is you need to unpack, replace musics then repack
You have no choice but to create a client somehow, if you don't have an interface it's most likely not going to work at all
A majority of actions require UI interactions
So you'd have to somehow manage to make the game work without a UI and add some interface to replace all the UI interactions with proper Lua scripts
There's a project of people that worked an AI agent
Is this game mostly made using 3D modeling?
I asked if the house was built using a 2.5D sprite sheet because I noticed it was partially obscured.
damn, this isn't quite what I was looking for. I wanted to train an rl agent using PZ as the environment, but I need it to run headless and in parallel. I don't imagine I could mod the game to run headlessly either. thanks anyways though, saved me a bunch of time
the problem is that when packing to the bank, you need to create additional folders in the program for further use in the code. but what are the names of these folders... we can only guess
Check the sound scripts
I've already read the scripts for music and sounds))) they can't be searched by file to find
Maybe a bank file viewer then ?
I have already used the fmod extractor to look at the packaging code. He skips sorting through folders and unpacks all the soundtracks completely. the txt file with the supporting information seems to dissolve into it... (all scripts and renames should be written in it). In the same way, for the sake of the test, I unpacked the folder of original music and packed it back in the form it was given. as a result, she did not earn. The bank file is a source of both problems and solutions)
But did you straight up extract or used an app to view the content ?
Bcs that app in the comment link I shared allows you to view the content without extracting
I extracted it immediately because I didn't have a viewer program
The idea is certainly interesting, thank you)
Yea check what I sent, maybe that could do it ?
Is anyone ever mentioned or contemplated a mod to introduce basic automation? There is real life and the lore justification for basic Ethernet or phone line. You could essentially create a system similar to Redstone or it can be more complex since technically in phone wire there's four wires in an basic ethernet there's eight you could do basic message passing or you could utilize the various channels (cables) to essentially maintain state or use it for sending timers or ticks or things. For the automation part I think that it would be relatively straightforward to essentially create things like buttons, pressure plates, switches, etc that are programmable to set a specific wire or to send a pulse or things like that. The ideas are on my head and in the basic programming is in my head but I don't have the time because I have kids, and a job, And I always get stopped at the very beginning where I'm trying to scope it out and I weigh overscope things.
Definitely doable
@bronze yoke might be onto it, or parts of it 👀
Yeah) It helps me. thx u
I'm up for collaboration the idea if anyone wants to be the primary brainchild. Life's too busy for me to have hobbies
The problem is there is really nothing to automate atm
we're missing everything that might be an input or output.
Like, we need traps, power doors, remote controllable lights.. maybe some kinda crafting factory system, dunno
So if you wanted to make such a mod, like factory like stuff, you'd have to basic make multiple submods to implement resources to actually automate, for example ores, tree farming
As a canadian, the lack of warcrime level traps annoys the hell outta me.
Wheres the giant spinny blade thingys from 7d2d?!?
or electrozap traps
I know that Cars, Players, Zombies, weapons, most placable items and animals are 3d - the rest are 2d sprites
Tiles are 2D, and they a depth map which is used for pseudo 3D
There is the factory parts mods, automated doors has a precedent and wouldn't be difficult as it's just a matter of "receive a signal, trigger door open", traps are little more nuanced but I have seen some psuedo traps such as a spike trap mod and a mod that makes barracades hurt zeds
https://steamcommunity.com/sharedfiles/filedetails/?id=3400131934 shouldnt that fit your needs for now? ^^
Oh it does, being a Network Engineer I just want to be able to plug things in lol
My thought is if the framework existed that have the transport, other folks could build the end points
it is not stored or ever passed to lua
I meant a reference to the distribution being used
Like the key for the distribution table to easily access the loot which can spawn in a container
unfortunately so do i 😅
yeah
When they spawn loot they pick one of the distribution and just rolls for loot and then ditch it
I guess that makes sense, so you can't just have full medicine containers in the military containers and be stuck with it forever
Just to put it out there if anyone decides they like the idea. For speed I organized my thiughts with Gemini I to a concept/design doc for a connectivity framework that could open up some possibilities for automations and inter-device communication.
Use it or don't, just want to punt it out there so it's no longer in my head!
I might be interested in making an electronic mod tbf, a mix of UI and object connections. My main problem is making anything which is tiles and art, but I've got some ideas for an interactive electronic system, where players can cable things together in a workshop UI. If there's actually a sort of internet thing being implemented, of having an interface to view their connected devices, and maybe customize their interactions
That sounds fun to code in
i've been working on something sort of like this, i don't think it'll meet your specifications exactly though
Yea since I know you're working on an electrical mod I'd have to see what you're planning on doing before working on something like that myself, so I don't recreate something you're basically already implementing
My idea is more towards electronic tho, not electrical wiring and machines
the basic concept of my mod is to rework power generation and consumption to require wiring between devices
Yea so it could live outside of my mod concept easily, or even have direct compatibility in a way
originally i wasn't planning to include signals and just consider adding them later, but i've come to realise that power is basically just a signal anyway and trying to leave support for them later would require me to redo most of the work
Just glad it seems something even remotely like it is on someone else's mind lol. Y'all the real MVPs. I'll actually contribute once I don't have so many kids under 5 lol
Yay, I have now completely fixed running over zombies randomly sending your car outta control with excessive impulses
(the impulses had no cooldown and would get triggered between 1~5 times over several 10mS physics timesteps when you ran over a zombie)
👀
Also the issue with animals was they had a corpsesize as big as a car.
And the collision code took offense to that.
uh wdym ?
Version: 42.11.0 Mode: Singleplayer Mods: None Reproduction steps: Run over deer. A debug spawned whitetail buck was used for this test. Then run it over. Then try to place the tire directly over the body at slow speed and this happens: It has uh... a forcefield... that violently ejects your car ...
Running over a deer at 10mph
Yep, thats definately what is supposed to happen when running over an animal at low speed.
... My bug zapper mod has run out of room in its description for all the bugs it fixes. sigh
Make a workshop page discussion
I think a steam guide would be more editable?
a steam guide isn't scoped to a mod
The cool thing with a discussion is that you can pin it to the workshop page
yea but can I edit my posts on it?
I'm talking actual workshop page discussion, not Steam discussion
Of course
yes
i think there is a length limit so if you're really anxious you can reserve a couple posts
yea iv literally run outta character limit for my steam description is the issue :p
A comment has a limit, but you can add as many comments as you want
if you lock the discussion (maybe creating another one for comments if you want) then you can just keep adding posts as long as you want
I don't remember but I think locking doesn't show it has pinned on the Workshop page no ?
you can pin anything you want
That's not what I mean
I mean if you pin, but lock, it won't pin
I'll test
pretty sure you can pin locked threads
i'm pretty sure i did that with starlit before i moved to sphinx
But I remember having to reserve posts bcs there was a specific limitation that didn't allow me to lock properly
Yup
That's the problem
This works
But then if I lock
Doesn't appear anymore
weird
Bcs when you "lock" it means you "close" the thread
well, worst case you can just delete people's comments
Yea tho if he doesn't do that constantly, he'll be fucked
Yea I think I'll just make a guide and link it to huge print/image
like 36pt "CLICK HERE FOR BUGFIX LIST WITH FORUM REPORTS" and just reduce the description to a simpler list of important bugs fixed with no citation links/etc.
Shit, I forgot steam description supports my old friend: tables
But you could even take a screenshot of a Steam guide embed in other Steam things like comments, which nicely embeds it
Let me find an example of that
ah, you already use a guide for your mod anyway
yea for project summer car. Im talking another for Bugzapper 9000
i'd consider hosting a wiki at a certain point
you can do it easily on github and you'll have far more control of presentation
If you paste a guide in a discussion, you get a nice embed
You can take a screenshot of that, and use it for your own stuff
I think I have an example of that wait
Adaptative sound in a way
Firearm sounds changing based on if you're inside or outside
Automatic sound volume based on conditions (zooming in/out decreasing volume)
is that the tiny soundparameter java class stuff littered throughout the codebase?
idk
yeah
@bright fog So the issue is, the vanilla game won't load arbitary soundbank files?
Basically
there has never been any modding support for them whatsoever
You need to manually install it AND you need to replace the whole .bank file which holds every single sound in the game
But we can create them.. thats like, 7/10ths of what you'd wanna do in modding them
Same for game musics with another bank file
fmod is a sound engine that takes in events and parameters from the game and then internally decides what audio to play, effects to put on it etc
Any mod which modifies the same bank file (aka the only bank file that matters) will be incompatible by default
If devs would just open up.. loading .banks from your mod folder...
we don't have a way of sending those events or changing those parameters from lua
and ideally had some kinda override system
Sure, but even just being able to add new sounds that react to vanilla parameters would be amazing.
except sound emitters' playSound methods, which just trigger an fmod event with no parameters
I have mentioned them adding fmod support as a suggestion, in fact I believe it was one of my first suggstion in #1318920979581501502
afaik those parameters only exist for the exact events they're used
so it would only really allow a couple very limited things the vanilla sounds already do
sure but.. new engine sounds. New zombie sounds.
new gunshot sounds
etc.
Actually nah that was somewhere else I think
engine sounds are the only thing i've seen proof actually need it
I feel like for the amount of work needed by TIS (load banks found in mod folders), it would be worth it to support that amount of it.
i don't remember what the thing with zombie sounds was, sim knows about it though
Lots of things
If you don't use FMOD, you need to manually control and time the zombie sounds
And adjust volume
the whole soundparameter thing might be more work then its worth ATM, but at least let us have the most basic of 'add a .bank file' support.
And sound won't adapt to inside outside, so no inside effect for sounds
You need to calculate the zoom level to adjust volume
I went with a manual control of sounds in my Zomboid Forge rework for B42
Tho I only realized recently that sounds volume change based on zoom level, so uh that's not a thing rn
i see, so zombie sounds just don't use events? they're triggered entirely within fmod?
and it probably never will since I no longer works on that
Wdym by events ?
Actions in the game ? They kind of do, like hit reaction and shit like that
Unless you mean something else
Anyone wanna post a request for basic .bank file support in mods here? https://theindiestone.com/forums/index.php?/forum/20-pz-suggestions/
Got things you want to see in PZ? Post here! Tip: search to see if there's already an existing thread.
I'll support it for what its worth.
Not even sure that's possible, depends if the game can even load from different bank files
(God I hate the vanilla engine sounds after 1000 hours of listening to them)
it's been requested several times already
they have a thread for modder requests and it's about as active as the discord one
find a thread and lets bump that? lol..
like lua events, FMOD events are just saying 'a thing happened, do something' and FMOD uses that information to work out which sound to play what effects to apply etc -- most sound triggers are just an event
Pretty sure they do use events then, it's like the footsteps for zombies, they trigger via events for sure since they play different sounds based on the material ?
Tho I'm really not familiar at all with how any of it works internally
footsteps should be events yeah, i wonder if their idle groans are though
it would make more sense for fmod to handle those
They make different sounds based on agro or idle
Maybe when they get close to the player too idk
basically not all sounds have to be manually triggered by java code
music for example is controlled entirely by fmod, the game just provides context about what's going on in the game and fmod decides what music to play
They also have 6 sound types, male and female and A B C
the game might just say 'there is a zombie here, it has sound type male A' and fmod periodically plays sounds whenever it wants rather than on a timer sending events in the java or something
basically just rationalising why it doesn't go through sound scripts, that's the only way i can imagine why
There are sound scripts for zombies
but they don't work fully right?
Never understood how they work tbh
I know I've seen examples of replacing the zombie sounds by changing the scripts
But the control is basically zero
I never got too deep into fmod during my time using it -_-
And the sounds I believe just get constantly spammed
And you can't change A B C type in the sound scripts if I remember right
ahhh, that would do it actually
fmod would use one event for all sound types and pass the sound type as a parameter
1/ Heya Sim 🐕 and also @bronze yoke both whose opinion about good APIs I value. Related to the past feedback and due to my own need to "manifest stuff in the world" I am close to start implementing something.
Given that
The modder wants to change or create something in the world.
They know exactly what they want to change/create and have the code for it.
They either know exactly where/when in the game that should happen or they are flexible and may indeed wish to set dynamic rules.
Problem They cannot change/create it yet because the world isn't ready (chunk load or any other condition, world-time etc. ..)
Vision So they ask a system that tracks their wishes and fulfills them when and where the world is ready for them.
2/
Solution (pre-implement)
Single world change at precise location, when location is ready
local PromiseKeeper = require("PromiseKeeper")
--- User provided function to serve as fulfiller: called once per roomDef
---@param roomDef RoomDef
---@param meta { id:string, fulfiller:string, tag:string|nil }
function LabScene.makeForRoomDef(roomDef, meta)
-- build with SceneBuilder ...
end
PromiseKeeper.registerFulfiller("destroyed_lab_scene", LabScene.makeForRoomDef, "Scene")
---@type RoomDef
local LabRoomDef = MyFinder.pickRoomForLab() -- your own resolver
-- or local LabRoomDef = getCell():getGridSquare(10677, 9783, 0) -- example coords
PromiseKeeper.ensureAt({
id = "intro-destroyed-lab-A",
fulfiller = "destroyed_lab_scene",
target = LabRoomDef,
})
3/
Permanent promise that affects all chunks
local PromiseKeeper = require("PromiseKeeper")
--- User provided function to serve as fulfiller: called once per roomDef
function KitchenScene.makeForRoomDef(roomDef, meta)
-- build with SceneBuilder ...
end
PromiseKeeper.registerFulfiller("kitchen_oddity_scene", KitchenScene.makeForRoomDef, "Scene")
-- Matcher: receives both chunkCtx and optional matchParam table
local function matchKitchens(chunkCtx, matchParam)
local results = {}
local chance = (matchParam and matchParam.chance) or 1.0
for _, roomDef in pairs(chunkCtx.roomDefs) do
if roomDef:getName() == "kitchen" and ZombRandFloat(0.0, 1.0) < chance then
local key = tostring(roomDef:getID()) -- stable keys avoid double-spawning
results[#results+1] = { type = "roomDef", key = key, ref = roomDef }
end
end
return results
end
-- PromiseKeeper ensures these scenes exist as often as requested
PromiseKeeper.ensureMatchingForChunk({
id = "global-kitchen-oddities",
fulfiller = "kitchen_oddity_scene",
matchFn = matchKitchens,
matchParams = { chance = 0.2}, -- every 5th kitchen
maxFulfillments = 999999 -- GLOBAL cap to this promise ID. For "permanent promises" set > total chunks on the map
})
4/
Questions 🙂
- Do you know if something like this already exists? I tried and researched but found nothing that came close enough in my book
- Do you think its a good idea? "meh"? 😄
- I have an implementation plan but I won't bore you with details, suffice to say I think I'll use starlit events for the first time under the hood. In case there is any other advise I'd be glad to hear
🫶 Thank you for the attention and the screen-space.
p.s.: I would love to not need to register fulfiller functions but pass them directly, however promises and who filfills them need to be persisted in modData so I guess string is safer. Now that I say that I think I also need to do that for the matchFn 🫠
Found this cool bug where if a vehicle is facing ~perfectly~ NW, NE, SW, SE you cannot use the V radial menu from a distance without using combat stance (or a controller I'm assuming). getNearVehicle fails to find the vehicle at those specific angles for whatever reason. Discovered it while testing climbable vehicles, just thought I'd bring it up here if anyone else was having issue idk
Make a bug report
Yeah I will in a bit, it's very easy to replicate so it should be a quick bug fix (if they see it)
Hi, I have a general question. In my mod, I want to spawn objects on the map. I understand the logic of chunks, squares, etc., but i have questions.
**I'm thinking about these steps : **
- I create my objects in a ModData table (server)
- Every time a player moves (Events.OnPlayerMove), I check if the object is in the chunk (client -> server)
- I force the creation of the object on the server side (server)
My question is: do I need to synchronize something with the client, and if so, what? How?
To be clear, I'm looking for multiplayer compatibility on B41.
Thank you very much in advance.
Could you please explain what exactly each of these files is used for and how to use them correctly?
seams, seating, spriteModels, tileDepthTextureAssignments, tileGeometry
And could you also please tell me how to add 2x tiles, like in vanilla — tiles and tiles2x?
1x sprites are no longer used in build 42, your sprites are almost definitely already 2x
Discord's time stamps had me confused, forgot today was the end of daylight saving.
Anyways, is there a proper way to just play an animation without doing anything else, just the character doing the animation.
I tried PlayAnim, but literally nothing happened
yeah not really, any API like that is ancient from before the game was even 3d
animations are basically controlled by xml animation scripts
there's a state machine that transitions between animation nodes based on the parameters set in those animation scripts
i think the easiest way to just play an animation is to copy how emotes work but i don't really know the details of that
Excalibar has a very similar system, but instead of checking "is this tile in the active cell" on every move it checks it using the everyTenMinutes event.
That means if you were fast enough you might have the tile on screen when the stuff spawns, but in practical terms you'd have to time it really well and make a deliberate effort to do so. Would be different if the mod was spawning things on the highway so you could just drive up to them easily.
I seem to have added the vanilla sprites, but they were added in lower quality. Also, could you please tell me how to fix the visual bug where the character appears under the texture?
If I understood correctly, I need to modify the tileset and tileGeometry files, right?:
tileGeometry
{
VERSION = 2,
tileset
{
name = uo_tiles,
/* uo_tiles_2 */
tile
{
xy = 2x2,
box
{
translate = -4684x0x262,
rotate = 0x0x0,
min = -315x0x-5262,
max = 315x24494x5262,
}
properties
{
OpaquePixelsOnly = true,
}
}
/* uo_tiles_3 */
tile
{
xy = 3x2,
box
{
translate = 234x0x-4682,
rotate = 0x0x0,
min = -5235x0x-317,
max = 5235x24494x317,
}
properties
{
OpaquePixelsOnly = true,
}
}
}
}
version = 1
tileset
{
file = uo_tiles
size = 8,16
id = 1
// uo_tiles_0
tile
{
xy = 0,0
BlocksPlacement =
MaterialType = Metal_Large
alwaysDraw =
attachedFloor =
solid =
}
// uo_tiles_1
tile
{
xy = 0,0
BlocksPlacement =
MaterialType = Metal_Large
alwaysDraw =
attachedFloor =
solid =
}
// uo_tiles_2
tile
{
xy = 2,2
CanScrap =
Material = MetalBars
MaterialType = Metal_Light
SpearOnlyAttackThrough =
WallWTrans =
makeWindowInvincible =
wall =
}
// uo_tiles_3
tile
{
xy = 3,2
CanScrap =
Material = MetalBars
MaterialType = Metal_Light
SpearOnlyAttackThrough =
WallNTrans =
makeWindowInvincible =
wall =
}
}
I need more practice
damn all these night vision mods and vanilla has it already, just a bit slow when turning off 🧐
You're using the lighting debug option right ?
isWearingNightVisionGoggles()
its the only thing i found 😄
was going to enable nv for my b42 brita googles, so i had to dig around
I mean that's probably why modders don't use it then
I think @sour island might know more since he worked on a nightvision framework
played around a bit, iam content 😄
https://imgur.com/a/MMe32De
maybe some more noise or grain
the red light is from escape from kentucky(not working in their mod atm, fixed that myself), its a supposed to be a thermal sight
I see, you can easily create light sources with Lua in B42 now
October modding wiki summary
only problem iam stuck with is that the context menu is not rly working with the overlay, the mouse is not registering the options
The menu doesn't open or you can't click the options ?
cant click the options and inventory also isnt opening when hovering
Most likely bcs the green effect is actually a UI then
So the cursor is registered as inside that UI
And since it takes the whole screen, the majority of other stuff can't be clicked since your cursor is in that UI
left and right mouse button click works fine, just the hover is broken
Bcs there's no right and left click functions in the UI
But I guess there's still a hover one in the UI
yea was because it used ui manager, doing manual render fixed it
Wdym manual render ?
In the render events ?
dont ask me such complicated questions, claude is doing all the hard work here 😆
💀
function BritaNV.Overlay.ManualRender()
if not BritaNV.Overlay.isActive then return end
local screenWidth = getCore():getScreenWidth()
local screenHeight = getCore():getScreenHeight()
-- Create temporary panel for rendering without adding to UI manager
if not BritaNV.Overlay.panel then
BritaNV.Overlay.panel = BritaNV.NVPanel:new(0, 0, screenWidth, screenHeight)
BritaNV.Overlay.panel:initialise()
end
-- Manually call render (bypasses UI manager mouse handling)
BritaNV.Overlay.panel:render()
end```
```-- Initialize on game start
function BritaNV.Overlay.Initialize()
BritaNV.DebugPrint("Advanced NV Overlay system initialized")
Events.OnPlayerUpdate.Add(OnPlayerUpdate)
Events.OnPostUIDraw.Add(BritaNV.Overlay.ManualRender) -- Manual rendering to avoid mouse blocking
end```
neither time nor patience atm to learn all that stuff, just have to feed him with all the info you can get and set the metadata up right
Been working on alittle submod for expanded helicopter events for personal use. I've been changing the flight sounds of the aircrafts depending on their types. For example, the common military helicopters using blackhawk audio. I've also made some things like the civilian use bell206 audio and the gunship use apache sounds, and so on.
I need to add backup lights to cars someday..
sucks so much backing up at night
what button did i press?was in vehicle editor xD
That could be any button!just mash keyboard keys till it gets better or worse. /s
do note that several of the buttons now turn on cheats like god mode.
also, nice bulldozer 🙂
Smashed like you said in vehicle editor and worked but still not sure which button it was 😅
oh I don't even think you have to be in vehicle editor to turn on wireframe mode?
shrugs
a bit sad that physic boxes only work for ragdolls and work subpar lol
basically stuck due to the weight or downforce they apply
... Ok so its not just my modified vehicles that have that issue lol.
Guess I never bothered to check if it applies reguardless.
yea for collision you still have to use the extents box
wanna test a mod that will let your vehicle be 5000kg+ and still drive? :p
(Can't promise improved ragdoll action, but will absolutely plow through other (non burnt wreck) cars
lol, would be nice if you get that to work
already using that, but 2800 wouldnt move, any suspensions recommendations? ^^
No, it was just updated 30 seconds ago
ah ok
You'll need to do the manual install again
but making it a require for the super bulldozer is not a smart move i think, many ppl just play vanilla physics
Yea at some point I need to make system where mod authors can supply an alternative HP/mass/aerodynamic drag for their vehicles
i mean i could just make a submod with a different, vehicle script file and thats it
Yea
Or alter your vehicle script at runtime with LUA if realistic physics is installed
i tried a speed limiter when bulldoze mode is on, no chance, or it was your mod interfering, havent tested it vanilla 😄
changing the vehicles top speed will dynamically recalculate its final gearbox ratio and should work
I believe you can access it with stablib on the vehicle script..
I really need to play with reflection more from the LUA side.
Using Load() might also work
i had setMaxSpeed running in bulldoze mode and it didnt change a thing sadly
My bad, try that without my mod, looks like I was using the vehiclescript maxspeed and I don't have a copy of the vanilla code to confirm what it does -_-;
(changed my code to use getMaxSpeed on the vehicle object for next update)
Anyway, other then that bug 😛 tell me what you think of the new realistic physics update with a high weight vehicle 🙂
will have to test that on the w900 box truck, i had implemented a function to manipulate its weight to have it behave better^^
fly little ones, fly !
hahahah, zombie be like "my people need me!"
thats basically how I fix the issues, except in much more complicated and cursed ways to fix the issues that also causes
i think i had it read the script mass, the rest will be reduced by x%
Yea, I change what mass is submitted to bullet physics, so the mechanic UI/etc still shows the 'correct' mass
for anyone who might've been wondering, pushing a zombie who has spiked armor on, does not damage you. Was doing some testing and nothing happened
You made sure to not be in god mode ?
Yea
I was only invisible
Pushed 2 zombies in full spiked armor like 30 times and it did nothing to me
invisible has a lot of unexpected side effects, i would try it without
https://steamcommunity.com/sharedfiles/filedetails/?id=3598575779
I launched my M163 mod, it's basically an M113 with a 20mm Vulcan rotary cannon
i was going to make a killdozer in the next weeks and using your track system, but will have to change the layout of the tracks, how difficult will it be? 😄
Honestly, rigging the tracks is by far the most complicated thing of all, it's extremely laborious. That's why, if you notice, I'm releasing several mods with the same M113 platform, precisely to take advantage of the tracks that have been made.
yea i thought so, well if its not reasonable doable it will have to stay that way
True labor of love of firepower. Amazing.
I can't seem to delete these curbs, or copy them... I can also for some reason place other tiles on them now. Has anyone else experienced this big?
Is it too much if I publish this?
#mapping will get you better help
yes with friend
Yo there's my TLOU Infected sounds
Cool shit anyway
Why would it be too much? This is hot as hell.
needs some fine tuning but hey i can power annex buildings ^^
hello! i'm starting out with steam workshop icons, so for anyone that'd like a handdrawn piece for their mod:
my rates start at 40 USD for rendered stuff and 25 usd for anything for simple and flat ^^
caard in bio, contact through dms for inquiries and other samples of my work :D
-# character is a spiffo-sona because i thought it would b funny
You'll probably have better luck with this sort of thing in the unofficial modding server—it has a channel for commissions
thanks ^^
Hi, I don't think I'm in the right place, but anyway...
I've developed a mod manager for dedicated Project Zomboid servers in docker.
It allows mods to be disabled or re-enabled without uninstalling them.
Mods are added automatically using their Workshop ID.
The site includes a filtering and sorting system.
Changes to variables in the world.ini file are applied instantly.
There's also an integrated server restart system via Docker.
I've tailored the script to fit my own setup, and I don't think I have the skills to handle every possible case.
What I can say is that it's fully functional.
That's all from me.
Anyone tried using Events.OnAddForageDefs to remove an item from showing in search/forage mode?
Or wait a minute, there's canBeForaged for items, let's see if it works
Hello, I've got a question.
I would like to cache the IsoPlayer object at the start of the game for later use in multiple local functions.
Is there a safe way to do this and make sure it doesn't lose scope throughout the program? I've got numerous calls in different functions requiring a player object, and I just want to tidy things up if possible.
Thanks!
if you do not want MP nor split screen, use getPlayer(). that's the point of it. Else, you need to understand what is the contextually correct IsoPlayer to use in each situation.
Thanks for the response Tchernobill.
I've used a variety of the methods, and I know there are results when ran from server vs client. I'm just trying to figure out all of those contexts so I can apply them without second guessing things.
I'm not worried about split screen at all, but I've seen that getSpecificPlayer() is used for that context?
getPlayer() seems to be client and server side, is that correct?
getPlayerByOnlineID is for Multiplayer, and I've used that in one of my mods to send client commands to specific players, if I recall.
I know functions can be similar but give different results, so mostly trying to pick everyone's brains about use cases.
Thanks for any insight you may have!
getPlayer isn't server side
When you talk about client and server side stuff it's MP
It cannot be SP
Imo there's no point caching the player
Most relevant events give you the player when needed, and if they don't just run a getPlayer, or iterate from 0 to 3 and get players with getSpecificPlayer to run the code for every players if you want to add support for splitscreen
If you don't give a shit like most of us, then just go with getPlayer
And cache the player locally in your function when it runs do you don't retrieve the player with getPlayer everytime
But imo no need to bother caching getPlayer like OnGameStart or smthg like that
Thanks, thats pretty much exactly what I was thinking. Refactored a bunch of my code, especially OnCreate from recipes, to just use the player from that, instead of re-getting the player constantly.
Turns out it's ISSearchManager.ignoredItemTypes["Bicycle.Saddlebag"] = true to make that item not show a pin while in search mode
Nice good to know
I tried adding my own tiles by taking vanilla sprites and putting them into a .pack. Could you please tell me how to make the sprite appear in high quality? And also, how can I make the sprite have collision on all sides?
also been messing around with ehe's preset guide for custom chopper events. Made the no mercy chopper from l4d as a fly by
Does anyone know, if it's even feasible, to increase the distance and volume of all zombie footsteps in the game? I was just killed by a bloody sprinter that made no sound until it was 1 square away behind me. That's ridiculous.
Is this even possible?
Known bug, B42.12's audio is all over the place
Iv even seen car engines randomly mute
Super hard to reproduce too -_-
Yeah, I've had that too. But is it possible to address in a mod and make the volume and range something changable in Sandbox Settings?
No, its the game bugging out and not playing sounds it should.
there is a huge volume override mod with like volume settings for everything, but its seriously just the game not playing the sound at all at random
And its the kinda bug Im VERY glad im not getting paid to fix, lol
Unless you get paid by the hour! 😉
Because like.. screw trying to track down a bug with 1% reproduceability lol
Id rather get paid by the hair that falls out for a bug like that, get more money that way.
lol. Depends how much hair you have to start with! 😉
LOTS. somehow.
somehow because every time I brush it, theres like, a small cat worth of hair that comes out and im like... wtf?
How lucky, he's got hair
Are you able to modify vanilla game items, such as a generator to change it's behavior? Or would I have to create my own generator item to craft & use?
I don't even think you can create your own generator
Nor can you modify the vanilla one
you can add new generators but you can't really change their behaviour
different generators can have different durability and noise radius but that's it
Oh gotcha, was looking to see if I could make a generator that powers the entire building - rather than the default 20 squares or however many it is.
A mod just released doing that
By @knotty stone
I wonder if there'll be a modern day mod
or maybe uh late 2000s mod
that shifts the year from 1993 to 2009 maybe?
bulshit ai
The mod itself isn't bullshit, the preview is tho
But the reason I'm mentioning this mod is bcs I've seen Beathoven's work being shared around here, and his mod is legit
But I can only agree that the AI preview will hurt your mod @knotty stone
Bcs that's the reason most people have: AI preview = AI bullshit mod
It's also one of the reasons we tell modders not to use AI preview, bcs it can seriously hurt their mod popularity, very notably
well you want me to draw something like some 5year old, i cant draw shiaat 😄
I can't draw shit either and yet I manage to make proper previews
Even an in-game image is good, you can ask @willow tulip, he was in your situation and yet now he makes mod previews that does make people want to click his mods
well i could just take a screen of the info window or smth
dont get all that ai bullying lol
Nah people won't understand it
ingame images, or simple image editing will look way better
this IS true
beathoven makes cool stuff from what ive seen
Tbf, it does make your mod look terribly worse than if you had a shitty screenshot, that's the thing
And it's not about "NOOOOO AIIIII BAAAAD", it's just a fact, people do not click AI mods as often, it's not hard to notice this behavior. Does it mean an AI preview can't make your mod work ? No of course not and I think where it works the "best" is with those sort of pixelated images, of like items, a room etc (just check the current mod list you'll easily find one or two)
AI preview also screams to people "AI mod", and we are literally the first ones that notice how AI is become very present in modding, as we get constantly new modders coming here for help but their entire stuff is AI so it's just impossible to help them since everything they made is bad
it has a more subtle affect on how most people view your mod: AI doesn't take any effort, if the first thing they see is AI they're probably going to think your mod is low effort and be much more likely to skip it
That
ai also like IS one of the things that are demolishing our society right now
it takes away the humanity of stuff, and its LITERALLY ruining lives
(also again: at least one person has DIED because of ai datacenters)
i already knew about your mod from you posting it here, but i can tell you with confidence that if all i saw was that image on the workshop, i would not check out your mod
yea humanity and its prejudice
xD
but i get it, will take a look to make it different
You could simply take a screenshot of your character with a thumbs up, in front of a generator, that is stuck to a building, with a written text of your mod's name
And it would be so much better and in fact I would argue it conveys better what your mod is about
- character thumbs up: good stuff
- generator next to a building alongside the name: we clearly understand what it is about
In your AI preview it's not the case, you just have a building with a generator, that's not on scale too, with zombies around, it doesn't convey the same thoughts
Generator, barrel, MS paint a pipe between the two, im already downloading it.
I tried adding my own tiles by taking vanilla sprites and putting them into a .pack. Could you please tell me how to make the sprite appear in high quality? And also, how can I make the sprite have collision on all sides?
Attempting to make a B41 mod with a custom item. I'm able to get it to spawn - however when I dismantle it, I get an error. Any ideas? Not too familiar with Zomboid modding yet.
at zombie.inventory.RecipeManager.PerformMakeItem(RecipeManager.java:1191)```
`MOD/media/scripts/Recipes_DismantleElectricityBooster.txt`:
```module Base
{
recipe Dismantle Electricity Booster
{
ElectricityBooster,
keep [Recipe.GetItemTypes.Screwdriver],
destroy ElectricityBooster,
Result:ElectronicsScrap=2,
Time:20.0,
Category:Electrical,
AnimNode:Disassemble,
Prop1:Screwdriver,
}
recipe Dismantle Used Electricity Booster
{
ElectricityBoosterUsed,
keep [Recipe.GetItemTypes.Screwdriver],
destroy ElectricityBoosterUsed,
Result:ElectronicsScrap,
Time:20.0,
Category:Electrical,
AnimNode:Disassemble,
Prop1:Screwdriver,
}
}```
`MOD/media/scripts/Items_ElectricityBooster.txt`:
```module Base
{
item ElectricityBooster
{
DisplayName = Electricity Booster,
Type = Normal,
Icon = RemoteCrafted,
Weight = 0.2,
ReplaceOnDeplete = ElectricityBoosterUsed,
UseDelta = 1.0,
}
item ElectricityBoosterUsed
{
DisplayName = Used Electricity Booster,
Type = Normal,
Icon = RemoteCrafted,
Weight = 0.2,
}
}```
You need to use the correct tile definitions, just look at the vanilla tile definition using tilezed and copy the settings from a wall or fence to your custom tile
no, it still sucks
I copied the same sprite def
It's been a while since I did tile stuff, maybe ask in the mapping discord instead https://discord.com/invite/CFuNM8rtCp
thanks, I'll try it
do i understand it correctly that the HeadConditionLowerChanceMultiplier in item code means the multiplier for standard durability reduction chance, and that all weapons burn more durability on tool heads than handles?
also, can someone tell me what does the Sharpness line in weapons do specifically? all weapons that have it are set at Sharpness = 1.0, so i am kind of confused
I don't think that's a rule no. From what I can tell it basically takes the HeadConditionLowerChanceMultiplier and multiplies by 1 before feeding it to the random roll that determines if it should lower the condition.
So if you set HeadConditionLowerChanceMultiplier to something less than 1 it should drain slower, greater than 1 and it drains faster
But I haven't tested it, just basing it on the java
i figured as much, but judging from the weapon stats code all weapons but the glass tipped spear have HeadConditionLowerChanceMultiplier at 1.0 or above, meaning their tool heads are supposed to degrade faster than handles
which is weird since handles generally break faster during actual gameplay, and logic-wise all tools aside from brittle glass spear should have more durable tool handles
could it be that HeadConditionLowerChanceMultiplier is inverted and higher values decrease degrade chance instead?
As far as I know, sharpness affects a weapon’s damage as well as its chance to low the condition. While the weapon’s sharpness is greater than 0, whenever a break chance occurs, only the sharpness is reduced, not the weapon’s actual condition. When sharpness == 0, then with every hit, the weapon’s durability is consumed regardless of the break chance.
are you sure that sharpness prevents the condition loss? i am mostly sure that a hatchet ive been using was losing both handle and tool head durability, although the latter was much slower
As far as I can tell Мепсель is correct, the sharpness basically acts as a buffer and stops condition from being lowered until it reaches 0. It also affects damage done and crit chance as sharpness drops
But sometimes things don't work the way it looks like they should from just reading the code lol
There's so many factors at play that there could be something I missed
also, do i understand correctly that the sharpness has the same amount of "durability" as the tool head durability?
yes, Iv poked through the code and the two are linked (though not nessecarly 1:1, there is some difference between the reduce durability chance and the reduce sharpness chance, IIRC)
Could someone please give me an example of their recipe (B41) for dismantling a custom item? I can't seem to get it to work properly.
Anyone know of a way or reference mods where an existing perk is edited?
Will PerkFactory.AddPerk override an existing perk?
For ex. I want the exp needed to level 10 for Farming increased
They should add a drone mod for aerial back up
Hi everyone, I need a little help. Since version 42.12, it seems the weapon repair system has changed. I used to be able to repair katanas in my mod with codes like this:
fixing Fix LegendaryKatana
{
Require = LegendaryKatana,
GlobalItem = BlowTorch=5,
ConditionModifier = 1.5,
Fixer = SheetMetal=1; MetalWelding=8; Maintenance=4,
Fixer = ScrapMetal=3; MetalWelding=8; Maintenance=4,
}
But this doesn't seem to work anymore. Can someone tell me how to do it now?
maybe you need to declare the module on the items
{
Require = Base.LegendaryKatana,
GlobalItem = Base.BlowTorch=5,
ConditionModifier = 1.5,
Fixer = Base.SheetMetal=1; MetalWelding=8; Maintenance=4,
Fixer = Base.ScrapMetal=3; MetalWelding=8; Maintenance=4,
}```
I've tried using a separate module called lk_fixing.txt and within the recipes module, but I think you can no longer repair by right-clicking on the object; you have to do it through the crafting console -> repair.
the repair system was kinda standardized, you can use tags in your items now to use the standard fix recipes, maybe you can use that
something like that i guess ``` item LegendaryKatana
{
tags = RepairKatanaSheet;RepairKatanaScrap,
}
craftRecipe RepairKatanaSheet
{
time = 180,
AllowBatchCraft = false,
Tags = InHandCraft,
category = Repair,
timedAction = CraftWeapon1H,
SkillRequired = Maintenance:3;MetalWelding:8,
xpAward = Maintenance:15,
OnCreate = CraftRecipeCode.GenericFixing.OnCreate,
Tooltip = Tooltip_Recipe_CanFailAndDamage,
inputs
{
item 1 tags[RepairKatanaSheet] mode:keep flags[Prop2;IsDamaged],
item 5 [Base.BlowTorch] flags[Prop1],
item 1 [Base.SheetMetal]
}
outputs
{
}
}
craftRecipe RepairKatanaScrap
{
time = 180,
AllowBatchCraft = false,
Tags = InHandCraft,
category = Repair,
timedAction = CraftWeapon1H,
SkillRequired = Maintenance:3;MetalWelding:8,
xpAward = Maintenance:5,
OnCreate = CraftRecipeCode.GenericFixing.OnCreate,
Tooltip = Tooltip_Recipe_CanFailAndDamage,
inputs
{
item 1 tags[RepairKatanaScrap] mode:keep flags[Prop2;IsDamaged],
item 5 [Base.BlowTorch] flags[Prop1],
item 3 [Base.ScrapMetal]
}
outputs
{
}
}``` but i think you would have to check the on create function for the condition modifier dont think that will work in a craft recipe.
The only fixing recipes I can find are for firearms. I would probably just make a normal craft recipe to repair melee weapons, like vanilla does
Thank you so much, I'm going to try it this way
This solution doesn't work for me, or I've implemented it incorrectly, because it crashes when loading the mod.
i just saw that i had an error and corrected it
item 1 tags[RepairKatanaScrap] mode:keep
you have to change the tags there to match them from the item
try again, thx a lot
Thank you so much for your help, it's working as it should now. I just added a small correction to your code because otherwise it wasn't using up the materials and allowed repairs without having them.
item 1 [Base.SheetMetal] mode:destroy,
item 3 [Base.ScrapMetal] mode:destroy,
Taking advantage of your kindness, one more thing: how can I change the icon that appears in the repair recipe? It shows one of the katanas, and I'd like something more generic.
As far as I know recipes show icon of first/default result item
i think gets the first item with tag=repairkatanascrap... in items.txt
😆
Amazing 😉
Hiya.
Is there some sort of project zomboid clothing mod implementation guide? From having a blender Model into converting it into code and as a steam mod?
what loads first?
OnGameStart
OnCreatePlayer
i assume gamestart
On game start I believe
Just test it with a print
trying to get the decompiler working and feel like i'm pulling teeth
anyone had this issue? i can't find anything useful on it and none of the fixes seem to work
i've tried installing different versions of java, clean installing them, etc
not very familiar with java
okay somehow i got it working and i have no clue how
fuck you java
oracle is a bitchass company
satanic black magic shit
Hello, I have a problem, so I'm asking for your help.
The problem is that when you finish the drink, the item has to change to an empty bottle and an empty can
It remains the same. ReplaceOnUse = does not work.
module Base
{
item LetsBeCan
{
DisplayName = Let's Be Can,
DisplayCategory = Food,
Type = Normal,
Weight = 0.1,
CustomContextMenu = Drink,
Icon = LetsBeCan,
Packaged = TRUE,
StaticModel = BeerCan,
WorldStaticModel = BeerCan_Ground,
ReplaceOnUse = Base.LetsBeCanEmpty,
Drainable = TRUE,
component FluidContainer
{
ContainerName = LetsBeCanEmpty,
Capacity = 0.3,
CustomDrinkSound = DrinkingFromCan,
Fluids
{
fluid = LetsBe:0.3,
}
}
}
item LetsBeCanEmpty
{
DisplayName = Let's Be Can (Empty),
DisplayCategory = Trash,
Type = Normal,
Weight = 0,
Icon = LetsBeCanEmpty,
CanStoreWater = FALSE,
StaticModel = BeerCanEmpty,
WorldStaticModel = BeerCanEmpty_Ground,
component FluidContainer
{
ContainerName = LetsBeCanEmpty,
Capacity = 0.3,
}
}
If you are using the base module you don’t need to/shouldn’t define Base before each item
I’m not sure if that will fix your problem or not though
okay thank you, i try it
Unfortunately, it is still unresolved. T^T
i dont rly get what you want to achieve you said "change to an empty bottle and an empty can" so you want 2 items back?
if you have a fluid container you dont need an empty item, only for spawn purposes if you rly want.
What I want is that when I finish the drink, the item is converted to the empty cans and empty bottles that I defined.
I want to utilize this in the recipe.
If the item code becomes the same, for example, cans with drinks and empty cans are treated as the same item, increasing only the number.
When I put it in the item slot window, the user is confused.
I want it.
First drink item code: LetsBeCan
After drink item code: LetbeCanEmpty
But now, the item code is the same.
i cant really read your can item in the screen but it should have the empty prefix already, if you look at the vanilla recipe for break glass you cant use a bottle with fluid remaining. maybe try working with that. else you would have to create your own drink timed action to replace the bottle/can
Thank you for your help.
Me, genius
https://imgur.com/a/f5Qk2X1
🤪
It's still weird to me that they have a dedicated key that's only used for swapping between the options in the pick-up menu (tab), but that same button is not used to enter the menu.
I had to make a mod just so tab makes you enter pick up mode. If you want to save yourself some mouse movements: https://steamcommunity.com/sharedfiles/filedetails/?id=3490233499
Might cause some issues when MP comes around since tab is also used for switching chat streams (which is only applicable to admin chat vs. regular chat in vanilla)
By issues I just mean multiple things happening on key press to be clear, not a huge deal
Oh, good call, I haven't played much multiplayer. I could add an option so it's long press to enter pick up mode. I currently have long press to exit so would be easy to add
@knotty stone I see you have a heating feature in your generator powered building mod, would you mind just giving me a quick rundown on how you implemented it? I'm not at my computer right now so can't download and check. I want to see if it's likely to be compatible with my realistic temperature mod which adds heat transfer for buildings.
iam just checking room tiles and place one heatsource in the middle(roomsize<50 tiles), needs some special case handling like U and L shape.
Ah okay sweet, then it should be compatible with my mod 👍 it takes any active heat sources into account when calculating the simulated values
👀
That just gave me an idea
I've been meaning to do my own take on the push furniture mods, and I could add a new button to that menu
<@&671452400221159444>
Can you tell me what the message was?
it was the usual four images only financial scam thing, i didn't look closely at it
hmmm... 4 images with nothing else should have gotten swatted by the bot
was definitely 4 images though?
yeah mine got swatted
i only looked at it briefly so it might have been fewer images or something, it didn't look like the exact images i'm used to seeing
okay... they might be changing up... sigh
Are these new accounts mostly or compromised older accounts?
Could make recruits unable to post images - it would just be links then.
It's compromised accounts. I wrote a bot to deal with them and it gets 95+%, but one apparently got through.
Nice work! I was hoping someone would.
Mmm, weather/offroading affecting vehicle traction feels quite nice
I have no idea why TIS disabled per-wheel friction -_-;
The B43 car update is gonna go crazy
Not to overhype it too much, but vehicles are lame in vanilla rn lol
Sure, but till then you can try https://steamcommunity.com/sharedfiles/filedetails/?id=3559765660 :0
I know I know
But when multiplayer comes around I'll be double disappointed without the mod lol
Iv heard tell from unofficial MP players that it works fine in MP 😛
How does that work for servers?
My new dynamic friction stuff will be a little borked, but id hope that TIS would see it in their infinite wisdom to let me do that per-vehicle instead of per-vehicle-type.
None of it runs on the server, its all client side anyway.
Wouldn't every person on the server need to manually install it?
In theory to maintain a fair and balanced game? yes
In practice? id have to add code to enforce you install it or have it fallback to vanilla behavior if its not enabled on the server.
I just don't think a lot of servers would want to do that
I dunno, maybe there will be
Then they can enjoy towing cars at 15mph, with GTA2 level vehicle physics.
Yep, and that sucks, I will GLADLY bring up your mod every time a sever is thinking about adding mods
Thanks.
I mean ideally TIS would just adopt all my changes (and revert back some of the things they hardcoded for MP testing that directly breaks freatures in Project Summer car)
2029
Yeaaa
Tis why I didn't bother waiting after reporting said bugs...
Only to find out one of them was actually just purposefully hardcoded and commented on in the java code...
The only "bug fix" I did in mine was removing a singlular line in lua that tbh I don't even know what it does, it just broke transfering items into other car seats from the outside to enter automatically.
gah the phrasing
Like if I wanna sit on a seat?
Yeah
.... WHY WAS THAT NOT VANILLA
pain
does it do a cool timed action and everything for the transfers?
It was at some point, I remembered it, looked into it, bam
It just works and all
Like that sounds like a feature id want, having been blocked before
I dunno what you mean by cool though lol
I bet they disabled it because of people reporting getting locked out of seats (apparently due to the limit not counting fluids in containers?)
That could be it
(that fluids part only recently found out in B42.13)
they maybe thought it was stuff getting moved around causing it
or people not realizing stuff auto-moves as needed
I honestly did not test the side affects of removing that line, all I know is that nothing bad happened immediately and no one has commented on it after nearly 6 months now
lol
problem solved
lol
I also kinda wanna rebalance all the vehicles to real world stats now
but I don't feel like looking up said stats of every vanilla vehicle since I have no clue what most of them even are, not being that big of a car guy..
Some of the vehicles should feel.. totally different lol.
Like apparently step vans are really 3000kg+, not 1300 or whatever they are ingame..
And yea, Not every 1993 car had a 400hp+ engine lol
But the 400hp thing is a matter of scaling HP to ingame impulses (ie, retain the existing forces, but have the UI show like 100hp for a typical car) while the HEAVY ass cars get 200~400hp engines
and maybe a few of th muscle cars get like, 200hp engines