Description
This mod allows map makers / server owners to change the respawn point & dimension of dimensions.
To use this mod you place a file called perfectspawn.json in the main minecraft / server directory or (in a singleplayer environment) in the main directory of a save. The file has to have this basic structure:
In the general section there is currently only one property you can set which is "initialSpawnDimension". This sets the dimension where a player who has never logged in before spawns initially.
This config would cause players to initially spawn in the nether when first joining the game.
The rules array can contain multiple rules which control the settings for different dimensions.
Each rule has these properties:
- appliesTo: An array containing either dimension ids / names of dimensions types / full class names of world providers. This controls what dimensions this rule is applied to. "*" can be used as a special element of appliesTo which will apply this rule to all dimensions.
- canRespawnHere: Whether players can respawn in the dimensions this rule applies to.
- canSleepHere: Whether players can sleep in the dimensions this rule applies to. (If canRespawnHere is set to false this has no effect). This also allows sleeping in dimensions where you generally can't sleep (Like the Nether / End).
- spawnPoint: The position at which players will spawn in this dimension.
- respawnDimension: The dimension players will respawn in when dying in this dimension (If canRespawnHere is set to false)
Rules that come later in the rules array override values of rules that come earlier.
Here are some examples:
This changes the initial spawn dimension & the respawn dimension of all dimensions to the nether. It also moves the spawn point of the nether to "x: 5, y: 84, z: 10" and allows players to change their spawn point in the nether by sleeping.
With this players will initially spawn in the end at "x: 23, y: 40, z: 10". Once they die they will respawn in the overworld at "x: 9, y: 100, z: 0". When they die there they will respawn in the nether at "x: 500, y: 40, z: -500". Dying in the nether will just respawn them back at "x: 500, y: 40, z: -500". It isn't possible to sleep in the nether / end / overworld.
Issues
Please post about bugs on the github issue tracker and not on the curseforge post. Also make sure your json is valid before creating a bug report.
Info for older versions ( < 1.12.2):
This mod allows map makers / server owners to set the exact spawn point of a world. You can also specify the start dimension.
To use this mod you place a file called PerfectSpawn.json in the main minecraft / server directory or (in a singleplayer environment) in the main directory of a save. The file has to have the following format:
{
"spawnDimension": 1,
"spawnX": 50,
"spawnY": 70,
"spawnZ": 60,
"exactSpawn": true,
"forceBed": true,
"spawnProtection": true
}
This config file sets the spawn point to X:50,Y:70,Z:60 in the end, enables beds, spawn protection and forces an exact spawn.
If you create a file you always have to specify spawnX,spawnY,spawnZ and spawnDimension. exactSpawn, spawnProtection and forceBed are optional and default to true.
- "exactSpawn" : Specifys whether players will respawn exactly at the specified spawn point.
- "forceBed": Specifys whether PerfectSpawn should force beds to be possible in the spawnDimension
- "spawnProtection" : Allows Spawn Protection in changed spawn dimensions.
A PerfectSpawn.json in a world directory overrides the one in the main dictionary.
You can use the command "/ps reload" to reload all config files and apply them instantly.
This mod class transforms all WorldProviders it finds, if you get a crash that only happens while using PerfectSpawn come to me first!
Instead of creating the json files manually you can also use the /ps set command to change the spawn ingame.
If you wanna add Perfect Spawn to a modpack / ship it with a map feel free to do so.
how would you make the spawn set in modded dimensions such as the midnight?
So the file goes right into the server directory? Not the config, right?
edit: spelling
Would really love to see this updated to 1.16 if at all possible
Is there a reason the mod didn't get updated past 1.12?
Is there a way to set a respawn dimension for all other dimensions instead of listing them manually in the file? like no matter what dimension the player dies in, I want them to spawn in dim -2 or at a set spawn
anything like this for 1.16.5?
edit: nvm, found one: https://www.curseforge.com/minecraft/mc-mods/globalspawn
My initial dimension = 111 (the lost city)
went into the end, kill dragon, jump into the exit portal..
and it sent me to overworld (dimension 0)...
Anyway to change this?
EDIT: Since respawn requirement is to die... Imma just gonna use Restrict Portal...
Anyway I still use this mod its awesome 🤏👍
Here are my example setup:
Dying in Lost City Dimension (111), respawn in Hell, dying in Hell, respawn in Hell, loop.
can this be updated to 1.16? im trying to make a nether survival type of pack and i can't figure out how to spawn in the nether when i create a world.
In reply to drowning51:
are u using forge or fabric
there needs to be a copy/paste code, as all the code examples are image files.
In reply to ultrasquid9:
agreed, I hate having to spend multiple days asking for help every time I use this mod.
In reply to vizthex:
{
"general": {
},
"rules": [
]
}
should work, dont think spacing is absolutely necessary
sorry for 3 month late reply lol
is there any way to automatically apply this to all maps?
edit - i figured it out, the description confused me.
In reply to ultrasquid9:
how exactly do you apply this to all maps, I am still unable to figure it out
Can this be updated for 1.15 + 16 once that comes out, that would be great thanks.
Please provide a better wiki and/or text examples, annoying af to hunt down help every time I use this mod.
i am trying to use this mod to set a spawn point in the end on an island where i have the player starting. but every time i die (ex. falling out of the world) it sends me back to the overworld. i am in version 1.12.2 and usind lockdown to start the player off in a desired area. any help would be greatful
In reply to yomamasnuggets:
Add the "canRespawnHere": true tag
Can you make it so you can choose a specific biome to spawn in?
1.7.10 user here.
Just wondering if you heard or known any issue with ForgeEseentials to kind of screw it up?
EDIT: Seems that the config file is very case sensitive in Linux haha.
"PerfectSpawn.json"