ganesh Sinha

Create a simple Minecraft Bedrock Edition (MCPE) Bodyguard Add-On as an MVP.

Bodyguard

Add a recruitable NPC called Bodyguard. It should have a tactical appearance and use a P90-style fictional Minecraft weapon to attack hostile entities.

Commands

When the player interacts with the Bodyguard, provide these commands:

  • Follow Me — Bodyguard follows the player.
  • Stay Here — Bodyguard stays at its current location.
  • Attack — Bodyguard attacks a nearby hostile entity.
  • Don't Attack — Bodyguard stops attacking.
  • Defend Me — Bodyguard attacks hostile entities that attack the player.

Basic AI

  • Follow the player when ordered.
  • Attack hostile mobs when ordered or when defending the player.
  • Never attack the player.
  • Do not attack passive/friendly mobs.
  • Have reasonable health and attack cooldown.
  • If the Bodyguard becomes stuck or extremely far away, return it near the player.

Technical Requirements

Make this a proper Bedrock Add-On using a Behavior Pack and Resource Pack.

Keep it:

  • Lightweight
  • Mobile/MCPE friendly
  • Simple to install
  • Compatible with as many Bedrock versions as realistically possible
  • Free of unnecessary features

First create the minimum working version with the Bodyguard, basic AI, commands, and attack system. Do not add advanced UI, ammunition systems, complex animations, or extra features yet.

Provide the required folder structure and complete files/code needed to test the MVP.

Kodari AI
KodariSep 15 at 2:10 am 1
BodyguardAddon
A lightweight Minecraft Bedrock Edition add-on that adds a recruitable Bodyguard NPC with tactical appearance and P90-style weapon. Players can command it via interaction menu to follow, stay, attack hostile entities, defend the player, or cease attacks. The Bodyguard uses basic AI to follow and protect the player, never attacks players or passive mobs, and auto-returns if stuck or too far. Includes behavior and resource packs, optimized for mobile performance and broad version compatibility.
  1. Create the Behavior Pack with the Bodyguard entity, tame/recruit flow, command interactions, AI modes, and projectile.

  2. Create the Resource Pack with the tactical-style model, weapon geometry, projectile rendering, and translations.

  3. Add installation and testing instructions for the complete add-on.

Created the complete Bedrock Edition Bodyguard MVP:

  • Bodyguard_BP/

    • Recruitable bodyguard:bodyguard entity

    • Follow, stay, attack, don’t attack, and defend modes

    • Hostile-only targeting

    • Owner-defense behavior

    • 40 health and ranged projectile attacks

    • Custom projectile entity

    • Loot table

    • Behavior Pack manifest

  • Bodyguard_RP/

    • Tactical-style Bodyguard geometry

    • Backpack, helmet, armor, and P90-style weapon geometry

    • Projectile geometry

    • Entity render controllers

    • Localization files

    • Resource Pack manifest

  • README.md

    • Installation instructions

    • Folder structure

    • Summon and testing commands

    • Feature overview

Test with:

Mcfunction
/summon bodyguard:bodyguard

Then use an emerald to recruit the Bodyguard and interact with it to select its commands.

Kodari can make mistakes. Review important code before using.
Files
Bodyguard_BP
Bodyguard_RP
README.md
Code
13 649
Bodyguard_RP/entity/bodyguard_bullet.entity.json
{
  "format_version": "1.10.0",
  "minecraft:client_entity": {
    "description": {
      "identifier": "bodyguard:bullet",
      "materials": {
        "default": "entity_alphatest"
      },
      "textures": {
        "default": "textures/entity/iron_golem/iron_golem"
      },
      "geometry": {
        "default": "geometry.bodyguard_bullet"
      },
      "render_controllers": ["controller.render.bodyguard"]
    }
  }
}