Başvuru
Bu sayfa İngilizce gösteriliyor.
boss-bar
Boss-bar colors, divisions, metadata, viewers, and updates.
Declarations from the script contract strawberry:plugin, version 0.2.0, without source comments.
How to use it: guide.
WIT declarations
use text.{text-component};
use player.{player};
enum boss-bar-color {
pink,
blue,
red,
green,
yellow,
purple,
white,
}
enum boss-bar-division {
no-division,
notches-6,
notches-10,
notches-12,
notches-20,
}
record boss-bar-metadata {
darken-sky: bool,
dragon-bar: bool,
create-fog: bool,
}
resource boss-bar {
constructor(title: text-component, color: boss-bar-color, division: boss-bar-division);
get-title: func() -> text-component;
set-title: func(title: text-component);
get-health: func() -> f32;
set-health: func(health: f32);
get-color: func() -> boss-bar-color;
set-color: func(color: boss-bar-color);
get-division: func() -> boss-bar-division;
set-division: func(division: boss-bar-division);
get-metadata: func() -> boss-bar-metadata;
set-metadata: func(metadata: boss-bar-metadata);
add-player: func(player: player);
remove-player: func(player: player);
get-players: func() -> list<player>;
remove-all: func();
}