API to send BossBar Titles / Messages
// First you"ll need this
$BossBarAPI = $this->getServer()->getPluginManager()->getPlugin("BossBarAPI");
// You can also do:
use PocketEssential\BossBarAPI\BossBarAPI;
// Set the barMessage first!
$message = "This is a BossBar message";
$BossBarAPI->setBarMessage($message);
/*
Player should an instance of a PLAYER, Just foreach loop all the online players; etc
*/
$BossBarAPI->sendBossBar($player);
}
You can also try a simple plugin made by us
Using our API, You can get (take a look at
it over) [here](https://github.com/PocketEssential/BossBar)