Mod

Mebahel's API

Quick rating

Mebahel's API

No reviews yet

Mebahel’s API is a core dependency mod that provides shared systems, utilities, and gameplay frameworks used across the Mebahel mod ecosystem.

API/Library
Mod Loaders
Forge
NeoForge
Fabric
Quilt
Minecraft

Community voices

Reviews

Versions
Loading versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your review has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

Compatibility

Supported Environments

Dev Environment
Client Required
Server Required

About

Project Details

Type
Mod
License
All Rights Reserved
Latest Version
mebahels-api-1.0.20-fabric-1.21.1
Authors
CurseForge
Modrinth

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

CurseForge ID
Modrinth ID

Resources

External Links

Source Issues Wiki Discord

About

Description

Mebahel’s API — Core Library for Mebahel Mods

Mebahel’s API is a core dependency mod that provides shared systems, utilities, and gameplay frameworks used across the Mebahel mod ecosystem.

It is designed for mod developers who want production-ready building blocks for complex mechanics without rewriting the same infrastructure in every project.

⚠️ This mod is a library. It does not add standalone gameplay content by itself.


Supported Versions

  • Minecraft 1.20.1 — Fabric
  • Minecraft 1.21.1 — Fabric

⭐ For Players & Modpack Users

This mod is a technical dependency used by other Mebahel mods.

What it does in a game

You normally won’t interact with this mod directly.
It runs in the background to make other mods work correctly and efficiently.

Depending on the mod that uses it, it may provide:

🌊 Dry Structure Generation

Structures can generate without being flooded, even underwater or inside wet terrain.

📦 Advanced Custom Chests

Some Mebahel mods use special chests powered by this API:

  • Animated opening and closing
  • Multiplayer-safe inventories
  • Optional per-player rewards (each player gets their own loot)
  • Custom sounds and GUI

⚔️ Improved Mob Behavior

Certain creatures may use advanced movement such as:

  • Strafing during combat
  • Tactical retreat when too close
  • More natural positioning
  • Reduced “stuck” behavior

Do I need this mod?

✔ Required if another mod lists it as a dependency
✔ Safe for singleplayer and multiplayer
✔ Must be installed on both client and server

❌ Removing it will break mods that depend on it


⭐ For Mod Developers

Mebahel’s API provides reusable systems intended to simplify the development of complex Fabric mods.

Main Systems Provided

🌊 Structure Water Removal System

Prevents structures from spawning flooded in oceans, rivers, or aquifers.

Capabilities

  • Removes waterlogged states after generation
  • Clears surrounding water blocks inside structure bounds
  • Works with template-based structures
  • Tick-budget safe (no lag spikes)
  • Fully automated once configured

📦 Advanced Animated Chest Framework

A complete foundation for creating custom containers with multiplayer-safe logic.

Includes

  • GeckoLib animated open/close/spawn sequences
  • Built-in sound synchronization
  • Custom GUI support
  • Server-authoritative behavior
  • Multiplayer compatibility
Personal Loot Mode

When using a loot table:

  • Each player receives individual rewards
  • Loot is generated once per player
  • Prevents duplication exploits
  • Ideal for dungeon or boss chests
Shared Inventory Mode

Without a loot table:

  • Functions as a normal container
  • Inventory shared between players

🖥️ Ready-to-Use GUI & Screen Handler

Speeds up development of container blocks:

  • Preconfigured ScreenHandler
  • Player inventory integration
  • Client GUI implementation
  • Minimal boilerplate required

⚔️ Entity Movement Utilities

Utility methods for advanced combat AI and movement behavior.

Supports:

  • Strafing around targets
  • Tactical retreat movement
  • Target-facing rotation
  • Jump assistance
  • Anti-stuck handling

Ideal for bosses, ranged mobs, constructs, or mechanical entities.


🧠 Why Use Mebahel’s API?

✔ Reduces duplicated code across multiple mods
✔ Optimized for server performance
✔ Multiplayer-safe systems
✔ Production-ready implementations
✔ Actively used in real released mods


🔧 Installation (Developers)

Add the API as a dependency in your Fabric mod project.

Maven Repository

repositories {
  maven {
    name = "GitLab-Mebahel"
    url = uri("https://gitlab.com/api/v4/projects/77311613/packages/maven")
  }
}

Dependency

dependencies {
    modImplementation "net.mebahelsapi:mebahels-api:<version>"
}

