mirror of
https://github.com/luanti-org/minetest_game.git
synced 2025-05-21 14:53:16 -04:00
Remove unrequired bed_pos if statement
This commit is contained in:
parent
fb8c42f862
commit
9d197b0e3e
1 changed files with 4 additions and 6 deletions
|
@ -58,12 +58,10 @@ local function lay_down(player, pos, bed_pos, state, skip)
|
|||
return
|
||||
end
|
||||
|
||||
if bed_pos then
|
||||
for _, other_pos in pairs(beds.bed_position) do
|
||||
if vector.distance(bed_pos, other_pos) < 0.1 then
|
||||
minetest.chat_send_player(name, S("This bed is already occupied!"))
|
||||
return false
|
||||
end
|
||||
for _, other_pos in pairs(beds.bed_position) do
|
||||
if vector.distance(bed_pos, other_pos) < 0.1 then
|
||||
minetest.chat_send_player(name, S("This bed is already occupied!"))
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue