#(Mars) how to make an npc sleep properly on a bed with command

52 messages · Page 1 of 1 (latest)

rugged light
#

Wondering what location to use for the sleep command to make an NPC sleep on a bed, like actually the way it’s supposed to. They always seem to be sideways or hanging off the bed. (Forgive me, I think I’ve asked this before but I need to revisit it)

prime sphinxBOT
#

(Mars) how to make an npc sleep properly on a bed with command

#

Hi I'm AutoThreadBot! Don't mind me, I'll just be adding the helper team to this thread so they can see it. A human will get to you soon.
You can block this bot if you don't want to see these messages, I won't mind.
<@&525394568410038282>

wet hinge
#

!c sleep

astral surgeBOT
# wet hinge !c sleep
Required Plugins or Platforms

Citizens

Group

npc

Syntax

sleep (<location>)

Short Description

Causes the NPC to sleep. To make them wake up, see !command Stand.

Description

Makes the linked NPC sleep at the specified location.
Use !command Stand to make the NPC wake back up.

wet hinge
#

in theory just give the location of the bed block for that

#

might matter head vs foot of the bed, not sure offhand

rugged light
#

Yeah that’s what I mean

#

I try the head block and the foot block but the npc always ends up like off to the side or sticking out over the top or diagonal laying across it

#

It never lays on the bed properly

#

I can get it to do so like manually everytime when I tp it, but if I use “stand” and then try to make it go back to sleep, it’s hanging off the bed always. (Simulating waking the npc up, and him going back to sleep is the desired outcome)

#

It’s for a quest where you have to sneak around and can’t wake the guy up. So if you wake him up he stands, you start over, and he should go back to sleep in the bed, but his position always gets messed up

wet hinge
#

er... it's a player type NPC right?

#

only player-type can properly sleep in beds

#

villagers can but differently

#

anything else just can't

#

Also make sure you're using the bed block

#

ie not the block above it

vivid tapir
#

Did you already try to teleport the npc to the headpart, after reaching the actual location? I know its just a workaround, but for me its working better than just walk and sleep.

rugged light
rugged light
#

yeah ive tried a few different solutions but the only way ive gotten it to work is if i go to the spot on the bed, do /npc tphere and then make em sleep

#

i can show you exactly in a little bit when i can get on the game

#

ive had to try weird ways to get the location, hoping it would be more precise or something but it doesnt work out.

rugged light
wet hinge
#

@vivid tapir @rugged light y'all both overcomplicating it something?

#

shouldn't be manually teleporting at all, just input a location to the sleep command

#

(the location being the head side of the bed)

vivid tapir
#

i found why its working

#

@rugged light you need to setup the location on the ground where the headpart actually is placed on, not where you stand when standing on the head part

#

right loc

#

wrong loc

wet hinge
#

The location needs to be the bed block itself

#

not the ground, not the air

#

The bed block.

rugged light
#

I got it

#

Thank you for the help

#

It was not working right before. He always laid diagonal hanging off of it

#

But I know why and got it working. Thanks a bunch monkey

#

And everyone

#

Actually hold on

rugged light
#

alright all good

#

actually my problem was the bed was right up against a block, once i removed the blocks surrounding it it worked, but if the head is against a wall on 2 sides the npc is crooked