fabric.mod.json

{
  "depends": {
    "mebahels-api": "*"
  }
}

⚙️ Required Dependencies

  • Fabric Loader
  • Fabric API
  • GeckoLib (for animated blocks and entities)

Ensure versions match your Minecraft version.


📦 Used By

All Mebahel ecosystem mods depend on this API as their shared core library.


👨‍💻 Developer Guide — Integration

🌊 Water Removal Processor (Structures)

Automatically removes water and waterlogged states after structure generation.

Use cases

  • Ocean structures
  • Underground builds intersecting fluids
  • Ruins or dungeons that must remain dry

How to enable

Add the processor to your structure configuration:

"processors": "mebahelsapi:water_removal_processor"

The cleanup runs automatically after placement.
Server-side only.


📦 BaseChest Framework — Custom Animated Containers

Provides a ready-to-extend system for animated, synchronized chests.

Creating a Custom Chest

  1. Extend the base chest block
  2. Extend the base chest block entity
  3. Register them normally
  4. Configure title, sounds, and multiplayer behavior

Example — ChestBlockEntity:

public class DwemerChestBlockEntity extends BaseChestBlockEntity {
    public DwemerChestBlockEntity(BlockPos pos, BlockState state) {
        super(ModBlockEntities.DWEMER_CHEST_ENTITY, pos, state, 36);
    }

    @Override
    protected Text getChestTitle() {
        return Text.translatable("block.mebahelcreaturesdwarven.dwemer_chest");
    }

    @Override
    protected String getLogPrefix() {
        return "[DwemerChest]";
    }

    @Override
    @Environment(EnvType.CLIENT)
    public void playOpenSound() {
        playChestSound(ModSounds.DWARVEN_CHEST_OPEN);
    }

    @Override
    @Environment(EnvType.CLIENT)
    public void playCloseSound() {
        playChestSound(ModSounds.DWARVEN_CHEST_CLOSE);
    }

    @Override
    protected boolean isMultiplayerEnabled() {
        return ModMultiplayerChest.turnOnMultiplayerDraugrChest;
    }
}

Example — ChestBlock:

public class DwemerChestBlock extends BaseChestBlock {
    public DwemerChestBlock(AbstractBlock.Settings settings) {
        super(
                settings,
                () -> ModBlockEntities.DWEMER_CHEST_ENTITY,
                DwemerChestBlockEntity::new
        );
    }

    @Override
    protected boolean isMultiplayerEnabled() {
        return ModMultiplayerChest.turnOnMultiplayerDraugrChest;
    }
}

🏹 MovementUtil — Advanced AI Positioning

MovementUtil provides reusable helpers for combat movement, especially for ranged entities.

Typical responsibilities:

  • Keep the entity facing its target
  • Prevent pathfinding stalls
  • Maintain optimal distance
  • Control strafe and retreat behavior

Recommended usage pattern inside a Goal:

1) Validate target
2) Face the target
3) Run anti-stuck logic
4) Choose movement based on distance
5) Handle attack timing separately

Example — Shooting Goal (Draugr Archer):

public class DraugrArcherShootingGoal extends Goal {
    private final DraugrArcherEntity actor;
    private final MovementUtil movementUtil;
    private final double STRAFE_DISTANCE = 8;

    public DraugrArcherShootingGoal(DraugrArcherEntity actor) {
        this.actor = actor;
        this.movementUtil = new MovementUtil(this.actor);
    }

    @Override
    public void tick() {
        if (actor.isUsingPotion() || actor.getHealTicks() > 0) {
            actor.setShooting(false);
            actor.getNavigation().stop();
            return;
        }

        LivingEntity target = this.actor.getTarget();
        if (target == null || !target.isAlive()) {
            this.stop();
            return;
        }

        double distanceToTarget = this.actor.distanceTo(target);

        movementUtil.lookAtTarget(target, actor);
        movementUtil.checkIfStuck(target, actor);

        if (distanceToTarget <= STRAFE_DISTANCE) {
            movementUtil.moveBackward(target, actor);
        } else {
            movementUtil.strafeAroundTarget(target, actor);
        }

        // Shooting logic handled separately
    }
}

This separation keeps movement smooth while allowing precise control over attack timing and animations.


