My world got corrupted and I recovered it, but I can't find my house. Will I spawn at my bed even tho the world was corrupted?
Minecraft – Does bed work after minecraft world corrupts
minecraft-java-edition
Related Solutions
Using MCEdit, you can go back to your original spawn point by using "Move Spawn Point" on the hotbar and select "Goto Spawn". Then you can follow your history to try to figure out where your bed is.
If you really can't figure out, you can try the following MCEdit Filter. It will help you find your bed, but may actually take quite long (probably no less than a few minutes).
displayName = "Find beds"
inputs = (
("Search the whole world regardless of bounding box", True),
)
def perform(level, box, options):
if options["Search the whole world regardless of bounding box"]:
i = level.getAllChunkSlices()
else:
i = level.getChunkSlices(box)
print "Finding beds..."
for (chunk, slices, point) in i:
if blockExistInChunk(chunk, 26):
(x, z) = chunk.chunkPosition
print "=> Bed found near x={0}, z={1}".format(x * 16 + 8, z * 16 + 8)
print "Stopped finding beds."
def blockExistInChunk(chunk, blockId):
for a in chunk.Blocks:
for b in a:
for c in b:
if c == blockId:
return True
return False
Save the file under the filters
directory in MCEdit with name findbeds.py
, then go to MCEdit, use Filter
on the hotbar, select Find Beds
and click Filter
. Now watch the console (the white on black window) and it will output the approximate coordinates of where beds are found.
Sample output:
Finding beds...
=> Bed found near x=-440, z=-600
Stopped finding beds.
The best way to try to figure out how this works is with some SCIENCE. To test this, I set my spawn in a bed in my test world. Then, I broke the bed, and placed it back in exactly the same position it was in when I set my spawn there (I used some wool to mark where the bed was and how it was oriented). When I used /kill
, I respawned at the bed. However, if I break the bed, use /kill
, and then replace it in the spot it was before, after having died, my spawn is no longer set.
The coordinates of the player's bed are stored in the Player.dat file. Upon respawning, the game checks to see if the bed is still there, and if there is a valid spawning space around it. If the bed is at those coordinates upon death, and there is a valid spawning space, the player will spawn there. Even if the bed had been broken. If the bed is missing or obstructed upon respawning, the bed coordinates are cleared.
Best Answer
Maybe. Maybe not.
The player's spawn point is saved in
level.dat
for singleplayer worlds, orplayerdata/[UUID].dat
for multiplayer, in theSpawnX
,SpawnY
andSpawnZ
tags. If that file was corrupted and restored, it's possible that this data was destroyed. If they exist, and there's still a bed at these coordinates, which might not be the case due to the corruption, killing yourself will work.If you want to find out, I suggest opening this file using an external tool, such as NBTExplorer, and check for the tags.