Project Zomboid

Project Zomboid

[B42] Vorpal Weapons (Unofficial)
36 Comments
deliriousdel 2 Apr @ 8:51am 
I think the problem happened because I added the mod mid game. After starting a new game, my weapons are being renamed after killing zombies
deliriousdel 25 Mar @ 9:11am 
My weapons are being renamed right after I equip them. Is it based on totals kills by my player or with the specific weapon? But I really love the idea of this mod. I'd use it even if it didn't increase damage, just give my weapons fun names.
⌬ classic 20 Feb @ 6:16am 
@Cuckoo Thank you for taking the time to answer, I wish you the best of luck in your work ;)
Cuckoo  [author] 20 Feb @ 5:32am 
@_classic That’s all fair enough.

I did some cursory testing to check the base functionality wasn’t “broken” (inactive) outright before reuploading the mod for B42 (with the original author’s permission), but not in enough depth to catch the bugged item effects and consistency issues.

I don’t expect I have the skills to address those issues (and to be honest, I’ve got my own mods to work on) -- but feel free by all means to take a closer look at the luascript and see if you have more luck.
⌬ classic 20 Feb @ 3:52am 
Porting a mod to latest build and not running a proper use case test is a bit shameful. If you can’t finish the work at least tell us in the description.

Porting a mod and making the content accepted by the engine doesn’t take much time.

Wish there was good practices guidelines on Steam Workshop.
Mr. Kobaltz SOG 30 Jan @ 8:35am 
@hasufel_lionheart damn I was extremely excited to see this mod had updated to 42. Sad to know it doesn’t work correctly with 42’s architecture. Hopefully someone can get it working later on in the stable build. Thanks for trying your best with it.
hasufel_lionheart 29 Jan @ 9:58pm 
Well, after 4 days of studying java and lua, and even totally remade the code of the mod myself to modify some aberrations and clean the code, it appears that B42 architecture doesn't allow the dynamic modifications to weapons because it reload the items from their original script at every start, and even while playing on certain event, so it seems to be impossible to modify certain data.

I think it would need to entirely remade the java code to separate weapons from other items and being able to create new specific methods to modify them. It appear the problem is known from the developpers for years but they annouced it will not be fixed until b42 so maybe they will do something about it but it doesn't seems to be planned at all.

And this is well beyond my skills and time to make it myself.
So I guess this mode will remain a good idea!

If someone manage to make it work, it would be very cool to share the solution!
hasufel_lionheart 27 Jan @ 8:22am 
Well, after about 30 hours of hard learning(non-stop since my last comment), I finally managed to make the weapon weight reduction work, but it requires some intervention on the Java side, so I had to learn how java and lua are functionning (never looked at the code until now...), then decompile, modify and recompile the .class files, it was a pure brainfuck.

But now that the weight reduction works perfectly, now I have issues with the weight of the weapon parts that set the base weapon weight at each player connection.

(for example: a shotgun have 0.0 encombrance with "ethereal", but it has 1.2 with weapon-parts like scope, ammo straps, etc... At restart, the initializing set the weapon weight to 1.2 plus 1.2 of weapon part, so it become 2.4. Then after another restart, it become 2.4 with 1.2 weapon part, so 3.6, then 4.8 , 6 , 7.2, etc...)

I swear i will come back to the code and i will manage to make it work, but my brain is about to melt right now. XD
hasufel_lionheart 26 Jan @ 12:58am 
Hello! This mod looks awesome! Thank you Cuckoo for bringing it in b42!

Unfortunately, some of the features doesn't work anymore and for now, all the modifications on the items are dismissed at reload.

All modifiers to weight doesn't work and a problem with condition modification is now in B42 some weapons are in 2 parts, head and handle. When you get some modifiers that set the weapon max condition to above its original value, it will set the handle condition to max but the head condition and sharpening remain at what it was before the upgrade.

For example an Axe with 9/10 condition get the "Vorpal" prefix, the handle condition will be 100/100 but the heads condition will remain at 9/100 with sharpenning also maxed at 9% so no crit.

Well, anyway, since no modifications are saved when exiting the game, I guess we can assume the mod doesn't really work but the idea is great and i would love to know how to code to make it work!
Q 25 Jan @ 11:31am 
this is amazing: i love the idea of it but i have hard time telling if it works. im going to play more w it to experience the mod more and thank you for your effort
SolarisFall 22 Jan @ 8:13pm 
Managed to get an indestructible baseball bat, but it still lost durability. It's weird actually, when it got the property, the durability went down to near zero and didn't seem to move anymore, but on a reload it went back to just under full, but started losing durability.

I also got a weapon "of activity" that I couldn't find on the pinned list.