📜 Notes

  • This mod is a core library required by several Mebahel projects.
  • Removing it will cause dependent mods to fail to load or function incorrectly.
  • Safe for both singleplayer and dedicated server environments.
  • Does not add standalone gameplay content by itself.
  • Join the community on Discord: https://discord.com/invite/y8uC2NepkB

Mebahel’s API — Core Library for Mebahel Mods

Mebahel’s API is a core dependency mod that provides shared systems, utilities, and gameplay frameworks used across the Mebahel mod ecosystem.

It is designed for mod developers who want production-ready building blocks for complex mechanics without rewriting the same infrastructure in every project.

⚠️ This mod is a library. It does not add standalone gameplay content by itself.


Supported Versions

  • Minecraft 1.20.1 — Fabric
  • Minecraft 1.21.1 — Fabric

⭐ For Players & Modpack Users

This mod is a technical dependency used by other Mebahel mods.

What it does in a game

You normally won’t interact with this mod directly.
It runs in the background to make other mods work correctly and efficiently.

Depending on the mod that uses it, it may provide:

🌊 Dry Structure Generation

Structures can generate without being flooded, even underwater or inside wet terrain.

📦 Advanced Custom Chests

Some Mebahel mods use special chests powered by this API:

  • Animated opening and closing
  • Multiplayer-safe inventories
  • Optional per-player rewards (each player gets their own loot)
  • Custom sounds and GUI

⚔️ Improved Mob Behavior

Certain creatures may use advanced movement such as:

  • Strafing during combat
  • Tactical retreat when too close
  • More natural positioning
  • Reduced “stuck” behavior

Do I need this mod?

✔ Required if another mod lists it as a dependency
✔ Safe for singleplayer and multiplayer
✔ Must be installed on both client and server

❌ Removing it will break mods that depend on it


⭐ For Mod Developers

Mebahel’s API provides reusable systems intended to simplify the development of complex Fabric mods.

Main Systems Provided

🌊 Structure Water Removal System

Prevents structures from spawning flooded in oceans, rivers, or aquifers.

Capabilities

  • Removes waterlogged states after generation
  • Clears surrounding water blocks inside structure bounds
  • Works with template-based structures
  • Tick-budget safe (no lag spikes)
  • Fully automated once configured

📦 Advanced Animated Chest Framework

A complete foundation for creating custom containers with multiplayer-safe logic.

Includes

  • GeckoLib animated open/close/spawn sequences
  • Built-in sound synchronization
  • Custom GUI support
  • Server-authoritative behavior
  • Multiplayer compatibility
Personal Loot Mode

When using a loot table:

  • Each player receives individual rewards
  • Loot is generated once per player
  • Prevents duplication exploits
  • Ideal for dungeon or boss chests
Shared Inventory Mode

Without a loot table:

  • Functions as a normal container
  • Inventory shared between players

🖥️ Ready-to-Use GUI & Screen Handler

Speeds up development of container blocks:

  • Preconfigured ScreenHandler
  • Player inventory integration
  • Client GUI implementation
  • Minimal boilerplate required

⚔️ Entity Movement Utilities

Utility methods for advanced combat AI and movement behavior.

Supports:

  • Strafing around targets
  • Tactical retreat movement
  • Target-facing rotation
  • Jump assistance
  • Anti-stuck handling

Ideal for bosses, ranged mobs, constructs, or mechanical entities.


🧠 Why Use Mebahel’s API?

✔ Reduces duplicated code across multiple mods
✔ Optimized for server performance
✔ Multiplayer-safe systems
✔ Production-ready implementations
✔ Actively used in real released mods


🔧 Installation (Developers)

Add the API as a dependency in your Fabric mod project.

Maven Repository

repositories {
  maven {
    name = "GitLab-Mebahel"
    url = uri("https://gitlab.com/api/v4/projects/77311613/packages/maven")
  }
}

Dependency

dependencies {
    modImplementation "net.mebahelsapi:mebahels-api:<version>"
}

fabric.mod.json

{
  "depends": {
    "mebahels-api": "*"
  }
}

⚙️ Required Dependencies

  • Fabric Loader
  • Fabric API
  • GeckoLib (for animated blocks and entities)

Ensure versions match your Minecraft version.


📦 Used By

All Mebahel ecosystem mods depend on this API as their shared core library.


👨‍💻 Developer Guide — Integration

🌊 Water Removal Processor (Structures)

Automatically removes water and waterlogged states after structure generation.

