(3.0.0 - 3.25.6) 1.0.6 (3.0.0 - 3.25.6) 1.0.5-dev2 (3.0.0 - 3.25.6) 1.0.2
A useful PocketMine-MP plugin that allow user to create customizable dynamic floating text easily!
Main command: /dynamicft
(Aliases: dft
)
Sub commands:
create
- Creates floating textedit
- Lets you edit selected floating textremove
- Removes selected floating textlistids
- Shows all floating texts in a list{player.name}
{player.display_name}
{server.online}
{server.max_online}
{player.item.name}
{player.item.id}
{player.item.meta}
{player.item.count}
{player.x}
{player.y}
{player.z}
{player.level.name}
{player.world.name}
{player.level.folder_name}
{player.world.folder_name}
{player.level.player_count}
{player.world.player_count}
{player.ip}
{player.ping}
{time}
{date}
{line}
{player.money}
{player.faction.name}
{player.faction.power}
use OguzhanUmutlu\DynamicFT\Main as DynamicFT;
$dynamicft = DynamicFT::getInstance();
$idOfCreatedFt = $dynamicft->registerFt("This is a text!", new \pocketmine\level\Position(10, 50, 20, $dynamicft->getServer()->getLevelByName("levelName")));
This function returns the ID of the floating text
$dynamicft->updateRegisteredFt($idOfCreatedFt, "propertyName", "Property data (mixed)");
Property name | Data type |
---|---|
text |
string |
x |
float |
y |
float |
z |
float |
level |
string (Level folder name) |
id |
int |
$dynamicft->getRegisteredFt($idOfCreatedFt);
This function returns all the properties of the floating text in array
$dynamicft->getRegisteredFtIndex($idOfCreatedFt);
This function returns the floating properties index of fts.yml
$dynamicft->getAllRegisteredFts();
This function returns the properties of every floating text
$idOfSpawnedFt = $dynamicft->spawnFt($idOfCreatedFt, $dynamicft->getServer()->getPlayer("aPlayerName"));
This process will be run automatically when a player joins, when a floating text gets registered or gets updated
$spawnedFt = $dynamicft->getSpawnedFt($idOfSpawnedFt);
This functions returns the all the floating text particle instances detail of a floating text in array
/*
[
"player" => \pocketmine\Player instance,
"particle" => \pocketmine\level\particle\FloatingTextParticle instance,
"id" => int,
"creationId" => int$idOfCreatedFt
]
*/
$idOfSpawnedFt = $spawnedFt["id"];
If you want to update the text of a floating text, update with the updateRegisteredFT()
function instead of changing the text of the floating text particle instance as it will be overwritten every second
You may open an issue on the floating text GitHub repository for report bugs https://github.com/OguzhanUmutlu/DynamicFT/issues