# Objective creation/setting values
execute if score #servers_max_storage space_mb_total matches ..29999 run scoreboard players set #servers_max_storage space_mb_total 30000
execute unless score #servers_max_storage space_gb matches 0.. run scoreboard players set #servers_max_storage space_gb 30
execute unless score #servers space_mb_total matches 0.. run scoreboard players set #servers space_mb 0
execute unless score #servers space_mb_total matches 0.. run scoreboard players set #servers space_mb_total 0
execute unless score #servers space_mb_total matches 0.. run scoreboard players display numberformat samsung_servers_storage samsung_sidebar fixed {"text":"Unknow!","color":"red"}
execute if score #servers space_mb_total matches ..999 run scoreboard players display numberformat samsung_servers_storage samsung_sidebar fixed [{"score":{"name":"#servers","objective":"space_mb"},color:green,bold:true},"MB/",{score:{"name":"#servers_max_storage","objective":"space_gb"}},"GB"]
execute if score #servers space_mb_total matches 1000..999999 run scoreboard players display numberformat samsung_servers_storage samsung_sidebar fixed [{"score":{"name":"#servers","objective":"space_gb"},color:green,bold:true},"GB/",{score:{"name":"#servers_max_storage","objective":"space_gb"}},"GB"]

# Converting (ex:MB to GB)
execute if score #servers space_mb matches 1000.. run scoreboard players add #servers space_gb 1
execute if score #servers space_mb matches 1000.. run scoreboard players remove #servers space_mb 1000

# Server Full Storage Particles