M

an mc builder bot that can build rooms (no credits), if you hit it it will open a menu , enter what you wanna build , place a door and it will make building noises if they stop , you build is finished , it can even add custom mobs and co [refference video : https://www.youtube.com/watch?v=dU9pjJQLXPE]

Kodari AI
KodariSep 16 at 2:03 pm 1
BuilderBotRooms
A Minecraft Fabric mod that adds a builder bot NPC. When hit, it opens a GUI menu where players select a room design to build. The bot then constructs the room block-by-block, emitting building noises while working. If the player stops interacting, the bot pauses; once complete, the build finishes. The bot can also spawn custom mobs and supports additional customization options.

Created the Fabric 1.20.4 Builder Bot mod.

Features:

  • /builderbot spawns an invulnerable Builder Bot.

  • Hitting the bot opens a client-side build request menu.

  • Enter prompts such as:

    • small stone room

    • large brick room with a zombie

    • wood house with a creeper

  • Place a door within 8 blocks of the bot to begin construction.

  • Builds floors, walls, ceilings, windows, and torches.

  • Plays construction sounds while building.

  • Stops sounds and reports completion when finished.

  • Supports requested zombie, skeleton, cow, and creeper spawns.

  • No credit or economy system included.

M

The compilation failed with this error:

code
Compilation failed with 2 error(s):

ERROR in src/main/java/com/kodari/builderbot/BuilderBotClient.java at line 73: method renderBackground in class Screen cannot be applied to given types;
            this.renderBackground(context);
                ^

ERROR in   src/main/java/com/kodari/builderbot/BuilderBotClient.java at line 73: method renderBackground in class Screen cannot be applied to given types;
              this.renderBackground(context);
                  ^


=== COMPILATION ERROR ANALYSIS ===

FILES TO INVESTIGATE:
  - src/main/java/com/kodari/builderbot/BuilderBotClient.java
  -   src/main/java/com/kodari/builderbot/BuilderBotClient.java

Please fix this error by creating a new artifact with the corrected code.

Kodari AI
KodariSep 16 at 2:05 pm 1

Fixed BuilderBotClient.java by updating renderBackground to use the Fabric 1.20.4 signature:

Java
this.renderBackground(context, mouseX, mouseY, delta);

The corrected artifact has been applied.

M

make it with a REAL ai and add custom item , more support (the ai mods for you )

Kodari AI
KodariSep 16 at 2:26 pm 2
  1. Add a real, configurable AI planning layer for natural-language build requests.

  2. Add a custom Builder Bot item for obtaining/spawning the bot.

  3. Expand build support and document the configuration/setup needed for AI providers.

  • The current bot uses substring matching only; I’m replacing that planner boundary with an asynchronous OpenAI-compatible HTTP planner.

  • The AI output will be constrained to validated room dimensions, supported blocks, and a safe mob allowlist, with a built-in fallback when no API key is configured.

  1. AI planner: added the async provider integration, validation, fallback planner, and expanded materials/mob options.

  2. Custom item: next I’m adding a reusable Builder Wand, right-click interaction, item registration, creative-tab entry, model, and a command to obtain it.

  1. Support expansion: I’m making the AI layer work with OpenAI-compatible services beyond one vendor, including local unauthenticated endpoints such as Ollama, while keeping the safe fallback and generated configuration.Implemented the Builder Bot AI upgrade.

  • Added a real asynchronous AI planner using Java’s HTTP client.

  • Supports OpenAI-compatible APIs, including OpenAI, Ollama, LM Studio, and other compatible endpoints.

  • Added safe validation for AI responses:

    • Room width/depth: 5–15 blocks

    • Room height: 4–8 blocks

    • Supported materials

    • Supported mobs: zombie, skeleton, creeper, and cow

  • Added automatic fallback planning if the AI service is unavailable.

  • Expanded materials:

    • Oak, spruce, and birch planks

    • Bricks

    • Stone bricks

    • Cobblestone

    • Deepslate bricks

    • Quartz

    • Glass

  • Added AI options for windows and torches.

  • Added the custom Builder Wand item.

  • Right-clicking the Builder Bot with the wand opens the build menu.

  • Added /builderbot item to obtain the wand.

  • Added item model and translation files.

  • Added optional unauthenticated support for local AI servers.

Configuration is generated automatically at:

Plain Text
config/builderbot-ai.properties

For OpenAI:

Properties
endpoint=https://api.openai.com/v1/chat/completions
model=gpt-4o-mini
api-key=YOUR_API_KEY
allow-unauthenticated=false

Or use an environment variable instead:

Plain Text
BUILDERBOT_AI_KEY=YOUR_API_KEY

For Ollama:

Properties
endpoint=http://localhost:11434/v1/chat/completions
model=llama3.1
api-key=
allow-unauthenticated=true

The AI is restricted to safe build plans and cannot execute arbitrary commands or place unrestricted blocks.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
gradle.properties
settings.gradle
Code
13 804
src/main/java/com/kodari/builderbot/BuilderBotClient.java
package com.kodari.builderbot;

import net.fabricmc.api.ClientModInitializer;
import net.fabricmc.fabric.api.client.networking.v1.ClientPlayNetworking;
import net.fabricmc.fabric.api.networking.v1.PacketByteBufs;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.gui.widget.ButtonWidget;
import net.minecraft.client.gui.widget.TextFieldWidget;
import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.network.PacketByteBuf;
import net.minecraft.text.Text;
import org.lwjgl.glfw.GLFW;

public final class BuilderBotClient implements ClientModInitializer {
    @Override
    public void onInitializeClient() {
        ClientPlayNetworking.registerGlobalReceiver(BuilderBotMod.OPEN_MENU_ID, (client, handler, buf, responseSender) -> {
            String prompt = buf.readString(256);
            client.execute(() -> client.setScreen(new BuilderScreen(prompt)));
        });
    }

    private static final class BuilderScreen extends Screen {
        private final String prompt;
        private TextFieldWidget input;

        private BuilderScreen(String prompt) {
            super(Text.literal("Builder Bot"));
            this.prompt = prompt;
        }

        @Override
        protected void init() {
            int center = this.width / 2;
            this.input = new TextFieldWidget(this.textRenderer, center - 140, 62, 280, 20, Text.literal("Build request"));
            this.input.setMaxLength(256);
            this.input.setSuggestion("small stone room with a zombie");
            this.input.setFocused(true);
            this.addDrawableChild(this.input);
            this.addDrawableChild(ButtonWidget.builder(Text.literal("Build"), button -> submit())
                    .dimensions(center - 50, 95, 100, 20)
                    .build());
        }

        private void submit() {
            String value = this.input.getText().trim();
            if (value.isEmpty()) {
                return;
            }
            PacketByteBuf buf = PacketByteBufs.create();
            buf.writeString(value, 256);
            ClientPlayNetworking.send(BuilderBotMod.SUBMIT_BUILD_ID, buf);
            this.close();
        }

        @Override
        public boolean keyPressed(int keyCode, int scanCode, int modifiers) {
            if (keyCode == GLFW.GLFW_KEY_ENTER) {
                submit();
                return true;
            }
            return super.keyPressed(keyCode, scanCode, modifiers);
        }

        @Override
        public void close() {
            MinecraftClient.getInstance().setScreen(null);
        }

        @Override
        public void render(net.minecraft.client.gui.DrawContext context, int mouseX, int mouseY, float delta) {
            this.renderBackground(context, mouseX, mouseY, delta);
            context.drawCenteredTextWithShadow(this.textRenderer, Text.literal(this.prompt), this.width / 2, 35, 0xFFFFFF);
            super.render(context, mouseX, mouseY, delta);
        }

        @Override
        public boolean shouldPause() {
            return false;
        }
    }
}