Project Zomboid Lua Docs 29123
Unofficial documentation for Project Zomboid's Lua
Loading...
Searching...
No Matches
Hooks

Attack

(Client) Attack: Called every tick while a local character is pressing their attack button and is able to attack.

Parameters

Name Type Notes
attacker IsoLivingCharacter The character attempting to attack.
chargeDelta number
weapon HandWeapon

AutoDrink

(Client) AutoDrink: Called whenever a character automatically drinks while auto-drink is turned on.

Parameters

Name Type Notes
character IsoGameCharacter The character auto-drinking.

CalculateStats

(Client) CalculateStats: Called when a character's stats are being updated. Character health is not included.

Parameters

Name Type Notes
character IsoGameCharacter

ContextualAction

ContextualAction:

Parameters

Name Type Notes
actionType string
character IsoGameCharacter
object any
arg1 any
arg2 any
arg3 any

WeaponHitCharacter

WeaponHitCharacter: Called when the effects of an attack are being calculated.

Parameters

Name Type Notes
attacker IsoGameCharacter
target IsoGameCharacter
weapon HandWeapon
damageSplit number

WeaponSwing

WeaponSwing: Called when a weapon is swung to find targets

Parameters

Name Type Notes
character IsoGameCharacter
weapon HandWeapon