I dunno how this event fires in cells that don't
have a waterlevel, but I saw a nil compare error in the logs at the line if headHeight <= waterLevel, so I put this "or 0"
This commit is contained in:
parent
9d61422cdc
commit
5fac128932
1 changed files with 1 additions and 1 deletions
|
@ -116,7 +116,7 @@ local function sinkInWater(e)
|
|||
local mobile = e.mobile
|
||||
local ref = e.reference
|
||||
local actor = ref.object
|
||||
local waterLevel = mobile.cell.waterLevel
|
||||
local waterLevel = mobile.cell.waterLevel or 0
|
||||
local headHeight = mobile.position.z + mobile.height * 0.8
|
||||
|
||||
-- no creatures
|
||||
|
|
Loading…
Add table
Reference in a new issue