Skip to content

Commit

Permalink
Merge pull request #244 from MrBurdy/dev
Browse files Browse the repository at this point in the history
Added DeathMessage
  • Loading branch information
Loumardes committed Jan 13, 2024
2 parents 5f19774 + d20f38c commit 2bde761
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Execute as & at the player
# Called by function scaffolding_rush:player/death/trigger

# Show a dead message
title @s actionbar {"translate":"deathScreen.title"}

# Force ride and sink into lava
ride @s mount @e[tag=player.death.drown_in_lava.animation,limit=1,sort=nearest]
execute as @e[tag=player.death.drown_in_lava.animation,limit=1,sort=nearest] at @s run tp @s ~ ~-0.025 ~
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ function scaffolding_rush:player/death/just_died

tellraw @a ["",{"text":"[BS] ","color":"gold"},{"selector":"@s"},{"translate":"blazing_scaffolding.fell_into_the_lava","color":"gray"}]

# Replace with a pumpkin head to have the color death message
item replace entity @s armor.head with carved_pumpkin{display:{Name:'{"text":""}'},HideFlags:1,CustomModelData:127,Enchantments:[{id:"minecraft:binding_curse",lvl:1s}]} 1
effect give @s resistance 3 127 true
effect give @s fire_resistance 3 127 true

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Execute as & at the player
# Called by function scaffolding_rush:player/death/trigger

# Show a dead message
title @s actionbar {"translate":"deathScreen.title"}

# Force spectate camera
spectate @e[tag=player.death.killed_by_player.animation,limit=1,sort=nearest] @s[scores={player.death.animation=1..39}]
execute as @e[tag=player.death.killed_by_player.animation,limit=1,sort=nearest] at @s run tp @s ^ ^ ^-0.1 ~ ~1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ function scaffolding_rush:player/death/just_died

tellraw @a ["",{"text":"[BS] ","color":"gold"},{"selector":"@s"},{"translate":"blazing_scaffolding.was_killed","color":"gray"}]

# Replace with a pumpkin head to have the color death message
item replace entity @s armor.head with carved_pumpkin{display:{Name:'{"text":""}'},HideFlags:1,CustomModelData:127,Enchantments:[{id:"minecraft:binding_curse",lvl:1s}]} 1

summon armor_stand ~ ~ ~ {Tags:["player.death.killed_by_player.animation","player.death.killed_by_player.animation.new"],NoGravity:1,Small:1,Marker:1,Invisible:1}

execute at @s anchored eyes positioned ^ ^ ^ run tp @e[tag=player.death.killed_by_player.animation.new,limit=1,sort=nearest] ~ ~ ~ ~ 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ scoreboard players operation @s respawn.timer = #respawn.delay.tick options
scoreboard players operation @s respawn.timer > 1 const

gamemode spectator @s
item replace entity @s armor.head with air
tag @s remove player.death.drown_in_lava
tag @s remove player.death.killed_by_player
tag @s add player.item.can_have_items

0 comments on commit 2bde761

Please sign in to comment.