mojira.dev
MC-188602

In non-natural custom dimensions, if "bed_works" is set to true, beds cannot be used to skip the night or set the spawn point

In a custom dimension, if the dimension type has natural set to false and bed_works set to true, using a bed does not explode, but it does not skip the night or set the player's spawn point either.

How to reproduce:

  1. Create a new world with the attached data pack (

[media]
  1. ).

  2. Go to the nether or the end.

  3. Place a bed down.

  4. Use the bed.

Expected result:

The bed would set my spawn point, but probably not skip the night as the dimension has "natural" set to false.

Observed result:

The bed did not do anything.


Original description:

I made a custom world where what I expected to happen was:

  • In the Overworld, beds explode and respawn anchors set your spawn point.

  • In the Nether, beds set your spawn point and respawn anchors explode.

  • In the End, beds and respawn anchors set your spawn point.

However, what actually happened was:

  • In the Overworld, beds exploded and respawn anchors did nothing (1.16.5)/actually set your spawn point (21w18a).

  • In the Nether, beds did nothing and respawn anchors exploded.

  • In the End, beds did nothing and respawn anchors did actually set my spawn point.

I have attached the world settings and a video that shows some of the results.

Additionally, these errors appear in the output log when attempting to set your spawn (1.16.5)

Error executing task on Client
java.lang.NullPointerException
	at afr.a(SourceFile:128)
	at afr.a(SourceFile:142)
	at dkv.b(SourceFile:1202)
	at dkv.a(SourceFile:1216)
	at dwu.a(SourceFile:870)
	at pb.a(SourceFile:41)
	at pb.a(SourceFile:11)
	at ol.a(SourceFile:21)
	at ol$$Lambda$4750/782440233.run(Unknown Source)
	at aob.c(SourceFile:144)
	at aof.c(SourceFile:23)
	at aob.y(SourceFile:118)
	at aob.bl(SourceFile:103)
	at djz.e(SourceFile:1015)
	at djz.e(SourceFile:681)
	at net.minecraft.client.main.Main.main(SourceFile:215)

Linked issues

Attachments

Comments 3

In the

[media]

 I have found these parts:

For bed not working in oveworld and RA working:
Line 151 and 152

"type":{
.
.
.
"respawn_anchor_works": true,
"bed_works": false,
.
.
.
}

For bed working in nether and RA not:
Line 357 and 358

"type":{
.
.
.
"respawn_anchor_works": false,
"bed_works": true,
.
.
.
}

 

So there is no bug, it is intended, you can change these settings through importing correct settings to your world

I will import a data pack I made to reproduce the bug in 1.16.2 later today.

Stupidly enough, bed works only controls whether it explodes; natural is checked for actual sleeping/setting spawn.

This seems like an oversight.

[Mod] ManosSef

(Unassigned)

Confirmed

Platform

Low

Custom Worlds

1.16 Pre-release 3, 1.16 Pre-release 4, 1.16 Pre-release 6, 1.16 Pre-release 7, 1.16 Pre-release 8, ..., 24w10a, 1.21 Pre-Release 1, 1.21.3, 1.21.4, 1.21.5

Retrieved