Project Zomboid

Project Zomboid

[B42] Occupation Starting Items
37 Comments
Taboody Efferwood 25 Jul @ 5:02am 
this feels like it needs a nerf, especially burglar as a duffel bag from start is strong. But i do like how this mod makes picking over professions a valid option
Pinky 16 Jun @ 10:53am 
This mod rocks btw, a must-have for any realism collection
Pinky 16 Jun @ 10:53am 
Is there any chance of you doing a SOTO sub-mod to add proper occupational clothing options to that mod? I just find it weird, that a soldier, for example, doesn't spawn with any sort of military gear. It's especially startling with spawn items, when the same soldier spawns with an m16 but not his uniform and/or webbing lol
FishLord  [author] 31 May @ 5:52am 
Yep! just updated to include all the occupations in that mod.
Katora Noku 6 May @ 4:15pm 
Any plans to add compatibility/items for the "Simple Overhaul: Traits and Occupations" mod?
DaCool 3 May @ 10:00am 
nice
Mang 1 Mar @ 5:53am 
ok
FishLord  [author] 1 Mar @ 1:59am 
no
Mang 28 Feb @ 7:42pm 
make this customizable in sandbox for all vanillla occupations
Aesarius 31 Jan @ 3:55pm 
I saw the comment, glad to help =)
FishLord  [author] 31 Jan @ 3:29pm 
@Aesarius Thank you I fixed the issue. I mistakenly used the old B41 item ID for the athlete's water bottle which has now become redundant. (sorry I accidentally deleted the old comment in case you didn't see it)
FishLord  [author] 31 Jan @ 3:17pm 
You may be on B41, update to the unstable B42 to use this mod and others.
TheManAndStuff 31 Jan @ 3:05pm 
why doesnt the mod show up in the mods menu in game? this is happening with a bunch of my mods and idk how to fix it
Aesarius 31 Jan @ 12:55pm 
Hi! The console logs show an error when starting the game
Console logs:

`attempted index: getDisplayName of non-table: null
function: AlterProfessionDescription -- file: SpawnProfessionItems.lua line # 202 | MOD: Occupation Starting Items
java.lang.RuntimeException: attempted index: getDisplayName of non-table: null
`
The highlighted line in your script: "desc = desc .. "\n- " .. it:getDisplayName()" in function AlterProfessionDescription()

In the loading order, your mod comes after Mar mods.
Do you need additional logs to fix this?
Kylian 31 Jan @ 11:18am 
No pressure, I'm already happy you're willing to try porting it at all
FishLord  [author] 31 Jan @ 11:14am 
I forgot that some of the professions start with a few B42 items so I'll need to change their starting items for the B41 version, I'll get around to doing it when I can.
皮皮凯(PiPiKai) 31 Jan @ 10:32am 
Thank you very much!
Kylian 31 Jan @ 10:21am 
Thanks alot!
FishLord  [author] 31 Jan @ 10:18am 
@Kylian I'll try backporting it to B41, shouldn't be too difficult.
FishLord  [author] 31 Jan @ 10:17am 
@皮皮凯(PiPiKai) I updated it so the starting items should now be automatically translated for every language!
Kylian 31 Jan @ 10:09am 
This mod looks great! It's exactly what I was looking for. Is this also compatible with B41? or alternatively is there another mod for B41 multiplayer that does something like this? I've been looking around but I can't seem to find any.
FishLord  [author] 31 Jan @ 9:22am 
So the hard coded text strings were actually kind of a work around I didn't really want to make. My initial plan was to have the starting item lists be automatically generated by grabbing the item display names from the item ID lists, this would have automatically translated everything to every language without the need for any external translation.

Unfortunately I couldn't figure how to get the display names of each item from each item ID within the code, so I just hard coded the descriptions as a temporary fix. However if there is a demand for translation I'll have a look at it again and see if I can get it working this time, thank you for letting me know about this issue!
皮皮凯(PiPiKai) 31 Jan @ 8:47am 
First of all, thank you so much for your mod—it’s really great to use! As a non-English-speaking player, I’d like to offer a suggestion that could make your mod more popular and easier to use.

Currently, the text strings are hardcoded, which makes translation challenging. Have you considered using text variables/keys that reference external language files? This would allow players to translate the mod easily without modifying the core code.

This change could effectively encourage the Steam Workshop community to translate your mod. I’d love to hear your thoughts—would you consider it?
FishLord  [author] 31 Jan @ 8:14am 
All starting items are listed in the discussions section or in game when selecting an occupation. The angler starts with a fishing rod, a net, some worms as bait, and a cool fishing hat.
Okruzhkov 31 Jan @ 7:08am 
What items does the fisherman start with?
VII 29 Jan @ 5:45pm 
@fishlord cheers for the reply i see it now and i finally got to terms on how the 2 different formats of coding works, blessing in disguise i learnt something new since you rewrote the code so i thank you for that little bit of education XD.
FishLord  [author] 28 Jan @ 4:22am 
@Farkin The blacksmith already starts with a smithing hammer and I don't want to add too many items as to make the game too easy. That being said I'll replace the tongs with metalworking pliers (as crude tongs can be made pretty easily) and I'll add in the metalworking punch too, so that more recipes are accessible with these starting tools.
FishLord  [author] 28 Jan @ 4:16am 
@VII no worries this section of code here checks to see if an added item can hold ammo (both guns and clips) and then sets their ammo capacity to max. It then chambers the gun and adds a clip just below it (the if statement makes sure that the item isn't a clip otherwise an error will happen if the code tries to chamber a clip)

for i, item in ipairs(Items[profession]) do
local newItem = playerObj:getInventory():AddItem(item);
if newItem:getMaxAmmo() > 0
then
newItem:setCurrentAmmoCount(newItem:getMaxAmmo())
if item ~= "Base.M14Clip" and item ~= "Base.556Clip"
then
newItem:setRoundChambered(true);
newItem:setContainsClip(true);
end
end
end
VII 27 Jan @ 9:59pm 
sorry to be a pain but i have been using your mod as a template to teach myself a little about this area of modding but since the update i cant figure out where to put the values for stuff like how many clips and and they will be loaded and guns chambered etc.
AxeHammer 27 Jan @ 5:58pm 
blacksmith should start with most of the metalworking tools plus a smithing hammer
FishLord  [author] 27 Jan @ 12:34pm 
Yeah that's probably the smartest thing to do not sure why I didn't consider that haha
Mutinous 27 Jan @ 12:29pm 
A work around I've seen on other mods, for the character limit, is to use screenshots. Not sure if that's doable, difficult, something you've already considered,or whatever, sorry if I'm telling you how to do your job :P
西伯利亚酥皮烤鸭 26 Jan @ 1:07am 
The original setting had no medicine at the doctor's house, no kitchen knives or food at the chef's house, and no hammers or saws at the carpenter's house.
Well, this is quite outrageous.
The design concept of this mod is excellent.
daygrindmike 25 Jan @ 5:11pm 
I'd love a mod that would let you start the game with 10 items of your own choosing. Is this difficult to create?
Nice. CDDA had this (fav being military recruit and a starter M4 assault rifle). Now I can finally have my own M14! :jake::steamthumbsup:
fishska 25 Jan @ 5:03am 
Like it should be!