Project Zomboid

Project Zomboid

Dynamic Traits and Expanded Moodles [B41 & B42]
2sa2 9 月 28 日 上午 2:29
B42.12 Hit/Swing Error Patch
This should be a place, where we troubleshoot the current issue, in which the game log outpots errors for Swinging a weapon (or even pushing with space) and hitting something or a zed:

I've documented that DTEMMainFile.lua and DTEMexpandedActionsEffects.lua are faulty in this case, looking into it, it determines if a player hits/swings and then probably affects the build processs of new traits (ofc. it's dynamic traits).

This is the log output when pushing/swinging a weapon (not hitting a zed):

function: DTEMonSwingWeapon -- file: DTEMexpandedActionsEffects.lua line # 37 | MOD: Dynamic Traits and Expanded Moodles function: DTEMOnWeaponSwingHitPointMain -- file: DTEMMainFile.lua line # 196 | MOD: Dynamic Traits and Expanded Moodles ERROR: General f:192, t:1759051405365> ExceptionLogger.logException> Exception thrown java.lang.RuntimeException: Object tried to call nil in DTEMonSwingWeapon at KahluaUtil.fail(KahluaUtil.java:101). Stack trace: .......

And this is when hitting a zed:

function: DTEMonPlayerHittingAZombie -- file: DTEMexpandedActionsEffects.lua line # 167 | MOD: Dynamic Traits and Expanded Moodles function: DTEMOnWeaponHitCharacterMain -- file: DTEMMainFile.lua line # 204 | MOD: Dynamic Traits and Expanded Moodles

As you can see, lines 37 and 196 are affected when swinging or pushing, lines 167 and 204 when hitting a zombie. Since these are pretty long functions I will still try to look into it deeper and hopefully find a patch. I'm not a programmer, not even a lua programmer. I know the structure of many programming languages, scripting is basically a free thing for me but coding from creativity is really not the case for me.

That's why I need help from others, if I make mistakes and etc.
< >
正在显示第 1 - 2 条,共 2 条留言
2sa2 9 月 28 日 上午 3:23 
FIXED! I've uploaded the file to google drive and just added a few lines. Apperently, it outputs runtime errors, because TIS changed something in their engine, probably how it checks on swinging and hitting. And since the mod is pretty outdated, you know what happens next.

https://drive.google.com/file/d/16Ej-gZMbo-jBtWcTGlX0XCW_CSIkTPnw/view?usp=sharing

You can download the edited file only. Or you can subscribe the workshop mod I've uploaded (it's the same mod, just with that one edited file, nothing more)

I will say this here again, I just made the fix, I'm NOT the owner, nor a partner of PepperCat that made the mod originally.
< >
正在显示第 1 - 2 条,共 2 条留言
每页显示数: 1530 50