#mod_development

1 messages ยท Page 295 of 1

bright fog
#

However the way I will do it is probably not good for you to go to (as I'll do like Bandits and control my clickers manually) BUT

hollow rock
#

I'm basing mine off the death angels from a quiet place

bright fog
#

Someone found something the other day

#

Zombies, take on the effects of VisionModifier

#

So if you put glasses on a zombie, they have a worse vision

#

However you can't set the value to 0

#

It needs to be at least 0.01 I believe, but that's still really low vision

hollow rock
#

Is there a way to disable it instead?

bright fog
#

Tho I really don't know how that actually affects zombies

bright fog
#

Currently

#

not

#

I asked for access to the values that affect stealth for zombies

#

But that'll probably have to wait ...

hollow rock
#

Dang

silent zealot
hollow rock
#

I'd be happy to take on the challenge

silent zealot
#

The java accepts a list of possible alues for vision/hearing, which are the ones you see in the sandbox options - so no "blind" or "deaf"

hollow rock
#

I see

unique harbor
#

I hope someone can maybe help me figure out why my game crashes when doing that... the debug log doesn't seem to log the error that's happening.
EDIT: runs in OnRefreshInventoryWindowContainers(inventoryPage, reason)

if inventoryPage.onCharacter == true and reason == "buttonsAdded" then
    local playerObj = getSpecificPlayer(inventoryPage.player)
    local backpacks = inventoryPage.backpacks

    for key, backpack in ipairs(backpacks) do
        local items = backpack.inventory:getItems()
        
        for i = 0, items:size()-1 do
            local item = items:get(i)

            if item:getCategory() == "Container" and item:getType() ~= "KeyRing" and not playerObj:isEquipped(item) then
                containerButton = inventoryPage:addContainerButton(item:getInventory(), item:getTex(), item:getName(), item:getName())
            end
        end
    end
end
hollow rock
#

Like I said I'm new to modding

silent zealot
#

In this case, it's just sandbox options that the java makes use of

#

One important aspect to Zomboid is the game is spilt into the java engine and the lua scripts & data files. Mods affect the lua code, but to affect java you need people to manually replace files in the game installation; a few mods like better car physics do this but it's rare and undesirable.

#

Sometimes you can find a crazy workaround, like changing tooltips by swapping ina fake item, letting java populate and render the tooltop, then swapping the item back. Other times you just give up on a mod idea because it hits the Great Wall of Java.

hollow rock
#

I hope the B42 modding tools rectify this issue

bright fog
hollow rock
#

They said that they would be improving it

bright fog
#

I do hope they give us access to stealth parameters

#

Especially specific zombies stealth parameters

silent zealot
#

They wont, it's a fundemental game design thing - but what will help a lot is when modders make a focused request in the Modding Request channel, because then speciifc java things can get exposed to change.

hollow rock
#

Where is the request channel?

#

Does it exist

silent zealot
#

it's a thread under this channel.

bright fog
#

Not really

#

If we get access to these

#

That's really good

#

Or something in this way

#

That'd be great for us

silent zealot
hollow rock
silent zealot
# bright fog

I meant the general "we can't change java other than through exposed API calls/oublic fields"

bright fog
bright fog
#

But if they expose this kind of stuff to us, that could be very useful to make blind zombies

hollow rock
#

I see

bright fog
silent zealot
#

Every zombie spawns with Groucho Marx glasses that have a .0001 vision modifier?

umbral raptor
#

hey guys i need help with a lua script

silent zealot
umbral raptor
#

im not familiar with lua scripts but how do i make a new action related to an item appear

bright fog
silent zealot
#

Because everything is a table.

bright fog
umbral raptor
#

nope

#

not a recipe

bright fog
#

And I'm not talking about a recipe either lol

umbral raptor
#

i want to add a book that allows the player to read and gain XP instead of XP multiplier

#

so im trying to implement an action called "ReadGuide" that adds the XP

silent zealot
#

Maybe: 1) make invisible turns-you-blind glasses 2) set all zombie outfits to include these 3) on zombie death they are removed from the zombie inventory

bright fog
#

Welp idk how books work in the game tbf, but I suppose it's a read book timed action or some shit

umbral raptor
#

yeah its a timedaction

bright fog
flat relic
#

there's already a mod out there that does something similiar in B41, you could take a peek at how they did it

flat relic
#

Nah, I mean the "skill literature" that gives XP on reading, sorry should have clarified that

silent zealot
#

Either intentionally or because the code aborts

bright fog
bright fog
#

I use it for my zombie models

#

My Clickers have a custom full outfit model

silent zealot
bright fog
#

And it doesn't have a display name so it can never spawn in the inventory

umbral raptor
silent zealot
#

It gives XP & recipes via a timed action when read, up to the limit of the character that wrote the journal

bright fog
#

Nah I'm not reading that shit mate sorry

umbral raptor
#

its prolly all wrong right haha ik im not gonna use it

bright fog
#

I'm not debugging a full on file when the first lines aren't even a timed action

umbral raptor
#

im asking how can i make a timedaction for that?

#

ight bro whatever

bright fog
#

Did you read the timed action for book reading ?

umbral raptor
#

ill check out some other things

#

there is none actually

#

that i found

bright fog
#

What ?

silent zealot
#

Skill Journal.

umbral raptor
#

in the scripts folder

umbral raptor
silent zealot
#

has a context menu entry that triggers a timed action that reads a book that gives XP.

bright fog
#

Check the mod skill journal

umbral raptor
#

that mod could have what i need

#

yeah

#

thanks alot bro!

#

that helped

silent zealot
#

Look how they did it - might not be the best way, but it works.

umbral raptor
#

yeah im still new to modding haha

bright fog
#

Timed Actions are not in the scripts folder

#

They are in the lua/shared/TimedActions folder

umbral raptor
#

media>scripts>timedactions, there is a list for alot of timed actions

bronze yoke
#

yeah 'timed action' now refers to two different things at the same time for no reason

silent zealot
#

They are all over the place, but always under media/lua

umbral raptor
bronze yoke
#

they define sounds, animations, etc for recipes

umbral raptor
#

thats what im talking bout

bright fog
#

what ?

umbral raptor
#

its not a folder

#

its a txt file

#

like animations.txt

bright fog
#

I mean

silent zealot
# umbral raptor

those are a bunch of parameters used by vanilla timed actions, not the actual times actions code

bright fog
#

God why did they name it timed action

#

That's a REAL timed action

bronze yoke
#

i've been complaining about this

umbral raptor
#

ight ha i get it now

silent zealot
#

In general, every timed action is in a seperate file in a folder names TimedActions

bright fog
silent zealot
#

but could be client/server/shared, could be a directory like "farming/timedactions" or "vehicles/timedactions"

frank elbow
#

Are they aware of the complaint? Seems like a no-brainer to not have a name collision of concepts for no reason

bright fog
bronze yoke
#

i haven't raised it since i don't think it's something they did by accident

#

i can't imagine the motives for it but they did choose to do this

bright fog
#

That's a hard mistake to make yea

frank elbow
#

I think for my mental health I'm just going to pretend it was an accident anyway

umbral raptor
#

--reading glasses are a little faster
local eyeItem = self.character:getWornItems():getItem("Eyes");
if(eyeItem and eyeItem:getType() == "Glasses_Reading") then
time = time * 0.9;
end

#

Found this while reading through the ISReadABook file in the vanilla timed actions files

#

does it mean u read faster with eye glasses? haha. if so i didnt know this before

spring jasper
#

Hello folks! I am new to modding PZ and new to Lua in general; I have a question to try to understand the code a little better. Is the :create method called automatically when an object is instantiated? I am not seeing the :create method called explicitly, so I am curious if that is the case or if I am just missing things.

silent zealot
#

Lua objects are... well they are tables with an object-shaped disguise on.

spring jasper
#

Oh, sounds like I am further from dipping my toes in than I thought ๐Ÿ˜†

bronze yoke
#

there's no special relevance to a :create() function in lua itself but a lot of the base classes the game uses will implement something like that

#

i think you're probably looking at ui which does do that

silent zealot
#

Java objects that are accessed through the various API calls... I'm not sure if they all have a create() that is the constructor, I've typically only created inventory items from scratch and I do that with instanceItem("Base.SomeItem")

spring jasper
bronze yoke
#

that would be in ISBuildingObject, create() is called when clicking

#

the cursor stuff, to be completely honest, is an absolute nightmare

silent zealot
bronze yoke
#

they're all built on top of the build cursor instead of having a generic cursor class to build on so most of them have to have a bunch of extra code to disable all the building stuff ๐Ÿ˜ญ

bronze yoke
spring jasper
#

oh my, I see my mistake now; I saw the self:create line, but didn't read the whole clause right that led to it. I saw the ISBuildMenu.cheat and completely wrote it off before noticing the big fat 'or' there unhappy

#

Thank you!

open drum
#

Guys i still couldn't figure out a bypass method or another method that could make my "spreading trash" code

#

the code runs with Event.LoadGridsquare.Add()

#

but as you can see on 5 o'clock and 6

#

depends on the direction where the character is coming from. some chunks/grids are not loaded so the trash gets stuck within the chunk and does not spread

#

is there any method to solve this problem?

#

