Skip to content

Latest commit

 

History

History
43 lines (29 loc) · 1.14 KB

huds-guis-images-and-more.md

File metadata and controls

43 lines (29 loc) · 1.14 KB

HUDs, GUIs, images and more

To see how to use HUDs and GUIs API (Font Images) you can check my examples.

GUIs

{% embed url="https://github.com/LoneDev6/API-ItemsAdder-Example-GUI" %}

Huds

{% embed url="https://github.com/LoneDev6/RPGhuds" %}

{% embed url="https://github.com/LoneDev6/API-ItemsAdder-Example-ServerMonitor" %}

Access mana bar value example

PlayerHudsHolderWrapper huds = new PlayerHudsHolderWrapper(player);
PlayerQuantityHudWrapper manaHud = 
                new PlayerQuantityHudWrapper(huds, "magiccraft:mana_bar");
if(manaHud.exists())
  manaHud.setFloatValue(2.0f);
else
  System.out.println("Error: mana not found, maybe it's disabled.");

{% hint style="warning" %}

NOTE

Make sure that you don't have the permission ia.user.hud.bypass.api.* or setFloatValue the code won't do anything. {% endhint %}

FAQ

{% content-ref url="../../plugin-usage/adding-content/font-images/common-errors.md" %} common-errors.md {% endcontent-ref %}

Get Emoji or GUI character

new FontImageWrapper("twitteremojis:confirm").getString()