Anas 53x

create a mod for me that shows streamchat at top left corner you hve to put stream link in a gui the chat gui will be fully adjustable the chat should update in real time.

Kodari AI
KodariOct 19 at 10:32 am 2
StreamChatOverlay
A Minecraft Fabric mod that displays live stream chat in the top-left corner of the screen. Players can input their stream link through a configurable GUI, with full customization options for chat position, size, opacity, and appearance. The chat updates in real-time, fetching messages from supported streaming platforms and rendering them as an adjustable overlay that can be moved, resized, and styled to suit player preferences.
  1. Add a Twitch stream-link settings screen with adjustable chat overlay options.

  2. Connect to Twitch chat and update the top-left overlay in real time.

  3. Package the Fabric 1.21.11 mod and required owo-lib dependency.

Added a client-side Fabric mod with a live Twitch chat overlay. Press O to open the owo-ui settings screen, enter a Twitch channel link, then adjust the overlay position, width, visible lines, opacity, or visibility. Settings are saved locally, and the chat reconnects automatically if the connection drops.

It reads public Twitch chat without sending messages; YouTube and other platforms aren’t supported.

Anas 53x

make it compactible with youtube stream also

Kodari AI
KodariOct 19 at 3:38 pm 1

Added YouTube Live chat support. In the O settings screen, paste a YouTube live video link and a YouTube Data API v3 key; Twitch still works without a key. YouTube chat updates using the API’s polling interval, so it may not appear quite as instantly as Twitch’s WebSocket chat.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
gradle.properties
manifest.kod
settings.gradle
Code
11 830
src/client/java/com/kodari/streamchat/client/StreamChatClientEntrypoint.java
package com.kodari.streamchat.client;

import net.fabricmc.api.ClientModInitializer;
import net.fabricmc.fabric.api.client.event.lifecycle.v1.ClientTickEvents;
import net.fabricmc.fabric.api.client.keybinding.v1.KeyBindingHelper;
import net.fabricmc.fabric.api.client.rendering.v1.hud.HudElementRegistry;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.option.KeyBinding;
import net.minecraft.util.Identifier;
import org.lwjgl.glfw.GLFW;

public final class StreamChatClientEntrypoint implements ClientModInitializer {

    private static final KeyBinding.Category CATEGORY = KeyBinding.Category.create(Identifier.of("streamchat", "main"));
    private static KeyBinding openSettings;

    @Override
    public void onInitializeClient() {
        StreamChatConfig.load();
        StreamChatClient.connectSavedLink();

        openSettings = KeyBindingHelper.registerKeyBinding(new KeyBinding(
                "key.streamchat.open_settings",
                GLFW.GLFW_KEY_O,
                CATEGORY
        ));

        ClientTickEvents.END_CLIENT_TICK.register(client -> {
            if (openSettings.wasPressed()) {
                client.setScreen(new StreamChatSettingsScreen());
            }
        });

        HudElementRegistry.addLast(Identifier.of("streamchat", "chat_overlay"), ChatOverlay::render);
    }
}