spreading trash function looks as follow ```
function SpreadTrash(Square)

local RecievedSqInfo = Square;
local PosX = RecievedSqInfo:getX();
local PosY = RecievedSqInfo:getY();
local PosZ = 0;
local SpreadChance = ZombRand(0,10)
-- print(SpreadChance)
if SpreadChance <= 3 then
     local posSQ = CalculateAdjacentFloor(RecievedSqInfo)
     local isoObject = IsoObject.new(getCell(),posSQ,  "d_trash_1_20")
       isoObject:transmitCompleteItemToClients()
       isoObject:transmitCompleteItemToServer()
       posSQ:AddTileObject(isoObject);
    
end

end

ebon dagger
#

For future info, because I can't do b42 Multiplayer to test it.

If player A's client adds to the mod data for an item (in my specific case, it adds an entry called "CurrentAmmo" to the mod data)

if player B grabs that same item, is the moddata passed?

bronze yoke
#

yeah

#

there's some bugs with it in b41 multiplayer (generally it works like this as expected though) but i imagine in b42 that probably won't be the case

#

it maybe could be necessary to add item mod data on the server side in b42

ebon dagger
#

Ok, that won't be too hard I don't think. Thank you for the info.

open drum
#

ugh i must admit Event. OnLoadGrid isn't good idea to use

#

Any other Event I could use to make my code flow better?

#

wish there was a onchunkload or something

bright fog
split summit
#

Hi guys, anyone has a sort of resource/guide or content where I can look up to learn how to add new traits into the game.

I don't want to do anything too complex, but I'm developing a mod that basically I want to add traits to the items when you equip them, I already kinda coded the trait on item equip functions but now I wonder how can I create new traits...

vast pier
#

depends on what you want the traits to do

vast pier
open drum
#

just for fun purpose

open drum
vast pier
open drum
#

so when then spread, the radioactive zones spread

#

agreed

#

i mean i managed to get everything to work Except the unloaded chunk spreading part

#

as you can see from the image, the 12,1 o'clock northern side chunks are not loaded

#

if the character walks from the south

#

so they never get spreaded over there

#

tried to run Events.LoadChunk.Add(LoadChunkforsq) to run before the Events.LoadGridsquare.Add(LoadingSq)

#

guess it wasn't enough

#

tried putting Events.LoadGridsquare.Add(LoadingSq) inside the LoadChunkforsq function

#

and that gave massive lag

true nova
#

here's something I've been working on that i finally released, thanks all that give help here

vast pier
#

The TM 31-210 Improvised Munitions Handbook is a 256-page United States Army technical manual intended for the United States Army Special Forces. It was first published in 1969 by the Department of the Army. Like many other U.S. military manuals dealing with improvised explosive devices (IEDs) and unconventional warfare, it was declassified and ...

#

hits that year requirement for immersion

vast pier
vast pier
vast pier
sly monolith
#

so i've run into a weird problem with this, after adding that Icon = line to the crafting script, then making custom icons, now when i craft lets say the red version of the item it doesn't have any icon at all in the inventory. After crafting a tinted version of an item i get an error: ```function: InheritColorFromMaterial -- file: recipecode.lua line # 275 | Vanilla
Callframe at: performCurrentRecipe
function: perform -- file: ISHandcraftAction.lua line # 158 | Vanilla

ERROR: General f:12045, t:1737431924108> ExceptionLogger.logException> Exception thrown
java.lang.RuntimeException: attempted index: getColor of non-table: null at KahluaThread.tableget(KahluaThread.java:1667).```

open drum
#

maybe try doing Icon = Item_line

sly monolith
#

but after restarting the game the icons are back to normal lol

open drum
#

interesting

sly monolith
#

do the icons have to be in the same folder as the textures for the item?

open drum
#

if you want to use the script file

#

then yes

sly monolith
#

then maybe that's the problem here, gonna move them heh

#

right so now there's the ? sign everywhere

ebon dagger
#

Does DoorDamage on firearms (which is on all vanilla firearms) just, do nothing? lol

open drum
#

did you have your item name

#

Item_line?

sly monolith
#

i have this in my crafting script Icon = Item_FaceMask_Red,

#

and this in the clothing script IconsForTexture = FaceMask_Red;FaceMask_Black;FaceMask_White,

#

it must have something to do with the icons being in a different folder than the textures, but in the base game they have them bundled in .package files and they work just fine anyway

#

idk how all that stuff works, but for different items i have textures and icons in 1 folder and those work just fine

ebon dagger
#

Remove Item_ from the Icon Line.

Icon = FaceMask_Red,

#

But don't remove it from the png.

sly monolith
#

i have it like that in the other stuff that works tho

#

even the ones that only have 1 color choice work fine

#

it's just those that have more than 1 color

ebon dagger
#

Oh, weird. I guess I have just been doing it the other way for so long, I thought it was supposed to be like that. lol

sly monolith
#

i mean maybe you're right, i'm about to test it

#

nope that did nothing heh

ebon dagger
#

I'm not sure, but the icons MIGHT have to be in the base texture folder

#

sounds like something that would be required lol.

sly monolith
#

like, the icons work just fine no matter if i leave the Item_ there or not, they appear for the crafting menu both ways

#

another weird thing is i get an error when crafting the tinted version of that item, but the icon appears for it in the bag

ebon dagger
#

Whats the error from console.txt?

umbral raptor
#

is there some form of limit for backpack capcity?

#

i keep trying to make a new backpack 60 but it reverts back to 48 for some reason

sly monolith
bronze yoke
#

backpacks cannot have a higher capacity than 50 in b42

umbral raptor
#

is there a way to bypass this?

umbral raptor
bronze yoke
#

i think there's a mod on the workshop that changes a bunch of the lua to bypass it

umbral raptor
#

do u know its name?

bronze yoke
#

i don't

umbral raptor
sly monolith
vast pier
umbral raptor
#

item Infantry_Backpack_Ground
{
DisplayName = Tactical Infantry Backpack,
DisplayCategory = Bag,
Type = Container,
Weight = 2,
Capacity = 65,
Icon = InfantryBackpack,
AttachmentReplacement = Bag,
BloodLocation = Bag,
CanBeEquipped = Back,
CanHaveHoles = false,
IconsForTexture = Infantry_Backpack_Green,
CloseSound = CloseBag,
ClothingItem = Infantry_Backpack_Ground,
EquipSound = EquipBackpackLarge,
OpenSound = OpenBag,
PutInSound = PutItemInBag,
ReplaceInPrimaryHand = Infantry_Backpack_RHand holdingbagright,
ReplaceInSecondHand = Infantry_Backpack_LHand holdingbagleft,
RunSpeedModifier = 0.95,
WeightReduction = 90,
WorldStaticModel = Infantry_Backpack_Ground,
Tags = IgnoreZombieDensity,
}

#

Did I make any mistakes here?

vast pier
# vast pier

Funny enough, this has the same issue as vanilla engineer. I forgot to captialize Bomb so it doesn't work

abstract cairn
#

does sending a server command end the function? cause for some reason it's not carrying on with the function

sly monolith
sly monolith
ebon dagger
#

Ok, anyone have any thoughts on the following, not from a code perspective, but a how fun would this mod be to use perspective?

I've got my ammo type swapping system mostly finished, but I'm taking a break from it and for the moment I'm doing the fun part and adding all the special types of ammo.

I'm working on "Breaching Rounds". It appears that only melee weapons can hit thumpables.

Which would be more fun:

  • A timed action via context menu that had the character walk up, put a round into the door and bust it up
  • Some sort of collision system that travels out the best it can and trys to find a door to hit within range when you fire a shotgun loaded with breaching rounds?
sly monolith
ebon dagger
sly monolith
hot plinth
sly monolith
#

thanks

umbral raptor
#

i wish someone would make a battering ram

sly monolith
#

i didn't have that file at all cuz before i made the custom icons it was just using the base game ones

umbral raptor
#

like the one used by SWAT

#

would be better than B42's 100 axe swings to take down the police station armory door lol

ebon dagger
#

I'm pretty sure I just saw a mod with that

sly monolith
#

isn't there a c4 or smh in the game? ๐Ÿ˜„

hot plinth
ebon dagger
#

Oh, nm it just has you break doors lol

hot plinth
#

Its good tho, thinking about it for a second made more sense of it for myself, now i can go back and move some models i had seperated for no reason and delete some duplicates. xD

sly monolith
#

yea if you're using base game models/textures you don't need to have those in your mod folder

sly monolith
oak hornet
#

I AM ABSOLUTELY A FUKING DUMBASS, We are talking about the OnCreate funciton defined on in the CraftRecipe.txt files not for generic any crafting done

#

Thanks @bronze yoke @winter bolt , aight gunna find a new workaround now angry

sly monolith
#

actually i'm now getting errors when i try using the static model for glasses with that script heh

#

can someone explain to me what does the "models_clothes" file even do

#
    java.lang.RuntimeException: attempted index: getWorldItem of non-table: null at KahluaThread.tableget(KahluaThread.java:1667).```
#

i guess it's because glasses don't have a world item? i tried looking for any reference to them but couldn't

hot plinth
spiral egret
#

@quartz kindle moving here to not flood the gen chat, but if you have the mod downloaded you can find the sprites in the mod files, they are all 16x16

quartz kindle
#

Ah ok

#

What's the file path? I'm on a mac so things look a little different

spiral egret
#

not home currently so I can't check it either haha

quartz kindle
#

Ah okay

spiral egret
#

my mod doesn't have a lot of files so it shouldn't be too hard to find

#

if you can't find them I'll just send you a zip later or something

quartz kindle
quasi jewel
#

Still haven't figured out why this refuses to work

bronze yoke
#

have you tried referencing it as HCustoms.Bag_EliteCombatMaxGraffiti ?

#

you don't usually need to specify module for script objects in the same module but i've noticed vanilla does anyway

silent zealot
#

I was about to say that

#

I wouldn't be surprised if you can skip "Base" but not other modules.

