gehongyan / MinecraftMessages

Helping generating message text for interacting with the Minecraft console.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MinecraftMessages

Helping generating message text for interacting with the Minecraft console.

Usage

MessageComponent component = MessageComponent.Create()
    .WithText("Hello")
    .WithBold()
    .WithItalic()
    .WithUnderlined()
    .WithStrikethrough()
    .WithObfuscated()
    .WithFont("minecraft:default")
    .WithClickEvent(ClickAction.OpenUrl, "https://github.com/gehongyan/MinecraftMessages")
    .WithHoverEvent(HoverAction.ShowText, "Click to open the project page");
JsonMessageBuilder builder = new();
builder.AddComponent(component);
string raw = builder.ToString();
string json = builder.ToJson();
string markdown = builder.ToMarkdown();

About

Helping generating message text for interacting with the Minecraft console.

License:MIT License


Languages

Language:C# 100.0%