Project Zomboid

Project Zomboid

Not enough ratings
A_Double Tap Mod
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
624.522 KB
28 Sep, 2022 @ 8:18am
1 Change Note ( view )

Subscribe to download
A_Double Tap Mod

Description
Not multiplayer compatible (yet)
Double-tap zombies to make them stay down....
Also, this mod adds reviving or reanimating to zombies, they may come back from the dead

Zombie Reanimation ( they come back for round 2 )
  • Zombies can reanimate after they are dead
  • There's a chance zombie will reanimate
  • Random time after zombie death, keeps it unknown
  • Small chance to get a fast reanimation
  • Adjustable with sandbox settings
    • chance to reanimate
    • time after death to reanimate (min/max for a randomzied time frame)
    • optional extra chance, which helps make sure there are some reanimated zombies
    • optional fast chance, a small chance that zombie will be reanimated really quickly(configurable fast time frame), to keep it interesting
    • Only revive once option
Flexible and configurable to get lots of different experiences.


Double Tap Action ( they stay down )
  • Double tap action will be avialable when player has a weapon and right clicks a dead body
  • Stronger weapon is better, however the weapon may be damaged
  • Random time after zombie death, keeps it unknown
  • Small chance to get a fast reanimation
  • Adjustable with sandbox settings
    • Action time
    • Weapon damage chance (the weapon is broken if used)
    • Weapon power modifier (could make all weapons stronger/weaker in the action (less time and faster action))



Under the hood:

When a zombie dies, it's location is saved and checked periodically for dead bodies. This is a weak point, there may be bugs and this is why this will probably not work in multiplayer immediately.
It's not too performance heavy as well, however it would be possible to change the code later to be even lighter, if that is the case.


A dead zombie has 5 possible randomizations:
1 - Zombie reanimation base chance; This always runs, determines if zombie becomes reanimated.
2 - Zombie reanimation extra chance; If the base chance fails, this is checked to see if zombie could still spawn. The extra chance can be increased every time a zombie fails both, the main reanimation check and the extra check, meaning that no matter how lucky the player is, they will eventually get a reanimated zombie. As long as the extra chance is enabled...
3 - Zombie reanimation fast chance; After a zombie is confirmed to reanimated, they could also have a (optionally increasing) chance to get a fast renaimation, which uses different time limits, allowing to catch players off guard.
4 - Zombie reanimation time; This is the main time setting, zombie will get a random number between min and max (default 1-48 hours).
5 - Zombie reanimation fast time; Only applies if the zombie passed the 3(fast chance) check. This uses different min and max (default 30 seconds - 6 minutes).

Vanilla compatability:

Since the vanilla chance is ~1%, I have not been able to test this properly, but I hope the functions that they have in vanilla work (setReanimateTime and setReanimateTime), if they work, the vanilla functionality will be overwritten.

If you have problems or bugs, please report them in the discussions





There's a movie with the curly hair skinny guy where he says "double tap", so I thought it would be cool to doubletap zombies, soo I like made zombies revive. I was already making this mod, after when I saw that video where they showed that vanilla has this feature too, I almost stopped, but then I realized vanilla doesn't have any configuration and doesn't have a double tap action.

Workshop ID: 2868751374
Mod ID: A_DoubleTapMod
12 Comments
Briar 8 Dec, 2024 @ 5:39pm 
Does this mod still work?
Mysteriono 16 Mar, 2023 @ 6:04pm 
For some reason settings are completely ignoring my required time and I only get fast reviving zombies despite having that option disabled.
nigel  [author] 3 Mar, 2023 @ 9:22pm 
Good idea tho, I do plan on updating the mod and when I do I'll read the comments again! 👍
nigel  [author] 3 Mar, 2023 @ 9:22pm 
I think I made it use any weapon, the script uses weapon stats like damage and durability.
I could add options for double tap weapon limits or configurations when I try to update this for MP.

Hopefully soon 🙏
RamboTurkey 3 Mar, 2023 @ 2:08pm 
anyway to make it use wooden stakes like for killing vampires?
BargainSale 22 Dec, 2022 @ 9:18am 
I tried. It stops the animation half way through. I can try to find a value that looks like one hit from most weapons
nigel  [author] 21 Dec, 2022 @ 4:02am 
try very low action time multiplier, like 0.1
nigel  [author] 21 Dec, 2022 @ 4:01am 
I think you can change the time to be very low
BargainSale 21 Dec, 2022 @ 3:53am 
Is it possible to make the double tack a single attack animation instead of a timed action?
Geruhn 13 Oct, 2022 @ 8:44am 
Too bad, would've love to include in the next RP session to surprise my players! :D