quasi jewel
#

Assuming I'd need to change this in both ECB_ITems as well as craft scripts?

bronze yoke
#

no, just the craft recipes

silent zealot
#

And if that fails... try just putting the new items in Base.

quasi jewel
#

gonna test

silent zealot
quasi jewel
#

originally tried putting them as base with module HCustoms {
imports {
Base
}

#

thoough prolly didnt do that right ๐Ÿ’€

#

same error

#

this is being a real pain in the ass

umbral raptor
#

I have an issue where an item's icon won't load no matter what I do

quasi jewel
#

huh. new error this time

#

Cannot override existing registry id (5639) to new id (323), item: Base.Bag_EliteCombatMaxSunrise

#

modding for this game has been.. much more annoying than I expected it to be

sly monolith
umbral raptor
#

okay im fucking done with this shit

#

i fix the icon, the model breaks, i fix the mod, the icon breaks

sly monolith
#

what's your problem, maybe i can help, i have some experience with stuff breaking lmao

umbral raptor
#

i change the clothingitem's name from infantry_backpack to infantry_backpack_ground and suddenly the icon works but wearing it shows no model

#

i make it infantry_backpack again and the model is fine and dandy but the icon is broken

#

i can dm u my files if u want

#

maybe u can take a look at tell me whats wrong

sly monolith
#

sure

oblique quiver
#

Heya all! I'm interested in doing some mod development for Zomboid for fun. I know Lua pretty well and I'm grateful for all the great resources provided in the wiki, pinned messages, and this channel. I'm curious about the particular workflow you'd suggest for developing/testing mods: What's your set up in terms of quickly iterating over changes/debugging mods/testing mods. I know how to set up mods, but how do you quickly test them ingame? What does your setup look like for doing the actual development? Thank you!

silent sky
#

has anyone seen this when making vest im new and do not see why my upper torso would disappear when puting on my vest i just made

sly monolith
#

it's probably using some masks that hide it

silent sky
#
    <m_Masks>12</m_Masks>
    <m_MasksFolder>media/textures/Clothes/BulletVest/Masks_BulletVest</m_MasksFolder>
    <m_UnderlayMasksFolder>media/textures/Clothes/BulletVest/Masks_BulletVest</m_UnderlayMasksFolder>
#

i removed this lol

sly monolith
#

yup mystery solved heh

silent sky
#

Made Escape From Tarcov
Airframe
Tv110
BlackJack50

sly monolith
#

ok i solved my own issue, forgot to add "Item_" before the texture name in the texture selector lua ๐Ÿคฆ

tranquil reef
#
if ISMusicVehicleMenu == nil then ISMusicVehicleMenu = {} end

if not ISMusicVehicleMenu.oldShowRadialMenu then
    ISMusicVehicleMenu.oldShowRadialMenu = ISVehicleMenu.showRadialMenu
end

function ISVehicleMenu.showRadialMenu(playerObj)
    ISMusicVehicleMenu.oldShowRadialMenu(playerObj)
    ISMusicVehicleMenu.showRadialMenu(playerObj)
end

function ISMusicVehicleMenu.showRadialMenu(playerObj)
    local isPaused = UIManager.getSpeedControls() and UIManager.getSpeedControls():getCurrentGameSpeed() == 0
    if isPaused then return end
    local vehicle = playerObj:getVehicle()
    if vehicle then
        local menu = getPlayerRadialMenu(playerObj:getPlayerNum())
        local seat = vehicle:getSeat(playerObj)
        if seat <= 1 then -- only front seats can access the radio
            -- print("ISMusicVehicleMenu")
            for partIndex=1,vehicle:getPartCount() do
                local part = vehicle:getPartByIndex(partIndex-1)
                if part:getDeviceData() and part:getInventoryItem() and TCMusic.VehicleMusicPlayer[part:getInventoryItem():getFullType()]then
                    menu:addSlice(getText("IGUI_MusicOptionsCar"), getTexture("media/ui/vehicle_tape.png"), ISMusicVehicleMenu.onSignalDevice, playerObj, part)
                end
            end
        end
        
    end
end


function ISMusicVehicleMenu.onSignalDevice(playerObj, part)
    if not part:getModData().tcmusic then
        part:getModData().tcmusic = {}
        part:getModData().tcmusic.mediaItem = nil
        part:getModData().tcmusic.needSpeaker = nil
    end
    ISTCBoomboxWindow.activate(playerObj, part)
end```
#

This script worked in Build 41, but doesn't in Build 42. No errors, just doesn't show

#

Anyone know any API changes that could be the reason this doesn't work?

slim swan
#

self.character:Say(getText("UI_ElectricWeapon_BatteryRemoved_WithCharge", math.floor(currentCharge)))

#

how to change the word color

umbral raptor
#

What is needed to be added while implementing a new moveable?

#

i made a .pack and a script file for the items

#

as well as translations

#

what else is needed?

#

the items uses vanilla functions such as cooking

#

i editted that in using tilez

umbral raptor
#

the objects currently appear ig but cannot be placed

undone elbow
#

@tranquil reef You can add colors:
```lua
[your code]
```
It will be more comfortable to read.

tranquil reef
ancient grail
#

can i still upload b41 even if ive updated to b42 unstable

bright fog
ancient grail
umbral raptor
#

I need help with a moveable. I made the tiles and pack, script and more files, one of the furniture works, but the other does not and cannot be placed

#

if anyone knows bout adding tiles and such plz dm me

split summit
#

does anyone knows why the size = is not making the worlditem bigger?

tranquil kindle
#

Size?

#

Don't you mean Scale?

split summit
#

Sorry, I did added as Scale =

tranquil kindle
#

Can you paste whole model script?

split summit
#

item TheBagofPortella_Back
{
WeightReduction = 95,
ClothingItemExtra = BagOfHolding_Front,
ClothingItemExtraOption = FannyPack_WearFront,
clothingExtraSubmenu = FannyPack_WearBack,
Weight = 1.5,
Type = Container,
Capacity = 80,
DisplayName = The Bag of Portella,
Icon = BagOfHolding,
WorldStaticModel = BagOfPortella_WorldItem,
Scale = 0.2,
PutInSound = PutItemInBag,
BodyLocation = FannyPackFront,
ClothingItem = Bag_FannyPackFront,
CanBeEquipped = FannyPackFront,
ToolTip = Portella,
}

tranquil kindle
#

That's not how it works

split summit
#

Everything works, like icon, item, worldstatic etc, just can resize haha

tranquil kindle
#

You need separate model script and put scale there.

#

Is that vanila model?

split summit
#

would that be
Model TheBagofPortella_Back
{

split summit
winter bolt
#

it needs to be in BagOfPortella_WorldItem

split summit
tranquil kindle
#

So that means you need new model script with model and texture assigned, and then use scale

#

Did you override texture?

split summit
#

I didn't, this is the only script i have

tranquil kindle
#

Because from what I can see you did not made model script.

#

Wait it's clothing item...

winter bolt
#

WorldStaticModel = BagOfPortella_WorldItem, is pointing to a model script called BagOfPortella_WorldItem

#

thats where you need to put the scale

split summit
split summit
winter bolt
#

yeah

#

if you look in the vanilla game media/scripts/models_items.txt you can see what it should look like

#

you wont need to put a texture in the model though because clothing items have that set automatically

tranquil kindle
#

He did mention that he doesn't need new texture on clothing, so he needs to specify texture in model script

split summit
#

Hm, so I understand until the part that I have to create a model script, but didn't get it about the texture cloathing etc

#

the Model should be the name of my item or the texture file?

module Base
{
Model

tacit pebble
#

Can someone confirm this is a bug or something??

function CF_RemoveCache(character, item)
    print(item)
    --item:setWeight(item:getWeight())
end

Events.OnEquipPrimary.Add(CF_RemoveCache)
LOG  : Lua          f:161, t:1737473158362> nil
LOG  : Lua          f:161, t:1737473158363> Base.KitchenKnifeForged:zombie.inventory.types.HandWeapon@11e44d4
LOG  : Lua          f:293, t:1737473160563> nil
LOG  : Lua          f:293, t:1737473160564> Base.BaseballBat:zombie.inventory.types.HandWeapon@5833ac9e

I tried twice (Bare Hand -> Kitchen Knife -> Baseball Bat)
and 4 lines were printed, i have no idea why nil is there.

winter bolt
main pasture
tacit pebble
#

I mean, KitchenKnife -> BaseballBat also printed

LOG  : Lua          f:293, t:1737473160563> nil
LOG  : Lua          f:293, t:1737473160564> Base.BaseballBat:zombie.inventory.types.HandWeapon@5833ac9e

so do they basically do this
knife -> hand -> bat

#

oh

#

it makes sense..

winter bolt
#

yeah the character puts away the weapon and then equips the new one

tacit pebble
#

but still i don't understand because event is OnEquipPrimary so bare hand is not something that can be equipped i think??

split summit
main pasture
#

dropHandItems() for example does setPrimaryHandItem((InventoryItem)null) (setPrimaryHandItem() triggers OnEquipPrimary)

jovial kindle
#

If I wanted to add a metalworking recipe where could I do that?

quartz kindle
#

Hey @spiral egret by any chance are you able to get those PNGs to me?

spiral egret
#

yep nice timing lmao, I tried to message you just now but your DMS are closed

quartz kindle
#

oh shoot sorry

#

I have it set to friends only

#

ill change it

#

Try now?

#

@spiral egret

unique harbor
#

How do you update a mod without overriding the workshop description?

vast pier
#

Oh hey! Nail grenades are in the Improvised Munitions Handbook

#

neat

bright fog
vast pier
bright fog
vast pier
#

It's a official us military handbook regarding manufacturing explosive material & propellents, along with improvised grenades and bombs.
Written in 1969

bright fog
#

yea I checked it out

vast pier
#

Declassified as part of the freedom of information act

bright fog
#

guessed so yea

vast pier
#

I have a pdf of the handbook if you want, I'm looking through it as reference for possible weapons to add in a mod ๐Ÿ‘

bright fog
#

I already found it lol

vast pier
#

nice

#

Page 75 is the nail grenade

vast pier
#

as neat as it would be to have a directional bomb that you set down and ignite to kill zombies in front of you, I'm not sure of a way to have the damage be a cone instead of a full circle

vast pier
#

yeah but I wouldn't know how to attach that to the grenade's damage in any way

bright fog
dull moss
#

How can one play a sound withot a regard if player is in-save (aka has character). I know you can play a sound with
player:playSoundLocal("name"); but how does one play it without player?

bright fog
#

Some shit like that

#

Give me a sec, I'll find a better example

#
        local emitter = getWorld():getFreeEmitter()
        local square = door:getSquare()
        emitter:playSoundImpl("DoorCreek"..tostring(ZombRand(1,16)),square)
#

With the string, your sound script

dull moss
#

i dont think that would work in main menu, no?

dull moss
#

ye that's what im saying

bright fog
#

For that, check the main menu music framework

bronze yoke
#

getSoundManager():PlaySound()

dull moss
bright fog
bronze yoke
#

actually use playUISound

#

PlaySound won't play on the main menu for whatever reason

bright fog
bronze yoke
#

nothing i think

bright fog
#

Bcs I set custom emitters for my zombies, however when they die, sometimes the emitter continues to play

#

Yet

#

When zombie dies

#

I stopAll its emitter

#

I think I just fixed it by checking OnTick if the zombie is dead and forcing it to stopAll

#

nah nvm

dull moss
#

so I'm using this as template, anyone knows why it crashes my modOptions?

local ETW_config = {
    ...
    SoundNotificationSoundSelectComboBox = nil
}

local function ETWConfig()
    local options = PZAPI.ModOptions:create("ETWModOptions", "ETW - Evolving Traits World")
    options:addTitle("Evolving Traits World")

    ETW_config.SoundNotificationSoundSelectComboBox = options:addComboBox("SoundNotificationSoundSelect", getText("UI_ETW_Options_SoundNotificationSoundSelect"),"")
    ETW_config.SoundNotificationSoundSelectComboBox:addItem(getText("UI_ETW_Options_Sound_B42"), true)
end

ETWConfig()

Intelisense not picking up addItem as existing thing

bright fog
#

You'll find better explanation of mod options

#

OOoh

#

nah nvm

#

Usually a crash of mod options tend to be linked to an empty string box

#

But you're not using these here anyway

bronze yoke
#

what do you mean by 'crashes my mod options'

dull moss
#

๐Ÿ‘

bright fog
#

Fixed now

dull moss
#
    java.lang.RuntimeException: No implementation found at MultiLuaJavaInvoker.call(MultiLuaJavaInvoker.java:112).
    Stack trace:
        se.krka.kahlua.integration.expose.MultiLuaJavaInvoker.call(MultiLuaJavaInvoker.java:112)
        se.krka.kahlua.vm.KahluaThread.callJava(KahluaThread.java:192)
        se.krka.kahlua.vm.KahluaThread.luaMainloop(KahluaThread.java:988)
        se.krka.kahlua.vm.KahluaThread.call(KahluaThread.java:173)
        se.krka.kahlua.vm.KahluaThread.pcall(KahluaThread.java:1963)
        se.krka.kahlua.vm.KahluaThread.pcallvoid(KahluaThread.java:1790)
        se.krka.kahlua.integration.LuaCaller.pcallvoid(LuaCaller.java:66)
        se.krka.kahlua.integration.LuaCaller.protectedCallVoid(LuaCaller.java:139)
        zombie.Lua.Event.trigger(Event.java:81)
        zombie.Lua.LuaEventManager.triggerEvent(LuaEventManager.java:281)
        zombie.gameStates.MainScreenState.enter(MainScreenState.java:359)
        zombie.gameStates.GameStateMachine.update(GameStateMachine.java:135)
        zombie.GameWindow.logic(GameWindow.java:372)
        zombie.core.profiling.AbstractPerformanceProfileProbe.invokeAndMeasure(AbstractPerformanceProfileProbe.java:76)
        zombie.GameWindow.frameStep(GameWindow.java:917)
        zombie.GameWindow.run_ez(GameWindow.java:810)
        zombie.GameWindow.mainThread(GameWindow.java:610)
        java.base/java.lang.Thread.run(Unknown Source)
LOG  : General      f:0, t:1737487789063> -----------------------------------------
#
-----------------------------------------
Callframe at: se.krka.kahlua.integration.expose.MultiLuaJavaInvoker@793dbd07
function: addModOptionsPanel -- file: MainOptions.lua line # 3582 | Vanilla
function: create -- file: MainOptions.lua line # 645 | Vanilla
function: instantiate -- file: MainScreen.lua line # 718 | Vanilla
function: addToUIManager -- file: ISUIElement.lua line # 1138 | Vanilla
function: LoadMainScreenPanelInt -- file: MainScreen.lua line # 2149 | Vanilla
function: LoadMainScreenPanel -- file: MainScreen.lua line # 2058 | Vanilla```
bright fog
#

That error looks like a classic error I had, tho I don't remember the exact reason

dull moss
#

WAit I have to add to ID

bronze yoke
#

i don't know if this would cause it but why do you have a combo box with only one option?

dull moss
#

it's one of many

#

or wait

#

huh

bright fog
#

also why put that in a function ?

#

just curious

dull moss
#

idfk, dhert was first one to figure new options so I jsut followed his stuff KekW

bright fog
#

Check the Mod Options

#

wiki page

dull moss
#

yea checking it now

bright fog
#

It's the result of all the researches others did, and my own on the subject

#

It should detail everything you need to know

#

Tho don't hesitate if you think something could be added

hot plinth
#

Can I make this like.... not 1 ugly line?
item 1 [Base.Basil;Base.BlackSage;Base.Plantain;Base.Broccoli;Base.Cabbage;Base.Carrots;Base.Cauliflower;Base.Chamomile;Base.Chives;Base.Cilantro;Base.Corn;Base.Comfrey;Base.CommonMallow;Base.Garlic;Base.Greenpeas;Base.Hops;Base.Kale;Base.Lavender;Base.Leek;Base.Lettuce;Base.Marigold;Base.Onion;Base.Oregano;Base.Parsley;Base.RedRadish;Base.Rosemary;Base.Roses;Base.Sage;Base.Soybeans;Base.Spinach;Base.SweetPotato;Base.SugarBeet;Base.Thyme;Base.Tobacco;Base.Turnip] flags[AllowRottenItem] mappers[map1] mode:destroy,

bright fog
#

Tags maybe ?

#

If vegetables have tags that can be used

#

Doesn't look like it sadly

hot plinth
#

its only for items that aren't in the basegame collect seeds recipe, so if i dont think theres a tag that would capture all this stuff but not double up the base recipe. Oh well, guess ill just have to deal with it.

bright fog
#

I think these vegetables are not supposed to have seeds lol

#

Maybe a function idk

hot plinth
#

Yeah they aren't, its not ment to make sense but getting seeds from everything was popular enough in 41 so I redid it for 42 stuff.

bronze yoke
#

you can't use functions for these anymore

bright fog
#

๐Ÿ‘Œ

bright fog
#

That's so stupid

bronze yoke
#

in vanilla it was only used for tags anyway so they don't need it anymore

hot plinth
#

They must be working for the ultra wide screen companys ๐Ÿ˜ญ

bright fog
slim swan
#

Any documents for modding ui?

dull moss
#

Just pain and suffering

hot plinth
#

If I do something to add a tag to all the base veggies etc i want to include will that conflict with other mods that touch the same items, like will we just overwrite each other in the load order?

bright fog
#

Idk how good it is tho

#

I plan on making that damn wiki page but that requires a lot of time for me to test stuff out, learn how to make UI and make a proper wiki page

#

But that looks like a decent guide from a quick glance

slim swan
#

Thanks!

#

B42 code is so different compared to B41

bright fog
#

Not really

#

Tho in terms of UI idk

vast pier
ebon dagger
#

Anyone know if there is a flag or option or whatever in the Recipe syntax to require a magazine to be empty?

I don't think anything in vanilla requires this... but I can hope.

ebon dagger
#

Oh, just thought about Recipe.OnTest. I might be able to do it there.

knotty stone
#

so the update killed all mods with recipes? anyone knows what changed?

#

java.lang.Exception: unknown recipe param: itemcount at InputScript.Load(InputScript.java:545).

#

ok without -debug i can atleast get in but its throwing errors like hell.

ebon dagger
#

The Exhausted moodle now looks LESS like an anime wifu in heat.

silent sky
#

Hey guys me and my buddy were trying to retexture some cars for fun and realized that somewhere there is a script randomizing the color instead of using a texture for the body any ideas where i should look to make it just use the texture we create

knotty stone
#

in vehicle

     {
         texture = Vehicles/texturename,
     }```
silent sky
knotty stone
#

if you have one declared it will only use this

winter bolt
#

my biggest complaint is how desaturated all of the new moodles are so im glad they made them more colourful

#

i love this one lol

pearl prism
#

How do I configure the distribution for an item spawns in large quantities?

tacit pebble
#

function IsoAnimal:checkForChickenpocalypse() end
LOL

silent sky
# knotty stone if you have one declared it will only use this
module MoreBags
{
        item Blackjack50
    {    
        WeightReduction    =    75,
        Weight    =    1.5,
        Type    =    Container,
        Capacity    =    80,
        DisplayName    =     Blackjack50,
        DisplayCategory = Bag,
        CanBeEquipped = Back,
        IconsForTexture = penetratoricon,
        OpenSound   =   BackpackOpen,
        CloseSound   =   BackpackOpen,
        PutInSound   =   PutItemInBag,
        ClothingItem = Blackjack50,
        BloodLocation = Bag,
        RunSpeedModifier = 0.94,
        AttachmentReplacement = Bag,
         CanHaveHoles = false,           
        ReplaceInSecondHand = Blackjack50_LHand holdingbagleft,
        ReplaceInPrimaryHand = Blackjack50_RHand holdingbagright,
        WorldStaticModel = Blackjack50_Ground,
        }        
        {
            texture = Vehicles/texturename,
        }
}
#

would this be how i would add multiple textures to my item

knotty stone
#

thats an item not a car^^

#

but yea its in the right place

silent sky
#

as well

silent sky
#

so change vehicles to this??

knotty stone
#

texture= is already accessing the textures folder

silent sky
#

last time i ask soo this is good thank you for your help

#

?

knotty stone
#

yea

silent sky
# knotty stone yea

trying this method because my other one did not work for the bags but it did for vest

#

where i duplicated the texturechoices on my vest and it worked

#

well added multiple lines

knotty stone
#

yea but you wrote at first about car textures, so i thought it was about that. for clothes i dont know if that works, sry.

tacit plover
knotty stone
#

thank you @tacit plover

tacit pebble
#

guys, did they change something with itemcount ?

tacit plover
tacit pebble
#

unknown recipe param: itemcount
my game is crashing and i've removed them one by one

#

oh

#

thank you ๐Ÿ™‚

bright fog
tacit pebble
#

btw so, unless I unsubcribe them manually, my game will keep crashing right?
why didn't they improve this ๐Ÿ˜ญ

bright fog
#

So I can add that in the wiki too

tacit pebble
tacit plover
tacit plover
bright fog
#

so instead of itemcount it's now flags[ItemCount] ?

tacit plover
#

your game wont crash instantly, then you can just update your mod

bright fog
tacit pebble
#

thank you again anyway โค๏ธ

silent sky
tacit plover
#

but, you'll lose your debug tools

tacit pebble
tacit plover
#

wish there was a way to disable it tho

bright fog
#

This might interest you, I think that's the flags for the crafting

#

Changes to the crafting flags

tacit plover
silent zealot
tacit pebble
silent sky
#

anyone have any ideas why this method of adding multiple textures to my bag would work for my vest mod but not my bags

#

added it to each xml too

#

really trying to make multiple bags just for the texture

vast pier
#

Failed to load asset: AssetPath("CanadeModel)
How is it failing? It's the same model that you see on the ground in the screenshot?

    {
        DisplayName = Can Bomb,
        DisplayCategory = Explosives,
        Type = Weapon,
        Weight = 1.5,
        Icon = Canade,
        ExplosionPower = 90,
        ExplosionRange = 7,
        ExplosionSound = PipeBombExplode,
        MaxDamage = 0,
        MaxHitCount = 0,
        MaxRange = 10,
        MinDamage = 0,
        MinimumSwingTime = 1.5,
        PhysicsObject = CanadeModel,
        PlacedSprite = constructedobjects_01_32,
        SwingAmountBeforeImpact = 0.1,
        SwingAnim = Throw,
        SwingSound = PipeBombThrow,
        SwingTime = 1.5,
        Tooltip = Tooltip_Trap,
        UseSelf = TRUE,
        WorldStaticModel = CanadeModel,
        WeaponSprite = CanadeModel,
    }```
model CanadeModel
{
    mesh = weapons/Canade,
    texture = weapons/Canade,
    scale = 0.35,
}```
#

don't understand why it's registering the model for worldstaticmodel but not WeaponSprite?

#

haven't had this issue with weapons before

tranquil reef
#

if a java variable is declared as public, do I still 100% need a setter function to affect it in lua

bright fog
#

If the field is exposed, you can access it

tranquil reef
#

this doesn't work. am i missing something blatantly obvious or is it not possible

bright fog
#

You can't do that

bronze yoke
#

kahlua doesn't expose fields

bright fog
#

You need a setter for that

tranquil reef
#

I figured

#

TIS exposing every value needed for custom animals besides the one that makes hostile animals possible

winter bolt
tranquil reef
#

There's a function that you can call to have the animal fight something, but it moves to you and then doesn't do the attack since it still depends on that attack timer lol. There's also an "attack time" variable in the animal definitions but that does nothing

#

Hoping they just forgot to make those two affect the same function rather than, the animal definitions one does something mundane and they have no plans to expose anything else

winter bolt
#

im assuming PhysicsObject is the one that needs a model path but ive never touched weapons so i have no clue

bronze yoke
#

isn't physicsobject just a texture

winter bolt
#

oh yeah i guess its looking for a texture path then

quiet plank
#

how would I go about ensuring a gas can is empty before use in a recipe? or - better still - is there a way to get the fluid mixing system to produce a new item?

#

oh - found something that does similar. Looking in

vast pier
#

no because it's not showing in my hand, and changing the weapon sprite makes it show the different weapon model

#

also it's displaying the model when throwing it, which is what PhysicsObject seems to handle

vast pier
winter bolt
#

oh wtf

bronze yoke
#

that's what that error indicates either way

#

something is looking for a file called CanadeModel

winter bolt
#

might just have to change each one until you narrow it down

vast pier
#

It's weaponsprite, I know because if I change it then it doesn't spit out the error

#

also cuz it's loading the ground and projectile model, but not in hand

#

Maybe it's because it's a throwable weapon specifically?

#

Lemme try something

pearl cobalt
#

Lil warning to modders, to anyone whom as a recipe mod in B42, last update broke compatibilities with mods with recipes

#

It'll cause a script loading error that makes the games unlaunchable

#

they changed the property "AutoLearn" to "AutoLearnAny", if that can help

#

thus making a parsing script error

silent zealot
#

and for some reason you can load in normal mode (with errors) but teh game will crash in debug mode.

#

So load in normal mode, disable mods that have recipies, then you can start in debug mode.

pearl cobalt
#

the item count?

sly monolith
#

did they intentionally make all crafting recipes the same color in that b42.1 update, no matter if you have the required materials or not?

hot plinth
lusty yoke
silent zealot
#

To put a positive spin on things: we now have a good example of why the new folder structure exists when people ask about it! Separate recipe files for B42.0.2 and B42.1.0 are possible.

silent zealot
lusty yoke
#

*gives a thumbs up, through tears*

pearl cobalt
#

it's alright... just like B41 to B42

silent zealot
#

I am glad they are still working on the core recipe stuff, just would have been nice to not crash the game when parsing a recipe from yesterday.

hot plinth
#

yeah only 2 mods ive got used itemcount anyway so simple fix for me until they fix themselves.

pearl cobalt
silent zealot
brittle geyser
#

hey all how can I move really fast in debug mode?

pearl cobalt
#

Oh, it's on the wiki ! never thought of looking about it there, i meant the actual changelog of the update

#

thanks

lusty yoke
#

okay, so. theoretically, if i go into the script files of any mods that have AutoLearn or itemcount, and change them to the new scripts, would it fix it?

hot plinth
#

i did that for itemcount and got 2 working so yeah, not sure of autolearn but probably.

pearl cobalt
#

If your recipes are totally custom i'd say it's a good start

silent zealot
lusty yoke
#

it'd be a simple find and replace, right? okay let's see how this goes nerd

pearl cobalt
#

mine are fixing the actual game recipes, so i'm currently going through every fixed recipes and looking line by line what changed

pearl cobalt
#

to me, to know for future updates

hot plinth
#

yep, just do a replace in every recipe script then run the game to see if you missed any. run from bat or chexk the console.txt after to try pinpoint which recipes are still borked

vast pier
#

wth

bronze yoke
#

that would imply it's trying to load a file called "CanadeModel

#

i don't really get how it could get that from anything you've written

vast pier
#

I think it's an issue with thrown weapons specifically, as in b41 all throwables just used the molotov model

#

swapping the weaponsprite with PipeBomb works perfectly fine, I don't understand what is different between the vanilla model and mine?

#

I haven't had this issue with melee weapons

lusty yoke
#

all recipe mods seemingly fixed, just by doing a simple search and replace c_clapfrog (went through and fixed everything i had from the workshop, by just using windows search in workshop folder for itemcount and AutoLearn and then used notepad++ to find/replace all instances with the new terms flags[ItemCount] and AutoLearnAny) though since it's a simple fix, i guess they'll get updated by the mod authors themselves soon enough

bright fog
vast pier
distant inlet
#

hi everyone! I'm new to modding PZ. I was wondering if anyone knows how to hot reload Lua scripts to test changes. I'm testing a few methods now and update with my findings any case zombie

bronze yoke
#

you can reload files from the debug menu (f11, on the right)

distant inlet
#

ty

bright fog
#

Community debug tools also make it a bit easier to reload multiple files, and not have to constantly search the file you want to reload

silent zealot
vast pier
#

I don't even think I could fix it

#

Nothing is visually wrong, and the error doesn't even make sense

#

๐Ÿ˜ตโ€๐Ÿ’ซ

sly monolith
#

jfc, i have a new issue with my mod, everything worked just fine, and now it doesn't again, and this time there's literally nothing different about one item or another, but one is working as intended, and the other one picks texture at random

vast pier
#

We love mysterious inconsistent bugs

sly monolith
#

seriously what's wrong with this thing ๐Ÿ˜ญ local maskRedTex = getTexture("media/textures/Item_FaceMask_Red.png") local maskBlkTex = getTexture("media/textures/Item_FaceMask_Black.png") local maskWhtTex = getTexture("media/textures/Item_FaceMask_White.png") this is the lua part for a mask, local skrtRedTex = getTexture("media/textures/Item_Skirt_Tiny_Red.png") local skrtBlkTex = getTexture("media/textures/Item_Skirt_Tiny_Black.png") local skrtWhtTex = getTexture("media/textures/Item_Skirt_Tiny_White.png") this is for the skirt, they are copy paste the same thing just with changed names, and the skirt one doesn't work

winter bolt
#

try testing using the mask textures for the skirt and seeing if it still happens

mellow frigate
#

That small update on moodles made me sweat anyway zombie

sly monolith
winter bolt
sly monolith
#

wdym

winter bolt
#

for setting the item texture

sly monolith
lusty yoke
#

a few mods have been flagged up as incompatible with b42 despite being, you know. compatible. is there any straightforward fix for this? i've seen a couple of options (changing the mod.info file, redoing the common/42 folder structure) but so far nothing seems to work

#

it does say they're only available in debug mode but they don't seem to load in even when activated e_think

winter bolt
# sly monolith

does the skirt item use a model or a texture on the character?

sly monolith
winter bolt
#

found it

#

in the skirt functions replace setTextureChoice with setBaseTexture

bronze yoke
sly monolith
#

i dont know how those functions work cuz i dont know lua at all

winter bolt
#

its because clothing items use basetexture for items on the character model but texturechoice for modelled items

#

it trips me up all the time lmao

sly monolith
#

i also get an error when crafting a tinted version of the skirt, i have this line in the crafting script OnCreate = Recipe.OnCreate.InheritColorFromMaterial,, i copy pasted it from the base game skirt

sly monolith
#

it's something about inheriting color from material

#

and the thing is it works just fine, it just gives an error

winter bolt
#

im not at my pc so im not able to check it rip

#

weird

sly monolith
#

i would guess it could have something to do with skirt i'm using as a base is lets say black, but the thread is lets say red?

#

the new skirt turns black like the old one

floral patio
#

With the new major patch for B42, is the HitChance field in the items_weapons_firearms.txt file now repurposed to the chance to damage? If not, where can I find the damage chance values?

sly monolith
gaunt meteor
#
function ISCharacterScreen:hairMenu(button)
    local player = self.char;

if player:isFemale() then
        hairMenu:addOption("Grow Long", player, ISCharacterScreen.onCutHair, "Long2", 10);
    else
        hairMenu:addOption("Grow Long", player, ISCharacterScreen.onCutHair, "Fabian", 10);
    end
end

this is a shortened version of the whole code, but its this part in particular that i wanted to ask about. in the beard menu function ive been able to add "Grow Beard" to the longest setting but I havent been able to get "Grow Long" (hair) to work (the above code)

no matter what I do, it won't show in the hair cut menu, i've made sure that no other mods are overwriting it, so i wonder where im going wrong?

its for MP server btw, i dunno if that changes how player = is

outer crypt
#

heard that a lot of recipes broke after the new update, any info on what broke them?

outer crypt
#

interesting, the one it is flagging on launch for me only has a single item in and out

oak hornet
#

Your Honor, I Pledge "Oopsy Daisy"

autumn sierra
#

anyone know how to set snow on the ground in debug mode?

outer crypt
#

Not sure but you might be able to start a blizzard in the climate debugger shrug

#

Looks like plumbing changed too. :/

bronze yoke
#

plumbing has not worked in any version of b42

jolly epoch
#

what do I need to do to add a tile in the game as a crafting station

#

as in workbenches

hot plinth
#

probably a tag but dont look at me i dont know anything ๐Ÿ™‚

umbral ingot
#

@tacit pebble
"- If it is too dark to read but the character is inside a vehicle it will be possible to read as long as the vehicle's battery has charge." - 42.1.0

Shortest mod life span speed run ๐Ÿ˜†

bright fog
#

If it's winter, ability to set snow on stuff or some shit like that

#

But general, for everything

tacit pebble
bright fog
umbral ingot
#

Hell yeah, my next idea is turning open truck beds/car hoods/etc in craft surfaces so gonna look into how they make those

#

What one is that?

bright fog
bright fog
tacit pebble
bright fog
#

I believe the check for surfaces is hard coded. However you might have to plug into the crafting UI directly

bright fog
tacit pebble
umbral ingot
#

Yeah my naive idea was use the mechanics area checks to force allow a a craft if I can

bright fog
#

Force craft is weird

#

Sometimes it just straight up doesn't even craft

round thorn
#

If someone is around and able I could use some assistance. I am trying to setup LuaCAT, and using VS code, but when I open the Lua Addon Manager and search for Umbrella, nothing show up, in fact nothing shows up at all it just says "nothing to show" not sure if I am doing something wrong, simply following the instructions from git page.

#

ah wait, it finally decided to show.

quaint warren
#

Hey CBF, I know your discussion on this topic is over 2 years old, but it's digging in the exact area I'm looking.

I'm trying to fix a bug with one of the broadcast codes at runtime (so I don't have to replace the entire RadioData.xml file, which would be extremely fragile when the game is updated).
Any idea if this is possible or the data structure which contains the line entries isn't exposed and thus can't be modified at runtime?

The more I look at this the less I think it's possible.

bright fog
round thorn
#

its working just took way longer than I expected.

bright fog
#

Yea

#

Same for unstable

round thorn
#

No clue if what I am working on will work, but we will see I suppose.

bright fog
#

It takes longer than the stable version to load in the list

quick forge
quick forge
round thorn
#

is there an API reference somewhere?

coarse sinew
quick forge
coarse sinew
quick forge
#

thanks a lot ! spiffo very good mods

tiny valve
#

Can I ask for help?
I'm trying to make a translation of a mod, but I'm getting strange characters in the text. What is this related to? How can I fix it?

jaunty marten
quick forge
bright fog
quick forge
split summit
#

Is it necessary a texture or can I test it with mesh = and my 3d model first?

coarse sinew
quick forge
quiet glacier
#

Hello all!

Is there a mod that tells you which track is currently playing? I want to replace the soundtrack in Zomboid but I'm unsure of which tracks are unused or not.

quiet glacier
#

Thanks, spongie! I'll give it a try.

sterile path
#

random question how would i go about reverting the butter changes for shits and giggles
i never got to exploit the glitch

sterile path
#

i've never modded before

#

at least zomboid

ornate sand
#

Has anyone checked if the AnimSet system works now?

frank elbow
# undone elbow B41 - ANSI B42+ - UTF-8

Is this true yet, for B42? I don't see any changes in the Translator class that would indicate this is already the case (unless I'm missing something elsewhere)

#

I remember nasKo reacted with a checkmark when someone asked if it would be done, but I thought they were still using the old encodings as of now. I'm doing mod development on B41 still (because multiplayer) so I haven't checked ingame

undone elbow
frank elbow
#

Ah, didn't check the actual languages. Good to know, thanks!

#

Argentinian Spanish, Catalan, Czech, and Korean were left out ๐Ÿค” Hopefully those are updated at some point too

frank elbow
#

The files for the languages I mentioned suggest otherwise

ornate sand
#

Looks like you need the mod_support channel.
This one is for developing mods.

ember crystal
#

misclick ๐Ÿ˜ข

vast pier
#

- Lowered the amount of zombies in the Forest by 5
Five what? Five individual zombies were removed?

tacit mauve
#

They were bad zombies

vast pier
dull moss
tulip valve
#

Has anyone figured out how to make a new item act like Whistle/Harmonica and add new sounds when using/equiping the item?

Harmonica has something called ShoutType = BlowHarmonica, I thought it had to be a sound script somewhere but I can't find, looked around in the lua folders too, didnt find anything

vast pier
# bright fog /5 lol

I like to the think the devs personally join your game, run into the forest, shoot five zombies, then leave.

dull moss
#
---Adds xp boosts from a trait to a player
---@param traitName string
local function addXPBoostsFromTrait(traitName)
    local player = getPlayer();
    local trait = TraitFactory.getTrait(traitName);
    local xpBoostMap = trait:getXPBoostMap();
    if xpBoostMap then
        print("--------  XP Boost Map: ", xpBoostMap, type(xpBoostMap));
        local table = transformIntoKahluaTable(xpBoostMap);
        print("--------  XP Boost Map (table): ", table, type(table));
        for perkName, boostLevel in pairs(table) do
            print("-------- applying boost to traitname: ", perkName, " boostLevel: ", boostLevel);
            local perk = PerkFactory.getPerkFromName(tostring(perkName));
            local currentBoost = player:getXp():getPerkBoost(perk);
            local newBoost = math.min(currentBoost + tonumber(boostLevel), 3);
            ---@cast newBoost integer
            player:getXp():setPerkBoost(perk, newBoost);
        end
    end
end
java.lang.RuntimeException: __add not defined for operands in addXPBoostsFromTrait at KahluaUtil.fail(KahluaUtil.java:82).

?????

#

local newBoost = math.min(currentBoost + tonumber(boostLevel), 3);

#

I literally convert it to number

fleet bridge
#

print boostLevel

dull moss
#

check above

#

all correct

#
--------  XP Boost Map:     {Doctor=1}    userdata
--------  XP Boost Map (table):     table 0x1027227740    table
-------- applying boost to traitname:     Doctor     boostLevel:     1
#

boostLevel is type userdata

#

local newBoost = math.min(currentBoost + tonumber(tostring(boostLevel)), 3)

#

it's funny sometimes

#

I pretty much never done scripts, I can list multiple entries, right?
like

module Base
{
    sound ETW_b42
    {
        category = Player,
        clip
        {
            file = media/sound/levelup.wav,
        }
    },
    sound ETW_b41
    {
        category = Player,
        clip
        {
            file = media/sound/b41.wav,
        }
    },
    ...
}
bronze yoke
#

of course

dull moss
#

ah, supposed to be no comma

#

I don't think getSoundManager():playUISound(str); is workign in main menu unless I'm doing something wrong PepeThink

#
local buttonFunc = function(_,button)
    local soundTable = {"ETW_b42", "ETW_b41", "ETW_TLOU", "ETW_SkyrimSkill", "ETW_SkyrimLevel", "ETW_Oblivion", "ETW_Diablo2", "ETW_Witcher3", "ETW_FalloutNV", "ETW_AoE3", "ETW_WoW"};
    local idx = SoundNotificationSoundSelectComboBox:getValue()
    local str = soundTable[idx]
    print(str)
    getSoundManager():playUISound(str);
end

I have this func that fires when button in mod options is pressed

#

It correctly prints which string it should play

#

but it aint playing anything PepeLaugh

bright fog
dull moss
#

oh wait

#

maybe it aint playing because category = player ?

bright fog
#

no idea

#

idk what category is

dull moss
#

neither do I KekW

bright fog
winter bolt
#

i think category is for volume grouping

dull moss
#

Oh ye you're right

winter bolt
#

the advanced volume screen uses them for the tabs but thats inaccessible now without mods so it might just be unused?

dull moss
#

hm I'm looking at playUISound used in game code and it looks fine, idk why it doesn't work on my end confus

vast pier
winter bolt
dull moss
#

already did

#

and reloaded the game

winter bolt
#

oh nvm i didnt see

#

if you try playing a vanilla sound does it work?

dull moss
#

which one as example?

vast pier
dull moss
#

can it be because pressing button plays a vanilla sound?

#

And sound manager can only play 1 maybe? idk

winter bolt
#

maybe the sounds need category = UI,?

#

all the vanilla ui sounds have it

dull moss
#

I tried using vanilla "UIObjectMenuObjectPlace"

#

it didnt play

tulip valve
#

is there anyway to make a recipe replace a vanilla recipe?

#

in b42

vast pier
#

Unless yesterday's patch changed it, don't think so

#

not intentional, just a bug from the new crafting system

tulip valve
#

well that sucks

bronze yoke
#

technically you can override the entire file it's defined in

vast pier
#

Ah right, forgot about the whole Capgras solution

#

I prefer to avoid overwriting as much as possible, but sometimes you just have to

tulip valve
#

Yeah for the recipes it seems you have to

dull moss
#

I think my sounds are straight up not loaded

unique harbor
#

Is there an alternative debugger instead of the F11 thing?
I'm seriously starting to loose brain cells trying to figure stuff out

dull moss
#

Is there a way to somehow check im my sounds are loaded into the game?

unique harbor
#

Awesome

winter bolt
silent sky
#

When people make cars do they not use guids

bronze yoke
#

no

spare burrow
#

Anyone knows if a skill book can give experience multipliers to two skills? and if not, is there a way to give experience multipliers via on-use?

pearl prism
#

Does anyone know how I can make that the clip of my gun spawn is already loaded?

winter bolt
silent sky
#

What is the common folder for?

winter bolt
elfin hamlet
#

Professional software engineer here. Looking to work together with an experienced modder as I've never modded pz before; however, I have experience modding DayZ and I know a functional amount of Lua & Java.

unique harbor
#

Is there a lua version of continue? Need it for a for loop

bronze yoke
#

no

#

you can do this bullshit if you really want to:```lua
for i = 1, whatever do
repeat
-- put the entire loop body in here
-- in this scope, break behaves like a continue
until true
end

errant bluff
#

what kind of animation would correspond when the zombie falls to the ground when pushed by the player?
I want to track when a player's push to the zombie is successful if that animation is triggered, otherwise, if he pushes and does the other animation, the one where he goes back a few steps, don't register anything.

unique harbor
bronze yoke
#

no, the repeat block will only happen once per loop no matter what

#

since the condition to terminate it is always true

unique harbor
#

Ohh yeah... I totally misunderstood that, thx xD

#

You want to order the container btns which are interestingly called backpacks?
Floor: I don't think so.

Now I understand why that one guy just took the whole Inventory Page and overwrote it

mellow frigate
#

Hello there, what should I do when PZ warns my about my vehicles parts-containers with logs like: "ItemPickInfo -> cannot get ID for container" ?

#
ItemPickInfo -> cannot get ID for container: ATAInteractiveTrunkFront
bright fog
#

I write it this way

for i = 1, whatever do repeat
    -- put the entire loop body in here
    -- in this scope, break behaves like a continue
until true end
#

So it's better to read

bronze yoke
#

i agree you should probably do it that way but i like to write it out on separate lines when showing it to people for the first time since it's a lot easier to figure out what it's doing

bright fog
#

That's fair

vocal vector
#

i'm trying to remove an event but it still fires; maybe because it is a local function?

bright fog
#

That can be a problem

bronze yoke
#

if you want to remove an event listener you need to have a reference to the listener

#

if it's a local in another file you can't get it very easily

vocal vector
#

it looks like this
Events.OnHitZombie.Remove(OnHitZombie)
Events.OnHitZombie.Add(OnHitZombieAddOptions)

#

but now both are firing

bright fog
vocal vector
#

no, thats the issue

#

it's a local function in a different file

bronze yoke
#
local old_add = Events.OnHitZombie.Add
Events.OnHitZombie.Add = function() end
require("path/to/other/file") -- e.g. require lua/shared/MyFile.lua as require("MyFile")
Events.OnHitZombie.Add = old_add
#

this will prevent the file from adding any listeners to that event

#

your file needs to run before the original file, that can be done by making it earlier alphabetically in b41 or by mod load order in b42

vocal vector
#

It won't work to use remove the same way?

bright fog
#

Based on what we had discussed the other day with load order

wet sandal
#

B42 has load order now?

#

Nice.

bright fog
#

No not nice actually skull

wet sandal
#

ah, and users have to set it right... I'll stick to events for my timing.

bright fog
#

Albion kind of convinced me that the way it loads now is actualkly terrible

bright fog
wet sandal
#

Still beating IT for every scrap of performance I can get from it

#

Realized the grids were deriving ISPanel for no reason and had 100% overdraw as a baseline

covert carbon
#

Is there any way to give an item its own ID or number assigned to it? I am trying to differentiate from different types of guns and I do not know how to tell the difference between two identical guns such as two m9s

wet sandal
#

So, they are the same item right?
The backing Item data will be identical, but for the InventoryItem instance you could put some info into moddata.

#

Also, InventoryItem's have ids already, which are all unique.

#

item:getID() is likely all you need

true nova
#

anyone know how to make a new isoRoom and add it to a building and add tiles to it?

bright fog
#

That's a very interesting question

true nova
#

there doesnt really seem to be any options to modify one. i can make a new one but then cant set any properties for it

bronze yoke
#

from all of my research i have concluded that you probably can't

true nova
#

ded so i'll be making and tracking everything myself then, thank you

bright fog
#

New changelog for modding
You can find a list of changes that were found and that were listed on the modding page. The format for it might change in the future. If you found any changes that need to noted, please don't hesitate to edit the wiki page

https://pzwiki.net/wiki/Modding#Modding_changes

distant inlet
#

good evening, I'm trying to test my mod but I can't find it from the mods menu in-game. What could I be missing? My mod is under C:\Users<<myUser>>\Zomboid\mods\MyMod and the structure looks like
MyMod/
mod.info
poster.png
media/
lua/
client/
<<.lua files>>

small topaz
#

Hi! In B42, does anyone know how the position of scrollbars is calculated when adding them to a ui panel via "self.myPanel:addScrollBars()"? Also, is there a way to access the scrollbars somehow and change position using commands like "scrollBar:setX(x)"?

quaint warren
#

Anyone know if there's a robust way to modify existing entries from RadioData.xml?
The only way I seem to be able is to replace the whole file, which is quite fragile when the game is updated.

I see how ZomboidRadioDebug.lua accesses the entries, but:

  1. It utilizes getValidAirBroadcastDebug, a debug method which I'm not certain can be used when not in debug mode
  2. It doesn't change any values
tacit pebble
#

shit wrong channel

small topaz
#

@tacit pebble what are you trying to achieve? get clothing item from specific body location?

silent sky
#

anyone know how adding a required tool works to a recipe

#

and having it actually show that its a required item

#

keep [Recipe.GetItemTypes.Screwdriver]/[Recipe.GetItemTypes.DullKnife]/[Recipe.GetItemTypes.SharpKnife]/SharpedStone,

#

i will see something and its seperate in game from the materials

#

but somethings will keep needle

#

and it does not seperate the item

keen silo
#

hey, I need some help with some coding help with changing clothes from zombies.

Essentially, I need to change their clothes from one model to another (to make them look fat, or obese, or thin, etc).

I already did this for the player character, but I had a special function on build 41 that updated the visuals. I do not have this function for zomboids.

Does anybody know how can I force the game to make it reload their visuals?

keen silo
#

Also, be aware that on build 42 they added english translations to the radios, so you have to make a translations file AND the lines will be read from THERE (not your xml file)

#

I made a simple py script that turns an xml on it's Translation_EN.txt file

quaint warren
keen silo
#

which code and why?

#

do you mean the colors?

bronze yoke
#

i've actually done this before, i haven't modified codes but i have modified the text itself

#

i don't have the code anymore (i think it was one of the first things i made around three years ago, i don't even remember why and i definitely didn't release it) but it can be done

#

i don't know about getValidAirBroadcastDebug specifically but there are other functions in the game with the -Debug suffix that don't actually depend on debug mode at all

tacit pebble
tacit pebble
keen silo
#

letme check

tacit pebble
keen silo
#

then you need to make a java mod

#

just kidding

bronze yoke
#

these are just proxy methods over getWornItem()

keen silo
bronze yoke
#

e.g getClothingItem_Back() just does getWornItem("Back")

keen silo
#
local function UpdateClotheVisuals( chr , suffix)

    --if not isCopySkinningDataAvailable then
    --    return
    --end


    ---@type WornItems|ArrayList
    local wornItems = chr:getWornItems()

    for i=0, wornItems:size()-1 do
        local wornItem = wornItems:get(i):getItem()
        print(wornItem:getType())
        local newWornItem = instanceItem(wornItem:getFullType()..suffix)

        if newWornItem then
            print(suffix.." Item Found")
            local oldItemVisual = wornItem:getVisual()
            if oldItemVisual ~= nil then
                local newItemVisual = newWornItem:getVisual()
                newItemVisual:copyBlood(oldItemVisual)
                newItemVisual:copyDirt(oldItemVisual)
                newItemVisual:copyHoles(oldItemVisual)
                newItemVisual:copyPatches(oldItemVisual)
                newItemVisual:setBaseTexture(oldItemVisual:getBaseTexture())
                newItemVisual:setTextureChoice(oldItemVisual:getTextureChoice())
                newItemVisual:setTint(oldItemVisual:getTint())
                oldItemVisual:copyFrom(newItemVisual)
            end
        end
    end
end
#

I needed to get all items worn by a character, and change their visuals for Fat and Obese versions

tacit pebble
keen silo
#

I guess you could check if they are on a specific body location

keen silo
bronze yoke
#

if it works for players just do the same thing and then zombie:resetModelNextFrame()

tranquil reef
#

is getModData able to store item references

bronze yoke
#

no

keen silo
#

I need to update the clothing, not the character model

bronze yoke
#

that function is necessary to update the clothing

keen silo
#

mmmm

#

im not exactly changing the clothing

keen silo
#

to change how it looks

#

the problem is that it is not updating that (?)

#

I guess I could simply make it Wear the clothes (I just didn't want players to be able to get the debug clothes in game)

ebon dagger
#

Hahahahah, I do NOT understand combat in this game lol.

The standard Debug combat text says the zombie got shot in the hand with no defense.

> CombatManager.pressedAttack         > Attacked zombie: dist: 5.6978936, chance: (57), crit: false (44%) from behind: true
> CombatManager.attackCollisionCheck  > Zombie got hit in Left Hand with a Base.AssaultRifle for 2.364 out of 2.364 after totalDef of 0.0% was applied

Then, with OnHitZombie I have logging outputting the bodyPart hit, and the defense of the clothing in the location.

> Bodypart:
> Torso_Upper
> Defense 20

Then Combat Debug text from zomboid debug says it was hit in the head.
CombatManager::ProcessHit 276 isCameraTarget and hit BodyPart 2 - BODYPART_HEAD

One bullet hit a zombie in 3 places lol

tranquil reef
#

is multiple world item textures possible for one item or does it need multiple items

silent sky
#

i just add multiple textures like this but it does not let you choose when spawning

#

its just random

keen silo
#

you could make multiple clothing definitions if you want it to be specific

#

how can I force a zomboid to wear clothes?

#

at runtime, like call a function "Wear this" ?

ebon dagger
#

@keen silo can you clarify the question?

Do you want random zombies to spawn in the game wearing your outfit?

Do you want to shoot a zombie with a clown gun and transform it into a clown?

Whatcha mean by "force".

keen silo
# ebon dagger <@464148894482432002> can you clarify the question? Do you want random zombies ...

So, im working on a Dynamic Body Shape mod that changes your character body shape based on your in game weight (purely aesthetic).

I wanted to make it work also with zombies. Zombies dont have a nutrition so I dont really care about that. I just want that when a zombie is spawned in he is asigned a body weight using a normal distribution (aprox) and that sets it up to be that weight until it is despawned.

#

So I can force the base model zombie to be fat or obese, and texture clothing will become fat and obese with the zombie, but mesh clothing arent working correctly

#

To make it work with the player, I created copy clothings called clothing_fat or _obese. These are not placed in spawn tables so they shouldnt appear normally in game. They are used to create a ghost visual with a different mesh (fat or obese) and then I copy every hole, blood, dirt and stitch to that mesh and back

#

So you are still wearing clothing, but it shows with the mesh of _fat or_obese versions

keen silo
undone elbow
#

Current mods that change the character model require a game restart.

#

How did you make it in Dynamic Body Shape?

tranquil reef
#

Is it possible to make custom depth maps like TIS does for sitting on things?

abstract cairn
#

table.insert and table.remove are giving me these errors
thoughts?

i think i did wrong methods, going to try again now

vivid imp
#

Project Zomboid Community Human Rig

#

I've spent the last few days creating a rig for the human character for people to animate with! It should be a lot easier to use than just posing every bone manually. I hope you all like it!

quaint warren
bronze yoke
#

it was definitely a broadcast

vivid imp
#

Maybe the rig should be pinned? might be presumptuous of me but it would help people see it haha

ebon dagger
#

This station runs hourly, forever, with over 142 trillion possible broadcasts.

abstract cairn
#

line 39 is causing errors still, different error though

LOG : General , 1737607908497> 31,582,997,828> -----------------------------------------
STACK TRACE

function: AssignPrey -- file: MInit.lua line # 39 | MOD: Chops
function: onClientCommand -- file: MInit.lua line # 16 | MOD: Chops

ERROR: General , 1737607908498> 31,582,997,829> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: Object tried to call nil in AssignPrey at KahluaUtil.fail line:82.
ERROR: General , 1737607908499> 31,582,997,829> DebugLogStream.printException> Stack trace:
java.lang.RuntimeException: Object tried to call nil in AssignPrey
at se.krka.kahlua.vm.KahluaUtil.fail(KahluaUtil.java:82)
at se.krka.kahlua.vm.KahluaThread.luaMainloop(KahluaThread.java:973)
at se.krka.kahlua.vm.KahluaThread.call(KahluaThread.java:163)
at se.krka.kahlua.vm.KahluaThread.pcall(KahluaThread.java:1980)
at se.krka.kahlua.vm.KahluaThread.pcallvoid(KahluaThread.java:1812)
at se.krka.kahlua.integration.LuaCaller.pcallvoid(LuaCaller.java:66)
at se.krka.kahlua.integration.LuaCaller.protectedCallVoid(LuaCaller.java:139)
at zombie.Lua.Event.trigger(Event.java:64)
at zombie.Lua.LuaEventManager.triggerEvent(LuaEventManager.java:214)
at zombie.network.GameServer.receiveClientCommand(GameServer.java:4168)
at zombie.network.PacketTypes$PacketType.onServerPacket(PacketTypes.java:1022)
at zombie.network.GameServer.mainLoopDealWithNetData(GameServer.java:1532)
at zombie.network.GameServer.main(GameServer.java:800)
LOG : General , 1737607908500> 31,582,997,830> -----------------------------------------
STACK TRACE

function: AssignPrey -- file: MInit.lua line # 39 | MOD: Chops
function: onClientCommand -- file: MInit.lua line # 16 | MOD: Chops

line 39 is causing errors still, different error though

wind lance
#

cool fish you there?

#

is it chill if i dm with help? if not totally cool but i really dont know what im doing

#

maybe i just need to read up some more ig

#

just lmk

grizzled fulcrum
abstract cairn
#

I presume so this is where its defined

grizzled fulcrum
#

As far as I am aware, table.add(table, element) doesn't exist.

abstract cairn
#

that is commented out now

#

the thing causing the error is PlayersToAdd:add(PlayerArray:get(PlayerTempNumber))

grizzled fulcrum
#

I know

#

the add function doesn't exist

abstract cairn
grizzled fulcrum
#

for normal tables

#

This is why I asked if it's a normal table or not, but when it's defined it looks like a normal table?

abstract cairn
#

Online players returns an array list, array lists have these...

how do I define it as an array list lmao

grizzled fulcrum
#

{} is a normal lua table, not an ArrayList

abstract cairn
#

okay that makes sense

grizzled fulcrum
#

you dont need to use them

#

just use a normal table

abstract cairn
grizzled fulcrum
#
PlayersToAdd[#PlayersToAdd + 1] = PlayerArray:get(PlayerTempNumber)
abstract cairn
#

then I swapped to using gets and adds

grizzled fulcrum
#

Then it might've been an ArrayList somehow?

abstract cairn
grizzled fulcrum
grizzled fulcrum
#

Yes this is what is happening ^

abstract cairn
#

would I change its init?

grizzled fulcrum
#

No, this is just a performance optimisation for PlayersToAdd:insert(value)

grizzled fulcrum
#

You don't need to make it an ArrayList

#

arraylists are only used when you are given something from Java, like an event arg that is an ArrayList

#

You should just use normal table for it like it is now