DAI 4.1 · LEVEL 0 · CHAPTER 5

Your First DAI Project

Build a tiny known-good DAI ADDON manually or in Creator, then prove the edit → reload → visible result loop.

No coding experience requiredCopyable examplesDAI 4.1

Goal: one visible DAI-controlled result.

This project is intentionally tiny. It overrides one visible DAI System-menu resource with a button that dispatches your own action definition. You will know the pack is working because pressing the button produces a chat message.

Download the known-good starter: My_First_DAI_Project_v1.0.0.zip. Open it and compare its tree to the steps below.

Project tree

My_First_DAI_Project_v1.0.0.zip
├─ pack.mcmeta
└─ data/
   ├─ decisions_and_impulses/
   │  └─ menus/
   │     └─ systems/
   │        └─ default.json
   └─ my_first_dai/
      └─ logics/
         └─ definitions/
            └─ hello.json

Step 1 — identify the pack

pack.mcmeta
{
  "pack": {
    "description": "My First DAI Project",
    "min_format": [107, 1],
    "max_format": 107
  },
  "dai": {
    "role": "addon",
    "pack_id": "my_first_dai",
    "version": "1.0.0"
  }
}

role: addon means this project adds functionality without claiming an entire DAI game/save. Keep pack_id stable across future releases.

Step 2 — create your action

data/my_first_dai/logics/definitions/hello.json
{
  "type": "sequence",
  "sequence": [
    {
      "type": "run_command",
      "action": "say Hello from my DAI pack"
    }
  ]
}

The filename becomes the resource path, so this definition is addressed as my_first_dai:hello.

Step 3 — put the action on a visible button

data/decisions_and_impulses/menus/systems/default.json
{
  "priority": 100,
  "buttons": [
    {
      "slot": 0,
      "id": "my_first_dai_button",
      "text": "SAY HELLO",
      "action": "my_first_dai:hello",
      "style": {
        "background": "#1A0D16",
        "hover": "#3A1729",
        "selected": "#59213C",
        "text": "#FFF2E8",
        "border": "#FF8A2A"
      }
    }
  ]
}
Why the DAI namespace here? This learning exercise intentionally overrides DAI's built-in systems/default menu resource. Original content normally belongs in your own namespace.

Step 4 — test it

  1. Install/enable the datapack in a disposable test world.Chapter 7 shows every install location.
  2. Run /reload.Wait for reload to finish and check chat/logs for errors.
  3. Open the DAI System menu.Use the normal DAI menu key unless the active experience has remapped/owned that input.
  4. Press SAY HELLO.The action should dispatch say Hello from my DAI pack.
  5. Change only the button text.Reload again. This proves your edit → reload → result loop.

Build the same shell in Creator

  1. Create a new datapack project.Choose ADDON for this exercise.
  2. Set stable identity.Use namespace/pack ID my_first_dai and version 1.0.0.
  3. Use Universal Files for the two learning files.Add the logic definition and menu override at the exact paths above.
  4. Validate.Fix syntax/path errors before export.
  5. Export the standard datapack ZIP.Open the ZIP and confirm pack.mcmeta is at its root.

The important lesson is that Creator and hand-authored files produce the same normal pack structure.

Now make it yours

Duplicate hello.json, give the new file a new stable ID, and replace the command. Then use the Module Guide or Create Anything when your idea needs a real item, entity, menu, quest, vehicle, world or other system.

Continue into DAI 4.1

How-To Guide Index · Complete 4.1 Capabilities