BossBar
Create boss bars visible to multiple players. Boss bars persist until destroyed or until /ignis reload.
Metatable name: "bossbar"
Creation
Section titled “Creation”mc.createBossBar(title, color?, style?)
Section titled “mc.createBossBar(title, color?, style?)”| Param | Type | Default | Description |
|---|---|---|---|
title | string | Boss bar display title | |
color | string | "white" | "pink", "blue", "red", "green", "yellow", "purple", "white" |
style | string | "progress" | "progress", "notched_6", "notched_10", "notched_12", "notched_20" |
local bar = mc.createBossBar("&cDragon Fight", "red", "notched_6")Properties
Section titled “Properties”bar.progress
Section titled “bar.progress”type: number
Boss bar progress (0.0 – 1.0). Read/write.
bar.progress = 0.75bar.visible
Section titled “bar.visible”type: boolean
Whether the bar is visible to its viewers. Read/write.
bar.visible = falseMethods
Section titled “Methods”bar:addPlayer(player)
Section titled “bar:addPlayer(player)”Adds a player to see this boss bar.
bar:addPlayer(player)bar:removePlayer(player)
Section titled “bar:removePlayer(player)”Removes a player from this boss bar.
bar:removePlayer(player)bar:destroy()
Section titled “bar:destroy()”Destroys the boss bar permanently.
bar:destroy()Lifetime
Section titled “Lifetime”Boss bars are destroyed on /ignis reload. Add players after creation or in the init event.