Use cases

  • Ocean structures
  • Underground builds intersecting fluids
  • Ruins or dungeons that must remain dry

How to enable

Add the processor to your structure configuration:

"processors": "mebahelsapi:water_removal_processor"

The cleanup runs automatically after placement.
Server-side only.


📦 BaseChest Framework — Custom Animated Containers

Provides a ready-to-extend system for animated, synchronized chests.

Creating a Custom Chest

  1. Extend the base chest block
  2. Extend the base chest block entity
  3. Register them normally
  4. Configure title, sounds, and multiplayer behavior

Example — ChestBlockEntity:

public class DwemerChestBlockEntity extends BaseChestBlockEntity {
    public DwemerChestBlockEntity(BlockPos pos, BlockState state) {
        super(ModBlockEntities.DWEMER_CHEST_ENTITY, pos, state, 36);
    }

    @Override
    protected Text getChestTitle() {
        return Text.translatable("block.mebahelcreaturesdwarven.dwemer_chest");
    }

    @Override
    protected String getLogPrefix() {
        return "[DwemerChest]";
    }

    @Override
    @Environment(EnvType.CLIENT)
    public void playOpenSound() {
        playChestSound(ModSounds.DWARVEN_CHEST_OPEN);
    }

    @Override
    @Environment(EnvType.CLIENT)
    public void playCloseSound() {
        playChestSound(ModSounds.DWARVEN_CHEST_CLOSE);
    }

    @Override
    protected boolean isMultiplayerEnabled() {
        return ModMultiplayerChest.turnOnMultiplayerDraugrChest;
    }
}

Example — ChestBlock:

public class DwemerChestBlock extends BaseChestBlock {
    public DwemerChestBlock(AbstractBlock.Settings settings) {
        super(
                settings,
                () -> ModBlockEntities.DWEMER_CHEST_ENTITY,
                DwemerChestBlockEntity::new
        );
    }

    @Override
    protected boolean isMultiplayerEnabled() {
        return ModMultiplayerChest.turnOnMultiplayerDraugrChest;
    }
}

🏹 MovementUtil — Advanced AI Positioning

MovementUtil provides reusable helpers for combat movement, especially for ranged entities.

Typical responsibilities:

  • Keep the entity facing its target
  • Prevent pathfinding stalls
  • Maintain optimal distance
  • Control strafe and retreat behavior

Recommended usage pattern inside a Goal:

  1. Validate target
  2. Face the target
  3. Run anti-stuck logic
  4. Choose movement based on distance
  5. Handle attack timing separately

Example — Shooting Goal (Draugr Archer):

public class DraugrArcherShootingGoal extends Goal {
    private final DraugrArcherEntity actor;
    private final MovementUtil movementUtil;
    private final double STRAFE_DISTANCE = 8;

    public DraugrArcherShootingGoal(DraugrArcherEntity actor) {
        this.actor = actor;
        this.movementUtil = new MovementUtil(this.actor);
    }

    @Override
    public void tick() {
        if (actor.isUsingPotion() actor.getHealTicks() > 0) {
actor.setShooting(false);
actor.getNavigation().stop();
return;
} LivingEntity target = this.actor.getTarget();
if (target == null
!target.isAlive()) { this.stop(); return; } double distanceToTarget = this.actor.distanceTo(target); movementUtil.lookAtTarget(target, actor); movementUtil.checkIfStuck(target, actor); if (distanceToTarget <= STRAFE_DISTANCE) { movementUtil.moveBackward(target, actor); } else { movementUtil.strafeAroundTarget(target, actor); } // Shooting logic handled separately } }

This separation keeps movement smooth while allowing precise control over attack timing and animations.


📜 Notes

  • This mod is a core library required by several Mebahel projects.
  • Removing it will cause dependent mods to fail to load or function incorrectly.
  • Safe for both singleplayer and dedicated server environments.
  • Does not add standalone gameplay content by itself.
  • Join the community on Discord: https://discord.com/invite/y8uC2NepkB

Screenshots

Gallery

This project has no gallery images yet.

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Ratings
0
Followers
0
In stacks

By the numbers

Statistics

~410,000
Total Downloads
CurseForge
~390,000
Modrinth
~24,000
Last Updated
CurseForge
Created
CurseForge
Modrinth
Last synced
When ModDex last fetched and imported data for this project from CurseForge or Modrinth. High-traffic and active projects are checked more often.
Next pipeline sync