by muon-rw
With that out of the way:
- Common Questions
- Quick Start: Recoloring Bars
- File Structure
- Texture Requirements
- Animation System
- Scaling System
- Combining Features
- Feature Matrix
- In-Game HUD Editor
- Troubleshooting
Q: How do I change bar colors?
A: Replace bar textures in a resource pack. See Quick Start.
Q: Can I make rounded bars, or other shapes
A: It's possible, but to do so, you'll need to each frame of the bar textures themselves (finding some way to automate this is highly recommended - Pixel Composer is great!)
Q: Can I use high-resolution (HD) textures?
A: Yes! The mod auto-detects texture dimensions. Use 512x2048 or any size. Power of 2 texture sizes are recommended!
Q: How do I add decorative borders to backgrounds?
A: Use nine-slice scaling with tile mode for borders.
Q: Do I need .mcmeta files?
A: No! The mod uses smart defaults. Only add .mcmeta to customize.
Q: What's the difference between texture size and rendered size?
A: Texture size = PNG file dimensions (256x1024). Rendered size = on-screen pixels (74x4). The mod scales automatically!
Q: Why can't I use nine-slice on bars?
A: Bars use UV sampling to show fill percentage. Use transparency in your bar textures for custom shapes!
Q: Can I mix features (HD + nine-slice)?
A: Yes! See Combining Features for examples.
Q: "How do I change bar colors?"
A: Replace the bar textures in a resource pack!
resourcepacks/
my_custom_bars/
pack.mcmeta
assets/
dynamic_resource_bars/
textures/
gui/
health_bar.png ← Replace this!
health_bar.png.mcmeta ← Optional: animation settings
stamina_bar.png ← Replace this!
mana_bar.png ← Replace this!
air_bar.png ← Replace this!
{
"pack": {
"pack_format": 15,
"description": "My Custom Bars"
}
}- Copy original textures from the mod's assets as a starting point
- Edit colors in your image editor (Photoshop, GIMP, Aseprite, etc.)
- Dimensions: Standard is 256 x 1024 (but any size works!)
- Want higher resolution? Use 512 x 2048! (update .mcmeta accordingly)
- Want smaller files? Use 128 x 512!
- Save as PNG with transparency support
- Place your resource pack in
.minecraft/resourcepacks/ - Enable it in-game (Options → Resource Packs)
- Press F3 + T to reload resource packs
- Your new colors appear instantly!
resourcepacks/
your_pack_name/
pack.mcmeta ← Required: pack metadata
pack.png ← Optional: pack icon
assets/
dynamic_resource_bars/
textures/
gui/
# === BAR TEXTURES ===
health_bar.png (256x1024 - 32 frames of 32px each)
health_bar.png.mcmeta (animation settings)
health_bar_poisoned.png (status variant)
health_bar_withered.png
health_bar_frozen.png
health_bar_scorched.png
stamina_bar.png (256x1024 - 32 frames)
stamina_bar.png.mcmeta
stamina_bar_warning.png
stamina_bar_critical.png
stamina_bar_hunger.png
stamina_bar_mounted.png
stamina_bar_blood.png
mana_bar.png (256x1024 - 32 frames)
mana_bar.png.mcmeta
air_bar.png (256x1024 - 32 frames)
air_bar.png.mcmeta
# === BACKGROUNDS ===
health_background.png (256x256 - static)
stamina_background.png
mana_background.png
air_background.png
# === FOREGROUNDS ===
health_foreground.png (256x256 - static overlay)
stamina_foreground.png
mana_foreground.png
# === STATUS OVERLAYS ===
absorption_overlay.png (256x256)
regeneration_overlay.png
protection_overlay.png
heat_overlay.png
cold_overlay.png
wetness_overlay.png
hardcore_overlay.png
comfort_overlay.png
nourishment_overlay.png
✨ Texture sizes are auto-detected! The mod reads your PNG dimensions automatically.
Recommended dimensions (standard, but not required):
| Texture Type | Standard Size | Format | Notes |
|---|---|---|---|
| Bar (animated) | 256 x 1024 | PNG + Alpha | 32 frames of 32px each (standard) |
| Bar (custom) | Any width x (height × frames) | PNG + Alpha | Width auto-detected, height ÷ frame height must be whole number |
| Background/Overlay | 256 x 256 | PNG + Alpha | Static (non-animated), standard size |
-
Texture width: Automatically detected from your PNG file
- Standard is 256px, but you can use 512px, 128px, or any size!
- UV calculations automatically adapt
-
Texture height: Automatically detected from your PNG file
- Must be evenly divisible by frame height from
.mcmeta - Example: 2048px texture ÷ 64px frame = 32 frames
- Must be evenly divisible by frame height from
Important distinction:
- Texture size: Dimensions of your PNG file (e.g., 256x1024)
- Rendered size: On-screen pixels (e.g., 74x4) - controlled by config/editor
- The mod automatically scales textures to fit rendered size!
- PNG with alpha channel (transparency)
- 8-bit RGBA recommended for file size
- No JPG (doesn't support transparency)
All bars support custom animations via .mcmeta files (standard Minecraft format).
File: health_bar.png.mcmeta
{
"animation": {
"frametime": 3,
"interpolate": false,
"height": 32
}
}| Property | Default | Description |
|---|---|---|
frametime |
3 | Ticks per frame (3 = 0.15s at 20 TPS). Lower = faster. |
interpolate |
false | Smooth blending between frames. Usually false for pixel art. |
height |
32 | Height of each frame in pixels. Total frames = texture height ÷ this. |
Fast animation (2 ticks per frame):
{
"animation": {
"frametime": 2,
"height": 32
}
}Slow animation (10 ticks per frame):
{
"animation": {
"frametime": 10,
"height": 32
}
}Large frames (64px, 16 total frames):
{
"animation": {
"frametime": 3,
"height": 64
}
}Note: Texture sheet must be 256 x 1024 (64 × 16 = 1024)
Static texture (no animation):
{
"animation": {
"frametime": 999999,
"height": 256
}
}Or omit .mcmeta entirely and make texture 256 x 32
All variants of a bar type share animation settings from the base .mcmeta:
health_bar_poisoned.png,health_bar_withered.png, etc. → usehealth_bar.png.mcmetastamina_bar_warning.png,stamina_bar_critical.png, etc. → usestamina_bar.png.mcmeta
This means: All variants must use the same frame height and dimensions!
✨ NEW: The mod auto-detects your texture dimensions!
You can now use:
- Standard: 256 x 1024 (32 frames of 32px)
- High-res: 512 x 2048 (32 frames of 64px)
- Compact: 128 x 512 (16 frames of 32px)
- Any size: As long as height ÷ frame_height is a whole number
The mod reads your PNG dimensions and adapts UV calculations automatically.
If no .mcmeta file is found:
- Uses default: 32 frames, 32px per frame, 3 ticks per frame
- Texture dimensions: Auto-detected from PNG (defaults to 256x1024 if missing)
Control how textures scale to fit different sizes using .mcmeta files!
Four modes available:
- None: No scaling (1:1 UV sampling, pixel-perfect)
- Stretch: Simple scaling to fit
- Tile: Repeat/pattern the texture
- Nine-slice: Scale with borders (stretch or tile edges/center)
{
"dynamic_resource_bars": {
"scaling": "none"
}
}- Samples texture at 1:1 ratio (no transforms)
- Samples exactly
width×heightpixels from texture - Best for: Icons, pixel-perfect overlays
- Original behavior before scaling was added
{
"dynamic_resource_bars": {
"scaling": "stretch"
}
}- Scales texture to fit render area
- Best for: Solid colors, gradients, simple overlays
{
"dynamic_resource_bars": {
"scaling": "tile"
}
}- Repeats texture pattern
- Best for: Repeating patterns, textures
{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 4,
"right": 4,
"top": 3,
"bottom": 3,
"edges": "stretch",
"center": "stretch"
}
}
}Nine regions:
┌──┬─────┬──┐
│TL│ Top │TR│ Corners = fixed size
├──┼─────┼──┤
│L │ C │R │ Edges = stretch or tile
├──┼─────┼──┤ Center = stretch or tile
│BL│ Bot │BR│
└──┴─────┴──┘
left/right/top/bottom: Border widths (pixels, fixed size)edges: "stretch" or "tile" (optional, default: stretch)center: "stretch" or "tile" (optional, default: stretch)source: Region to use (optional, defaults to full texture)u,v: Offset in texture (default: 0, 0)width,height: Size of region to use
Use cases:
| Use Case | Edges | Center | Example |
|---|---|---|---|
| Smooth background | stretch | stretch | Gradient borders |
| Decorative frame | tile | stretch | Ornate borders with pattern |
| Textured overlay | tile | tile | Heat/cold effects |
Important: If your actual graphic doesn't fill the entire texture sheet, you must specify the source region!
If your texture file is 256×256 but your actual graphic is only 80×10 in the corner, the mod will try to scale/tile the full 256×256 (including empty space). Use source to tell it where the real graphic is:
{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 2,
"right": 2,
"top": 2,
"bottom": 2,
"edges": "stretch",
"center": "stretch",
"source": {
"u": 0,
"v": 0,
"width": 80,
"height": 10
}
}
}
}Field meanings:
u: X offset in texture sheet (default: 0 = left edge)v: Y offset in texture sheet (default: 0 = top edge)width: Width of actual graphicheight: Height of actual graphic
Default placement: If u and v are omitted, defaults to (0, 0) = top-left corner
Examples:
// Graphic in top-left (most common)
"source": { "width": 80, "height": 10 } // u:0, v:0 implied
// Graphic at offset position
"source": { "u": 20, "v": 30, "width": 80, "height": 10 }
// Full sheet (no source needed)
// Omit "source" entirely if graphic fills entire sheetWhen to use:
- ✅ Small textures in large sheets (most bundled overlays are 80×10 in 256×256 sheets)
- ✅ Avoiding texture sheet resizing (which can cause UV issues)
- ✅ Keeping original file dimensions for compatibility
When NOT needed:
- ❌ Your graphic fills the entire texture sheet (e.g., full 256×256)
If you don't specify scaling, the mod applies smart defaults:
| Texture Type | Default Scaling |
|---|---|
| Backgrounds | nine-slice (4,4,3,3) with stretch |
| Foregrounds | nine-slice (4,4,3,3) with stretch |
| Animated overlays | nine-slice (3,3,2,2) with tile |
| Static overlays | simple stretch |
Why? Bars use:
- UV sampling to show fill percentage (not scaling)
- Applying nine-slice would require complex UV remapping per frame
What this means:
- ✅ Backgrounds, foregrounds, overlays → Can use nine-slice/tiling
- ❌ Bar animated textures → Use transparency for custom shapes instead
- ✅ Bar dimensions are capped at texture sheet width (auto-detected)
Goal: 2x resolution bars with smooth visuals
Files needed:
health_bar.png (512x2048)
health_bar.png.mcmeta
health_bar.png.mcmeta:
{
"animation": {
"frametime": 3,
"height": 64
}
}Steps:
- Create 512x2048 bar texture (double resolution)
- Add
.mcmetawith height: 64 - Reload and enjoy HD bars!
Why it works:
- Auto-detection reads 512x2048 dimensions
- Everything scales automatically!
Goal: Background with ornate border that preserves pattern
Files needed:
health_background.png (256x256)
health_background.png.mcmeta
health_background.png.mcmeta:
{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 8,
"right": 8,
"top": 6,
"bottom": 6,
"edges": "tile",
"center": "stretch"
}
}
}Design tips:
- Put decorative pattern in 8px left/right borders
- Put decorative pattern in 6px top/bottom borders
- Center can be solid color (will stretch)
- Corners (8x6) stay fixed
Result: Border pattern repeats perfectly, no matter the size!
Goal: Heat overlay that preserves fire texture pattern
Files needed:
heat_overlay.png (64x64)
heat_overlay.png.mcmeta
heat_overlay.png.mcmeta:
{
"dynamic_resource_bars": {
"scaling": "tile"
}
}Design tip: Create seamless tileable texture (edges wrap)
Result: Fire pattern tiles across bar width without stretching!
Goal: Full visual overhaul with custom everything
Files structure:
fantasy_pack/
pack.mcmeta
assets/dynamic_resource_bars/textures/gui/
# HD bars (512x2048)
health_bar.png
health_bar.png.mcmeta (animation)
# Decorative backgrounds (256x256)
health_background.png
health_background.png.mcmeta (nine-slice tile)
# Overlay foregrounds (256x256)
health_foreground.png
health_foreground.png.mcmeta (nine-slice stretch)
# Pattern overlays (64x64)
heat_overlay.png
heat_overlay.png.mcmeta (tile)
cold_overlay.png
cold_overlay.png.mcmeta (tile)
Features used:
- ✅ HD textures (512x2048 bars)
- ✅ Decorative borders (nine-slice tile)
- ✅ Patterned overlays (simple tile)
Result: Professional-grade themed resource pack!
Bars are rendered in multiple layers for visual depth and status effects.
- Background (
health_background.png) - Behind everything - Bar (
health_bar.png) - Main animated bar - Status Overlays - Applied over bar (absorption, regen, heat, etc.)
- Foreground (
health_foreground.png) - Frame/border on top
All layers are optional! Replace only what you want:
Minimal pack (just recolor bars):
assets/dynamic_resource_bars/textures/gui/
├── health_bar.png ← Only this! (256x1024 standard size)
High-res pack (2x resolution):
assets/dynamic_resource_bars/textures/gui/
├── health_bar.png ← 512x2048 (double resolution)
├── health_bar.png.mcmeta ← height: 64 (double frame size)
Full pack (complete visual overhaul):
assets/dynamic_resource_bars/textures/gui/
├── health_bar.png ← Animated bar (any size!)
├── health_background.png ← Frame/container
├── health_foreground.png ← Border overlay
├── absorption_overlay.png ← Status effects
└── regeneration_overlay.png
| Layer | Size | Alpha Channel |
|---|---|---|
| Background | 256 x 256 | Required |
| Foreground | 256 x 256 | Required |
| Overlays | 256 x 256 | Required (for transparency) |
Users can toggle layers via config:
enableHealthBackground(true/false)enableHealthForeground(true/false)enableStaminaBackground(true/false)- etc.
Resource pack tip: Design layers to work independently so users can mix and match!
Dynamic Resource Bars includes a powerful in-game editor for positioning and customizing bars.
In-game: Open via mod config menu
- Mods button → Dynamic Resource Bars → Config → "Open HUD Editor" button
- Click and drag any bar to reposition
- Real-time preview as you drag
- Snaps to pixel grid
- Tab: Cycle through bars
- Arrow keys: Move selected bar 1px at a time
- Shift + Arrow keys: Resize selected bar 1px at a time
- Green outline: Shows currently selected bar
Each bar has draggable sub-elements:
- Background (yellow outline when focused)
- Bar (green outline when focused)
- Foreground (magenta outline when focused)
- Text (cyan outline when focused)
Bars can anchor to screen regions:
- Top-left, Top-center, Top-right
- Middle-left, Middle-center, Middle-right
- Bottom-left, Bottom-center, Bottom-right
Why anchors matter: Bars stay in relative position when window resizes!
Toggle bar fill direction:
- Horizontal: Left-to-right (or right-to-left)
- Vertical: Bottom-to-top
✅ Best practices:
- Start with anchor point, then fine-tune with offsets
- Use keyboard for precise 1px adjustments
- Test at different window sizes
- Save often (editor auto-saves to config)
What works with what:
| Feature | Bars | Backgrounds | Foregrounds | Overlays |
|---|---|---|---|---|
| Custom animations | ✅ | ❌ | ❌ | ❌ |
| Auto-detected size | ✅ | ✅ | ✅ | ✅ |
| Nine-slice scaling | ❌ | ✅ | ✅ | ✅ |
| Tile mode | ❌ | ✅ | ✅ | ✅ |
Key insights:
- Bars = Animation with UV sampling for fill percentage
- Backgrounds/Foregrounds/Overlays = Nine-slice or Tile (full texture rendering)
- Bars don't scale because they use UV sampling to show fill percentage
{
"animation": {
"frametime": 3,
"height": 32
}
}{
"dynamic_resource_bars": {
"scaling": "none",
"source": {
"width": 80,
"height": 10
}
}
}{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 4,
"right": 4,
"top": 3,
"bottom": 3,
"edges": "stretch",
"center": "stretch"
}
}
}{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 2,
"right": 2,
"top": 2,
"bottom": 2,
"source": {
"width": 80,
"height": 10
}
}
}
}{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 3, "right": 3, "top": 2, "bottom": 2,
"edges": "tile",
"center": "tile"
}
}
}{
"dynamic_resource_bars": {
"scaling": "tile"
}
}Smart defaults are applied automatically based on texture type. Only add .mcmeta if you want to customize!
Checklist:
- Resource pack is enabled? (Options → Resource Packs)
- Pack is above vanilla in the list? (higher priority)
- File paths match exactly? (
dynamic_resource_bars/textures/gui/) - Files are named correctly? (
health_bar.png, nothealthbar.png) - Reloaded resource packs? (F3 + T)
Edit .mcmeta file:
- Too fast: Increase
frametime(try 5-10) - Too slow: Decrease
frametime(try 1-2) - Reload with F3 + T
Check these requirements:
- Height must be divisible: texture_height ÷ frame_height must be whole number
- Frame height in .mcmeta: Must match your actual frame size
- Rendered size: Config values are separate from texture size
Check image editor export settings:
- Use PNG-24 or PNG-32 (with alpha)
- Ensure sRGB color space
- Disable any "web optimization" that reduces colors
Check your border dimensions:
- Borders must be smaller than texture size
- Example: 8px borders need at least 16px texture (8+8)
- Use smaller borders for small textures
- Test: Temporarily set edges/center to "stretch" to verify dimensions
Your texture is smaller than the full sheet (e.g., 80x10 in 256x256 sheet).
Solution: Use source to specify the region:
{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 2, "right": 2, "top": 2, "bottom": 2,
"source": {
"width": 80,
"height": 10
}
}
}
}This tells the mod to only use the 80x10 region (starting at 0,0) instead of the full 256x256.
Your texture isn't seamless:
- Edges of texture must wrap perfectly
- Use "offset" in image editor to test wraparound
- Or use nine-slice with stretch instead of tile
- Many image editors have "make seamless" filters
Known limitation (tracked for future fix):
- Config sliders assume 256px texture width
- Workaround: Edit config file manually
.minecraft/config/dynamic_resource_bars-client.toml- Set
healthBarWidth = 512(or your texture width)
- Editor drag limits also assume 256px
- Future update will auto-detect max values from texture
- Check logs:
.minecraft/logs/latest.logfor error messages - Validation warnings: Mod logs dimension mismatches and missing textures
- Test with default: Disable your pack to verify mod works
- Share pack structure: Post your file tree when asking for help
- Mod config:
.minecraft/config/dynamic_resource_bars-client.toml - In-game editor: Access via config menu to customize positioning
- ✅ Texture auto-detection - Use any PNG size
- ✅ Nine-slice scaling - Tile/stretch modes for backgrounds and overlays
my_red_bars/
pack.mcmeta
assets/dynamic_resource_bars/textures/gui/
health_bar.png ← Red tinted (256x1024)
stamina_bar.png ← Red tinted (256x1024)
mana_bar.png ← Red tinted (256x1024)
hd_bars/
pack.mcmeta
assets/dynamic_resource_bars/textures/gui/
health_bar.png ← 512x2048 (double resolution)
health_bar.png.mcmeta ← height: 64 (double frame size)
stamina_bar.png ← 512x2048
stamina_bar.png.mcmeta ← height: 64
mana_bar.png ← 512x2048
mana_bar.png.mcmeta ← height: 64
recolor_pack/
pack.mcmeta
assets/dynamic_resource_bars/textures/gui/
health_bar.png ← 256x1024 recolored
stamina_bar.png ← 256x1024 recolored
mana_bar.png ← 256x1024 recolored
ornate_bars/
pack.mcmeta
assets/dynamic_resource_bars/textures/gui/
health_background.png ← 256x256 with decorative border
health_background.png.mcmeta ← Nine-slice with tile edges
health_foreground.png ← 256x256 gold frame
health_foreground.png.mcmeta ← Nine-slice with stretch
health_background.png.mcmeta:
{
"dynamic_resource_bars": {
"scaling": {
"type": "nine_slice",
"left": 8,
"right": 8,
"top": 6,
"bottom": 6,
"edges": "tile",
"center": "stretch"
}
}
}fantasy_bars/
pack.mcmeta
assets/dynamic_resource_bars/textures/gui/
health_bar.png ← Custom animated texture (any size)
health_bar.png.mcmeta ← Custom timing
health_background.png ← Ornate frame
health_background.png.mcmeta ← Nine-slice for scaling
health_foreground.png ← Gold border
health_foreground.png.mcmeta ← Nine-slice for scaling
absorption_overlay.png ← Custom effect
# ... and all other bars
| File | Dimensions | Required? | Notes |
|---|---|---|---|
health_bar.png |
256×1024 | ✅ Yes | Animated bar |
health_bar.png.mcmeta |
N/A | Animation | |
health_background.png |
256×256 | Frame/container | |
health_background.png.mcmeta |
N/A | Nine-slice | |
health_foreground.png |
256×256 | Border overlay | |
health_foreground.png.mcmeta |
N/A | Nine-slice |
Pattern: {bar_type}_{layer}.png where:
bar_type= health, mana, stamina, airlayer= bar, background, foreground, mask
| File | Dimensions | Notes |
|---|---|---|
health_bar.png |
512×2048 | Double resolution |
health_bar.png.mcmeta |
N/A | Must specify height: 64 |
health_background.png |
512×512 | Can be any size |
Bar texture height = frame_height × frame_count
Mask dimensions = bar_texture_width × frame_height
Background/overlay = Any size (will scale with nine-slice)
Standard: 256 × 1024 = 32 × 32 frames
HD 2x: 512 × 2048 = 64 × 32 frames
Compact: 128 × 512 = 32 × 16 frames
Pro tip: Check assets/dynamic_resource_bars/textures/gui/ in the mod for EXAMPLE_*.mcmeta files showing all features!