Really love this mod I think it adds a nice element to the game, but unsure if any of them actually work.
Sandtygr 20 Jan @ 8:58am 
Thank you for moving this over for Build 42. It seems that you cannot repair a weapon with a suffix/affix through maintenance in the crafting menu. Is anyone else getting this? It does not appear as an Item within the list if it has the "Named" effects.
EvoSouls 12 Jan @ 8:49am 
Does this only work with vanilla weapons?
nicholas_axels 4 Jan @ 10:31pm 
hello mod creator i would like to ask a question, it seems the modifiers other than damage and vorpal isn't working as intended do you know what might be the cause?
NekoMilo 2 Jan @ 2:51am 
it's the second time i got a weight modifier with it seamingly not applying, other stuff i got so far works though
KPEX 30 Dec, 2024 @ 10:29am 
I can confirm that using a weapon in each hand will apply a bonus to both weapons when only using the weapon in the primary slot. Can anyone confirm if the durability will work on axes? I've yet to have an axe with a durability buff so I cannot test for sure if the axes will last longer.
renndumi 30 Dec, 2024 @ 8:04am 
the damage factor don't applies with the Alternate Occupations mod
Marads~Yuuka 29 Dec, 2024 @ 12:39pm 
I'm using Show Weapon Stats Plus to see the weapon stats, I noticed that the initial pistol got "of the Ninja" which would increase critical chance, but the tooltip remained the same as the base pistol.

I know the mod is working because I got "of Diamond" in a spear and it displays the improved durability and break chance.

And a minor bug if you leave your "of Diamond" spear at home it will lose any vorpal properties until you equip it again, meaning the durability that should've been 100/100 will go down to 6/100, this probably happens when the chunk is unloaded due to distance, when coming back the game loads the base weapon instead of the vorpal stats.
Thraxinius 24 Dec, 2024 @ 9:40am 
Lets go got a vorpal prefix, ZOMBIES BEWARE
stecph 23 Dec, 2024 @ 3:20am 
Thanks a lot for updating this great mod!
Cuckoo  [author] 22 Dec, 2024 @ 8:19pm 
@Darth Ceveo it does indeed also affect modded weapons.

It looks like effects are no longer carried over when a weapon becomes modified (like a bat becoming a bat with nails), though - unlike in B41.
Vignette 22 Dec, 2024 @ 6:29pm 
Please port this when the full build comes out.
Wiseman6672 21 Dec, 2024 @ 11:31am 
Can't wait to do this with a fork or something
Darth Ceveo 21 Dec, 2024 @ 10:11am 
Is this only for vanilla weapons? Or does this, by some black magic, also effect modded items.
Quilava 21 Dec, 2024 @ 5:53am 
The weapon condition is reset when it power up? So it mean my dream of god like super weapon isnt dat far off after all? GOAT mod :love_seagull:
Cuckoo  [author] 21 Dec, 2024 @ 5:27am 
@Quilava
If you do manage to get a weapon to power up, its condition is reset to its maximum.
If I'm interpreting the code correctly, it takes between 10-29 kills for a weapon to get its first power up, and 30-70 kills for it to get its second.
Frasine 21 Dec, 2024 @ 2:32am 
Bout to create Excalibur (pencil)
gormotha 21 Dec, 2024 @ 12:48am 
aruan, do you have the cheats installed? i had a problem where i typed a certain key, i dont remember if its w, or maybe z... the weapon would reset; this was actually cool because if i didnt like the weapons modifier id reset it, and it would be fully repaired and could get a new set of attributes. just disable cheat and it should work, or find the key that triggers the reset;
Quilava 20 Dec, 2024 @ 10:48pm 
I love the idea of evolve weapon, the only problem is weapon so easy to break, it wont last long enough to make some godlike weapon, that would be fun :cool_seagull:
Cuckoo  [author] 20 Dec, 2024 @ 10:45am 
If that's a bug you were experiencing with the original Vorpal Weapons (1.2.1), then it's probably been carried over to this one.

Do you have a sense of which attribute modifier(s) or weapon names were affected (and have you already run the mod on its own, to make sure it's not due to a conflict with something else) ?
Aruan 20 Dec, 2024 @ 10:37am 
I have a problem with the original in which after the weapons gains the new powers, it immediatly resets to regular attributes, no longer having the power despite keeping the name. Anyone knows a way around this if it's still a problem in this version?
Cuckoo  [author] 20 Dec, 2024 @ 10:28am 
Exactly.

I've also left the pre-existing B41-compatible folder structure from electroglyph's original mod in place for this add-on (so in theory, it should still be backwards-compatible with Build 41).
Pompadour Nautice 20 Dec, 2024 @ 10:16am 
Oh I see, gotcha. Just moved the stuff into the 42 folder.
Cuckoo  [author] 20 Dec, 2024 @ 10:10am 
The required folder structure for Build 42 mods is different than what Build 41 used.

Once I'd reorganised Vorpal Weapons' folder/file structure so that B42 would accept it, the mod's original code from 2016 worked straight away. No actual changes to the luascript were required.

My so-called "port" is essentially the modders' equivalent of rearranging the furniture.

I spent more time working on the new Workshop preview image than I did actually meddling with any of the files for Vorpal Weapons (and I did not spend very long working on that preview image, in case Spiffo's cat tail didn't tip you off).
Pompadour Nautice 20 Dec, 2024 @ 9:49am 
Oh, so wait did the original Vorpal not work with Build 42?
Garfield. 20 Dec, 2024 @ 9:19am 
oh my god does it actually still work lmao