4

Bossbar Help Needed

BritishSpuds 10/17/20 10:44 am
173
11/3/2020 1:27 am
so, i want to have a dragon, called Jörmungandr. with 10k healh. as a challenging event for a server im in. currently i have the command:

"/summon minecraft:ender_dragon ~ ~63 ~ {DragonPhase:0,CustomName:'[{"text":"Jörmungandr"},{"text":"l","underlined":false}]',CustomNameVisible:1,Health:10000,Attributes:[{Name:"generic.attack_damage",Base:100.0F},{Name:"generic.knockback_resistance",Base:1.0F}]}"

this summons a dragon, with the name, Jörmungandr, with 10k health. but it doesnt have a bossbar. any help? thanks :D
Posted by
BritishSpuds
Level 1 : New Miner
6

  Have something to say?

JoinSign in

4

Eternity303
10/31/2020 3:17 am
Level 20 : Expert System
Here

so make a bossbar using bossbar command

/bossbar add <id> {"Jörmungandr"}

the id can be anything
then set the value of the bossbar

/bossbar set <id> max 10000
/bossbar set <id> value 10000
/bossbar set players <selector>

selector can be @a, @p, etc

now place a repeating command block and set to always active
then type in this command:

execute store result bossbar <id> value run data get entity @e[type=minecraft:ender_dragon,name="Jörmungandr"] "Health"

that should hopefully work
2
BritishSpuds
11/02/2020 5:46 pm
Level 1 : New Miner
the first part worked but the execute command isnt working. it give an output of


execute store result bossbar dboss1 value run data get entity @e[type=minecraft:ender_dragon,name="Jörmungandr"] "Health" <--[HERE]

Any idea why this happens?
2
Eternity303
11/03/2020 1:27 am
Level 20 : Expert System
maybe you have a space. there should be no space after the "health"
1
Nitgo
10/17/2020 3:26 pm
Level 77 : Legendary Sus
Try killing the dragon and checking if the portal to the overworld opens.
1

Welcome