
This datapack is a gamemode addition to the game. It lands somewhere in between hard and hardcore. On death you will enter spectator mode for a configurable amount of time. After the countdown is finished you will be spawned at a bed, respawn anchor, or worlds spawn (whichever you had set). There are many config settings to change to get it just the way you would like it to be.
Supports MC versions 1.20.2 through 26.1.2
SET UP:
-
Put the SoftHardcore file into the datapacks folder located in your world folder and reload/leave and rejoin your server/world
-
At world spawn (or where you would like to change world spawn to) run this command: /function softhardcore:setspawn
-
OPTIONAL Set the amount of time in ticks (20 ticks = 1 second) the countdown is when a player dies: /scoreboard players set sh.DeathDuration SHconfig 1200
EXTRA CONFIG SETTINGS/COMMANDS
Only runnable while dead, return to your death location to see what went down (any player can run this): /trigger back
1= true 0= false
Turn off the countdown and gamemode switch on death: /scoreboard players set sh.SkipSpectatorCountdown SHconfig 1
Turn off instant respawn gamerule (this will now show the main menu button on death: /scoreboard players set sh.GameruleDoImmediateRespawn SHconfig 0
Lock "Dead" players to only move a short distance away from world spawn: /scoreboard players set sh.PreventDeadSpectatorsMoving SHconfig 1
Force player out of death early:
/scoreboard players set
If you are running a server This data pack will not pass dead players time if the server is paused or if it is offline. Change this property so that if no one is online players timers continue to go down.
pause-when-empty-seconds=-1
Another thing you can do to prevent server lag is prevent spectators from generating chunks.
/gamerule spectatorsGenerateChunks false
