Skip to content
Browse files
Check for attachments before attaching player to bed (#2862)
  • Loading branch information
ElCeejo committed May 8, 2021
1 parent 4945f4b commit 81589268625277fdbe41da296c176c4ba3bc1c21
Showing with 5 additions and 0 deletions.
  1. +5 −0 mods/beds/functions.lua
@@ -102,6 +102,11 @@ local function lay_down(player, pos, bed_pos, state, skip)
return false

-- Check if player is attached to an object
if player:get_attach() then
return false

if beds.player[name] then
-- player already in bed, do nothing
return false

0 comments on commit 8158926

Please sign in to comment.