#JSON-UI General

1 messages · Page 32 of 1

jolly rock
#

Oh I see

hybrid aurora
#

j'ai l'idée mais je sais pas comment m'y prendre

last pollen
#

att je te send le code

jolly rock
#

Use hover binding on the image panel and check if hover_text = '', if not, hide it

#
"bindings": [
    {
        "binding_name": "#hover_text",
        "binding_type": "collection",
        "binding_collection_name": "$item_collection_name"
    },
    {
        "binding_type": "view",
        "source_property_name": "(#hover_text = '')",
        "target_property_name": "#visible"
    }
]```
#

But you need to add your image inside of the container

hybrid aurora
#

it works, thank you for your help !

tawny gale
#

I'm looking at having a custom form with one half scrollable and the other half a set of buttons!! do i need to have i have a main stack_panel with 2 controls, one for the scroll panel and one for the button panel??

tawny gale
#

living up to that name of yours!! thanx goosedance

jaunty smelt
#

yall gave me no brainer awnsers like show me an example

idle oar
#

When referencing an existing namespace, can you change its pre-existing values within a new namespace it is referenced in?

For example, I want to change the button textures without changing the original button template. I want to use a new namespace that takes all properties of that template and update only the texture properties. Is it possible?

oak verge
quaint raptor
#

If I want to create a background like this, where do I start?

idle oar
# oak verge yeah in your template do "$var_name|default":"texture/..." "texture":"$var_name"...

I couldn't get it work. Using "texture" throws an error:

    "$toggle_view_binding_name": "custom_button_toggle",
    "$glyph_texture": "textures/ui/custom_icon",
    "$glyph_color_texture": "textures/ui/custom_icon",
    "$glyph_size": [ 17, 17 ],
    "$button_text": "Custom Text Button",
    "$toggle_property_bag": {
      "#panel_title": "Custom Text Panel"
    },
    "$default_texture|default":"textures/ui/button_purple",
    "texture":"$default_texture"
  },```

I'm trying to change the textures from "[email protected]" btw.
idle oar
# oak verge what error
Unknown properties found in def[custom_button] from namespace[general_section]
- Unknown property [texture]
----------------------------------------------------```
oak verge
#

list of the vanilla vars you can change```json
"$unchecked_control|default": "common_toggles.toggle_unchecked",
"$checked_control|default": "common_toggles.toggle_checked",
"$unchecked_hover_control|default": "common_toggles.toggle_unchecked_hover",
"$checked_hover_control|default": "common_toggles.toggle_checked_hover",
"$unchecked_locked_control|default": "common_toggles.toggle_locked",
"$unchecked_locked_hover_control|default": "common_toggles.toggle_locked",
"$checked_locked_control|default": "common_toggles.toggle_locked",
"$checked_locked_hover_control|default": "common_toggles.toggle_locked",

"$default_texture|default": "textures/ui/button_borderless_light",
"$hover_texture|default": "textures/ui/button_borderless_lightpressednohover",
"$pressed_texture|default": "textures/ui/button_borderless_lighthover",
"$pressed_no_hover_texture|default": "textures/ui/button_borderless_lightpressed",
"$locked_texture|default": "textures/ui/disabledButtonNoBorder",
idle oar
# oak verge you want to change the toggle texture right?

Yeah. I tried to do it like this but it didn't do anything either. Am I missing something?

    "$toggle_view_binding_name": "custom_button_toggle",
    "$glyph_texture": "textures/ui/custom_icon",
    "$glyph_color_texture": "textures/ui/custom_icon",
    "$glyph_size": [ 17, 17 ],
    "$button_text": "Custom Button Text",
    "$toggle_property_bag": {
      "#panel_title": "Custom Panel Text"
    },
    "controls": [
      {
        "custom_button_ref@settings_common.section_toggle_base": {
          "anchor_from": "top_left",
          "anchor_to": "top_left",
          "size": [ "100%", "30px" ],
          "$button_size_override": [ "100%", "100% + 1px" ],
          "$button_type_panel": "settings_common.toggle_button_control",
      
          "$radio_toggle_group": true,
          "$toggle_name": "navigation_tab",
          "$toggle_group_default_selected": "$default_selector_toggle_index",
      
          "$toggle_tab_focus_binding_type": "global",
          "$toggle_tab_focus_binding_name": "#navigation_tab_focus_precedence",
          "$toggle_on_hover_binding_type": "global",
          "$toggle_on_hover_binding_name": "#toggle_on_hover",
          "$toggle_tts_toggle_on_text": "accessibility.state.selected",
          "$toggle_tts_toggle_off_text": "accessibility.state.unselected",
          "$toggle_tts_name": "accessibility.tab.tts.title",

          "$default_texture|default": "textures/ui/button_purple",
          "$hover_texture|default": "textures/ui/button_purple",
          "$pressed_texture|default": "textures/ui/button_purple",
          "$pressed_no_hover_texture|default": "textures/ui/button_purple",
          "$locked_texture|default": "textures/ui/button_purple"
        }
      }
    ]
  }```
oak verge
idle oar
oak verge
#

np

lament kraken
#

i couldnt find magical item 😦

last pollen
#

is the minecraft bedrock creator thing ui all json?

last pollen
oak verge
#

ore ui

last pollen
#

what is that

rocky quail
pearl fable
#

Can someone help me? I created a file called "pod" and pasted the default minecraft long_form into it. However, when I create a ui with text_field or anything other than just .body and .button, the menu becomes invisible.

      },
      {"pod@long_form": {
        "bindings": [
          {
            "binding_name": "#title_text",
            "binding_type": "global"
          },
          {
            "binding_type": "view",
            "source_property_name": "(not (#title_text = '§l§fSTATUS'))",
            "target_property_name": "#visible"
          }
        ]
      }},```
normal moat
pearl fable
nocturne python
#

Pressing the Play button may redirect you to a specific server.

livid vault
#

Is there any way to make a button in UI because I'm making that if you click it it summon TNT for now if it possible

quartz axle
#

is it possible to split string in json ui?
like

'You:Know'

split ":"

into 'You'
and 'Know'

and make it to be variable?
$1 = 'You'
$2 = 'Know'

tropic badger
#

number is possible but not string

safe geyser
#

@oak verge can U give me JsonUI maker owner discord

#

I'm gonna request him to get it bc I really need that tool

oak verge
safe geyser
oak verge
#

no

safe geyser
#

..

safe geyser
oak verge
#

no idea

safe geyser
#

So we can still use it soon?

oak verge
#

welp
he said he is going to release it more then month ago
and he didn't, so i can't say for sure

mental crystal
#

Ngl, I tried that website it's kinda good... I just don't like the UI they used (white) and functionality wise it's nice

safe geyser
safe geyser
dire holly
#

why this doesn't work pls ?? json "bindings": [ { "binding_name": "#title_text" }, { "binding_type": "view", "source_property_name": "((#title_text - 'Phone') = #title_text) or ((#title_text - 'Banque') = #title_text)", "target_property_name": "#visible" } ]

jolly rock
#

Just do
((#title_text - 'Phone' - 'Banque') = #tilte_text)

vernal jacinth
#

Anyone know how to make ui’s

dire holly
#

hmmmmmhmh

dire holly
#

like on your screen

#

or forms

vernal jacinth
#

Like Vex essentials type ui

dire holly
#

ahhhhh

vernal jacinth
#

Anyone?

jolly rock
#

What are the Vex essentials UI like?

dire holly
#

ask in #1067535382285135923 and this look like something like this in your script:

import { ActionFormData } from '@minecraft/server-ui';

const form = new ActionFormData()
    .title("Form title")
    .body("Form body")
    .button('button 1')
    .button('button 3')
    .button('button 2');
form.show(source).then((response) => {
    if (response.selection === 0) {}
    else if (response.selection === 1) {}
    else if (response.selection === 2) {}
}); break;
dire holly
vernal jacinth
#

@jolly rock

#

Check DM’s

jolly rock
dire holly
#

in game*

jolly rock
#

User friendly

dire holly
#

yep :')

jolly rock
#

I think i can

#

I do ui's like this

neat sequoia
#

how can i set a image based on a form_button_text? Example:

"image": {
  "type": "image",
  "texture": "#form_button_text",
  "size": ["50%", "50%"],
  "bindings": [
    {
      "binding_name": "#form_button_text",
      // Bindings collection
    }
  ]
}

something like this

mental crystal
#
"image": {
  "type": "image",
  "texture": "#texture",
  "size": ["50%", "50%"],
  "bindings": [
    {
      "binding_name": "#form_button_text"
    },
    {
      "binding_type": "view",
      "source_property_name": "#form_button_text",
      "target_property_name": "#texture"
    }
  ]
}
#

Maybe like this? I'm not kinda sure... Try putting the path of the textures in the button name you want to see.

neat sequoia
#

ok, it works ty

#

😘

oak verge
#

bindings is my json ui weakness

mental crystal
oak verge
#

nah, you seem to be doing fine

jaunty smelt
#

can smone show me an example on how to add a tooltip to a long form button instead of telling me to put it in hover control .

oak verge
#

check herobrine chest form

jaunty smelt
oak verge
quartz axle
jaunty smelt
jaunty smelt
#

its not the buttons control i needed to put the tooltip in

#

it was the texture

torpid axle
#

How does JSON-UI works?

safe geyser
#
{
    "namespace": "server_form",
    "long_form": {
        "type": "panel",
        "size": [
            "100%",
            "100%"
        ],
        "controls": [
            {
                "long_form@common_dialogs.main_panel_no_buttons": {
                    "$title_panel": "common_dialogs.standard_title_label",
                    "$title_size": [
                        "100% - 14px",
                        10
                    ],
                    "size": [
                        400,
                        200
                    ],
                    "$text_name": "#title_text",
                    "$title_text_binding_type": "none",
                    "$child_control": "server_form.long_form_panel",
                    "layer": 2,
                    "bindings": [
                        {
                            "binding_name": "#title_text"
                        },
                        {
                            "binding_type": "view",
                            "source_property_name": "(#title_text = 'JsonUI')",
                            "target_property_name": "#visible"
                        }
                    ]
                }
            }
        ]
    }
}

Guys how I give it a custom title

#

For the exp source name is JsonUI I hope it displays custom text

mortal monolith
#

Happy new year

hasty hamlet
#

hi there, happy new year 🙂

do someone know if it is possible to save the output of a binding into a variable? like so? json "city@profile_sheet.line_label_value": { "$label_text": "#label_text", "$value_text": "#value_text", "bindings": [ { "binding_type": "view", "source_property_name": "(('%.26s' * #title_text) - ('%.10s' * #title_text))", "target_property_name": "#label_text" }, { "binding_type": "view", "source_property_name": "(('%.657s' * #title_text) - ('%.638s' * #title_text))", "target_property_name": "#value_text" } ] }

turbid nimbus
#

oh yeah, thanks for hardcored index 👍

#

I think scanning bedrock samples for Json-UI info is fun

quartz axle
#

@oak verge hi bro i saw u in a post using 3d structure renderer how to use the 3d structure as a map?

turbid nimbus
#

Json-UI is not bad in some moments

quartz axle
turbid nimbus
#

Everything has its pros and cons

quartz axle
#

like making minecraft a game engine is bad

turbid nimbus
# turbid nimbus why not?

if they could do this without prejudice to the gameplay of the game, then on the contrary it is very good for the dev community.

quartz axle
#

im scared like now there like mouse(and snake i think) sound on my rooftop

#

normal day in jungle country

oak verge
hardy lily
#

Will inventory UI get revamped?

#

and also the container UI?

torpid axle
#

@rocky quail no more hacky stuff on inventories

hardy lily
#

rip

#

also, I heard hud screen also had a change too

turbid nimbus
#

I have good enough pc to play with RTX without lags, but not good for using new Ore-UI screens.

normal moat
rocky quail
past stirrup
#

Does anyone know what's up? Even when the variable $text is king:test, $achievement_text does not get updated, it still says Unknown.

{
    "achievement_stacked": {
        "layer": 1,
        "type": "image",
        "texture": "textures/ui/achievement",
        "anims": [ "@hud.achievement_animation_in" ],
        "$achievement_text|default": "Unknown",
        
        "clips_children": true,
        "anchor_from": "bottom_right",
        "anchor_to": "bottom_right",
        
        "offset": [ 0, -16 ],
        "size": [ 163, 32 ],
        "uv_size": [ 163, 32 ],
        "$uv|default": [ 0, 32 ],
        "uv": "$uv|default",

        "$text|default": "#text",
        "variables": [
            { "requires": "($text = 'king:test')", "$achievement_text": "Meow" }
        ],
        "controls": [
            {
                "achievement_content": {
                    "type": "label",
                    "shadow": true,
                    "anchor_from": "left_middle",
                    "anchor_to": "left_middle",
                    "color": "$main_header_text_color",
                    "text": "$achievement_text",
                    "layer": 2,
                    "offset": [ "18%", 5 ]
                }
            }
        ],
        "bindings": [
            {
                "binding_name": "#chat_text",
                "binding_name_override": "#text",
                "binding_type": "collection",
                "binding_collection_name": "chat_text_grid",
                "binding_condition": "once"
            },
            {
                "binding_type": "view",
                "source_property_name": "(('%.5s' * #text) = 'king:')",
                "target_property_name": "#visible"
            }
        ]
    }
}
outer juniper
#

How do people make variations of server forms?

#

Do they just like, copy and rename the source code

turbid nimbus
outer juniper
#

Without external software i meant

turbid nimbus
# outer juniper Without external software i meant

this is thing that you just adding in your addon code.

Or:
Create form template (to optimize your code because some form element can be the same)
Create 2 or more form elements
Create one main element where you will switch your forms controls by bindings

outer juniper
#

I acknowledge this is something that is more appropriate to probably ask in #1067535382285135923, but how would i, for example, create this server form in a script

#

Due to the fact that it's not a vanilla form, and yet i see ppl can achieve it

past stirrup
#

I tried debugging it by setting "text" to the $text variable and it does indeed output king:test

torpid axle
#

You really can't put bindings in a variables array, i think theres a better way to do this wait

torpid axle
# past stirrup I tried debugging it by setting `"text"` to the `$text` variable and it does ind...

Here, it works by converting boolean to a number then putting that on the string that gets a binding from property_bag. It's really hacky but it should probably work.

"achievement_stacked": {
  "layer": 1,
  "type": "image",
  "texture": "textures/ui/achievement",
  "anims": [
    "@hud.achievement_animation_in"
  ],
  "clips_children": true,
  "anchor_from": "bottom_right",
  "anchor_to": "bottom_right",
  "offset": [
    0,
    -16
  ],
  "size": [
    163,
    32
  ],
  "uv_size": [
    163,
    32
  ],
  "$uv|default": [
    0,
    32
  ],
  "uv": "$uv",
  "controls": [
    {
      "achievement_content": {
        "type": "label",
        "shadow": true,
        "anchor_from": "left_middle",
        "anchor_to": "left_middle",
        "color": "$main_header_text_color",
        "text": "#chat_labell",
        "layer": 2,
        "offset": [
          "18%",
          5
        ],
        "property_bag": {
          "#text_0": "Unknown",
          "#text_1": "Meow"
        },
        "bindings": [
          {
            "binding_type": "view",
            "source_property_name": "#text",
            "target_property_name": "#chat_textt"
          },
          {
            "binding_type": "view",
            "source_property_name": "((#chat_textt = 'king:test') * 1)",
            "target_property_name": "#condition"
          },
          {
            "binding_type": "view",
            "source_property_name": "('#text_' + #condition)",
            "target_property_name": "#chat_labell"
          }
        ]
      }
    }
  ],
  "bindings": [
    {
      "binding_name": "#chat_text",
      "binding_name_override": "#text",
      "binding_type": "collection",
      "binding_collection_name": "chat_text_grid",
      "binding_condition": "once"
    },
    {
      "binding_type": "view",
      "source_property_name": "(('%.5s' * #text) = 'king:')",
      "target_property_name": "#visible"
    }
  ]
}
past stirrup
#

oh interesting! Thank you! I’ll give that a shot

outer juniper
#

The fact that json ui has no official documentation makes it so confusing 😵‍💫

past stirrup
#

Tbf JSON-UI was never supposed to be accessible by the creator community. It was also kinda deprecated because of us.

outer juniper
#

Wdym "deprecated"

#

Not the definition, just in what way

past stirrup
#

Mojang doesn’t like it anymore and are no longer updating it

#

They’re moving over to OreUI

outer juniper
#

Sad😔

past stirrup
#

JSON-UI was basically deprecated very early

outer juniper
#

Is it a bit ambiguous

past stirrup
#

By the looks of things, Mojang doesn’t want us to modify OreUI but build upon it instead

torpid axle
outer juniper
#

As in, no forking the main UI but being able to make user-defined UI?

torpid axle
#

i was replying to fern

past stirrup
#

Pfft it’s alright

outer juniper
#

Yes I don't think it's difficult it's just that some sections are a bit ambiguous and undocumented

#

Or under-documented, if that's a word

past stirrup
safe geyser
#
{
    "namespace": "server_form",
    "long_form": {
        "type": "panel",
        "size": [
            "100%",
            "100%"
        ],
        "controls": [
            {
                "long_form@common_dialogs.main_panel_no_buttons": {
                    "$title_panel": "common_dialogs.standard_title_label",
                    "$title_size": [
                        "100% - 14px",
                        10
                    ],
                    "size": [
                        400,
                        200
                    ],
                    "$text_name": "#title_text",
                    "$title_text_binding_type": "none",
                    "$child_control": "server_form.long_form_panel",
                    "layer": 2,
                    "bindings": [
                        {
                            "binding_name": "#title_text"
                        },
                        {
                            "binding_type": "view",
                            "source_property_name": "(#title_text = 'JsonUI')",
                            "target_property_name": "#visible"
                        }
                    ]
                }
            }
        ]
    }
}
#

Who can help me

#

I want it to apply on server form called JsonUI but I wanna to let it display to another custom word

neat sequoia
#

Why anchor_from and anchor_to doesn't work at stack_panel?

oak verge
neat sequoia
#

ok

#

and i can just define the position with offset?

oak verge
#

no

neat sequoia
#

what are the other ways?

oak verge
#

panel

neat sequoia
#

but i need the stack panel

opal aurora
last pollen
#

does anyone know how to make a certain ui only appear when you look at a certain block

last pollen
last pollen
#

I couldn't find a module for it

still sundial
#

That's the only way, if i understood what you want correctly

#

And you use Script API to set the text to actionbar

last pollen
#

I want this ui to show only if I look at wood

turbid nimbus
pulsar hornet
#

i want to learn json ui, how should i start

outer juniper
#

Since that's not documented

vivid swallow
#

Is there any point in getting into JSON ui now? I've wanted to add an extra xp-like bar to the game, but I heard about json ui getting deprecated soon?

pulsar hornet
mental crystal
#

Soon like 50 years from now?

outer juniper
#

We'll probably get Minecraft 2 before the ui is deprecated

outer juniper
hasty stirrup
#

Hello guys, i was trying to change the villager hero texture animation that appears when you receve the effect in your screen. There is one issue, that animation in the center that should appear does not, i just get the effect and thats it. Anyone know how to fix this issue asap

safe root
#

Can anyone look over some some simple code and just explain some of the numbers, to do with sizing, anchoring and offsets etc. I got some stuff working but it's a bit janky and I just want to clean it up a bit.

If you can help send a DM :)

quartz axle
#

how can i change color from image?

#
"type":"image",
"texture":"textures/ui/White",
"color":[1,0,0]

like this or what?

oak verge
#

use gradient render

quartz axle
oak verge
# quartz axle how?

"background_gradient": {
"type": "custom",
"renderer": "gradient_renderer",
"color1": [1,0,0],
"color2": [1,0,0]
},

hardy lily
#

How to use textbox in chat_screen.json as a binding listener 🤔

#

previously, I have 2 textbox. One is for chat, and the other is for find the chat

#

It would be simple if I combined it and have a toggle to switch between chat and search

quartz axle
#

is it possible to convert a normal text to vector?
"[1.3,1,0]"->[1.3,1,0]

using split ?

hardy lily
#

in json ui?

quartz axle
hardy lily
#

I'm a bit confused, but it should work.

#

assuming you removing each bracket

quartz axle
#

it should right?

quartz axle
hardy lily
oak verge
hardy lily
#

no wonder it's using brackets

digital finchBOT
#
causalguide

So it's hard to change the color of the form button

quartz axle
#

I HAVE IDEA

hardy lily
#

awog

quartz axle
#

but now i dont have any

#

rules bg
only inglis

hardy lily
#

yes, ik

hardy lily
quartz axle
#

ill write hex color to color code real quick(using AI ofc)

hardy lily
#

I think you can use global variables instead

oak verge
hardy lily
#
                    "$x": 360,
                    "size": ["$x", 210],
oak verge
#

i meant "i been told dynamic arrays are not possible" part

rocky quail
oak verge
digital finchBOT
#
zihaoooo

Kaixo

#
zihaoooo

Hello

oak verge
#

Hello

digital finchBOT
#
zihaoooo

I need a json ui generator

oak verge
quartz axle
#

idk whyyyyy

#
function colorToMinecraftCode(color) {
  const { red, green, blue, alpha = 1 } = color;
  if(alpha == 0){
      const r = Math.round(red * 2550);
      const g = Math.round(green * 2550);
      const b = Math.round(blue * 2550);
  }
  const r = Math.round(red * 255);
  const g = Math.round(green * 255);
  const b = Math.round(blue * 255);

  // Convert to hex format
  const hexColor = ('#' + ((1 << 24) + (r << 16) + (g << 8) + b).toString(16).slice(1).toUpperCase() + Math.round(alpha * 255).toString(16).padStart(2, '0').toUpperCase());

  // Minecraft: Bedrock Edition color codes
  const bedrockColors = {
    "§0": "#000000",
    "§1": "#0000AA",
    "§2": "#00AA00",
    "§3": "#00AAAA",
    "§4": "#AA0000",
    "§5": "#AA00AA",
    "§6": "#FFAA00",
    "§7": "#AAAAAA",
    "§8": "#555555",
    "§9": "#5555FF",
    "§a": "#55FF55",
    "§b": "#55FFFF",
    "§c": "#FF5555",
    "§d": "#FF55FF",
    "§e": "#FFFF55",
    "§f": "#FFFFFF",
  };

  // Find the closest Bedrock color
  let closestColor = "§f"; // Default to white
  let minDistance = Infinity;

  // Convert each Minecraft color's hex code to RGB and find the closest match
  for (const code in bedrockColors) {
    const bedrockColor = bedrockColors[code];
    const bedrockR = parseInt(bedrockColor.substr(1, 2), 16);
    const bedrockG = parseInt(bedrockColor.substr(3, 2), 16);
    const bedrockB = parseInt(bedrockColor.substr(5, 2), 16);
    // Calculate the distance between the input color and the Bedrock color
    const rDiff = Math.abs(bedrockR - r);
    const gDiff = Math.abs(bedrockG - g);
    const bDiff = Math.abs(bedrockB - b);
    const distance = rDiff + gDiff + bDiff; // Use sum of differences for simplicity

    // If the distance is smaller, update the closest color
    if (distance < minDistance) {
      minDistance = distance;
      closestColor = code;
    }
  }

  return closestColor;
}

sorry oot

outer juniper
#

Are you attaching this function to ui?

mental crystal
oak verge
#

colorToMinecraftCode 🗿

mental crystal
#

imo this is unnecessary as hell 😭

mental crystal
# digital finch

Instead of asking for a json ui generator, learn how to make it first, cause once you have a generator (soon) you don't even understand a single shit in it.

quartz axle
quartz axle
#

it actually work for some block with colorMap that have the alpha value 1

#

it was

#

until i broke it

oak verge
quartz axle
digital finchBOT
#
causalguide

message length

quartz axle
#

yep message length not long

outer juniper
# quartz axle yep

May i ask, how did you do that since i heard ui cannot be integrated into JavaScript

rocky quail
#

so if it detects coordinates that is beyond what the renderer displays, itll show another renderer

quartz axle
#

i hve try it and my phone almost explode

oak verge
hasty stirrup
#

Hello guys, i was trying to change the villager hero texture animation that appears when you receve the effect in your screen. There is one issue, that animation in the center that should appear does not, i just get the effect and thats it. Anyone know how to fix this issue asap

quartz axle
#

hi guys so when i typed to much line on a button it will cut the text how to fix it?

haughty saddle
#

iam trying to learn json ui basic and iam trying to display a photo on the middle of the screen anyone know why it's not working?

chilly yacht
#

its just a blank image

#

also

#

your format is all wrong

#

{
"namespace": "test",
"elements": {}
}

weak cape
#

is it possible to put on a screen a mp4 file running?

outer juniper
#

Idk ngl

#

Mojang is probably calling since you dropped that sentence🗿

mental crystal
mental crystal
weak cape
#

i wanted to create "Brainrot PVP"

#

a box pvp with 3 running 24/7 Simpson Big mouth and Family guy clips

#

and brainrot sounds

#

like "sigma"

mental crystal
# weak cape really sucks

Ehh... Just convert video into animated texture and timing that sound match the animated texture 🤷

weak cape
#

yea

#

but it is more complicated than a single mp4 file

mental crystal
#

You can't even play mp4 in Minecraft in the first place iirc

haughty saddle
outer juniper
#

Wait did i ping

#

Idk if i disabled it

mental crystal
haughty saddle
#

`{
"toggle_template": {
"type": "toggle",

"$toggle_name|default": "Tutorial",
"$toggle_default_state|default": false,

"toggle_name": "$toggle_name",
"toggle_default_state": "$toggle_default_state"

"sound_name": "random.click", 
"sound_volume": 1.0 // Sound volume
"sound_pitch": 1.0 // Sound pitch

"checked_control": "@namespace.img_element", // When toggle is checked
"unchecked_control": "@namespace.img_element", // When toggle is unchecked
"checked_hover_control": "@namespace.img_element", // When toggle is checked and hovered
"unchecked_hover_control": "@namespace.img_element", // When toggle is unchecked and hovered
"checked_locked_control": "@namespace.img_element", // When toggle is checked and locked
"unchecked_locked_control": "@namespace.img_element", // When toggle is unchecked and locked
"checked_locked_hover_control": "@namespace.img_element", // When a locked and checked toggle is hovered
"unchecked_locked_hover_control": "@namespace.img_element", // When a locked and unchecked is hovered

"$use_grouped_toggle|default": false,
"$toggle_group_index|default": 0,

"radio_toggle_group": "$use_grouped_toggle" // Is boolean, when used will allow grouped toggles on which case only one toggle can be toggled
"toggle_group_forced_index": "$toggle_group_index" // It's indices of each toggle that differentiates one to the other

// Button mapping to do something when the toggle is clicked
// It can also be used for keybinding
"button_mappings": [
  {
    "from_button_id": "button.menu_select",
    "to_button_id": "button.menu_select",
    "mapping_type": "pressed"
  },
  {
    "from_button_id": "button.menu_ok",
    "to_button_id": "button.menu_ok",
    "mapping_type": "focused"
  }
]

}
}`

i found this in the wiki. what does this line do
"$toggle_name|default": "Tutorial",

and what does the | symbol do in general?

weak cape
#

well i dont know for sure

#

but i know it is used for the "default" defining

#

and is necessary to use it for the default

#

unless you will change the value in controls you dont need to use "|default"

torpid axle
#

if you are using the toggle group

nocturne python
#

Is it possible to add images or videos in the subtitles?

#

In actionbar and title it can be done but it will be possible in subtitles

weak cape
#

if you mean animations then yes

nocturne python
nocturne python
weak cape
vital edge
#

you can use subtitles, but subtitles only update when you update the title first

safe geyser
pine furnace
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

normal moat
# pine furnace One message removed from a suspended account.

it is something like this:

  "animation": {
    "anim_type": "flip_book",
    "initial_uv": [ 0, 0 ], // starting point
    "frame_count": 0, // total number of frames according to your spritesheet
    "frame_step": 0, // steps in pixels to the next frame
    "fps": 30,
    "reversible": true,
    "easing": "linear"
  },

  "image": {
    "type": "image",
    "texture": "textures/ui/image",
    "size": 0, // size of the image you want
    "uv_size": 0, // size of one frame according to your spritesheet
    "uv": "@animation" // add your animation here in uv
  }
pine furnace
#

One message removed from a suspended account.

#

One message removed from a suspended account.

normal moat
pine furnace
#

One message removed from a suspended account.

normal moat
#

then you just have to change the size property of your image i think

#

make sure you dont change uv size

pine furnace
#

One message removed from a suspended account.

normal moat
pine furnace
#

One message removed from a suspended account.

normal moat
#

then using aseprite you can make sprite sheet

pine furnace
#

One message removed from a suspended account.

normal moat
pine furnace
#

One message removed from a suspended account.

#

One message removed from a suspended account.

#

One message removed from a suspended account.

normal moat
#

okay (💀)

clever maple
#

can someone tell me whats wrong with the title? I want it if the message starts with §r§c it will show above the hotbar but it didn't work


    "hud_title_text": {
        "anchor_from": "bottom_middle",
        "anchor_to": "bottom_middle",
        "type": "image",
        "offset": [
            0,
            -40
        ],
        "size": [
            "100%c + 22px",
            "100%c + 10px"
        ],
        "texture": "textures/ui/hud_title.png",
        "keep_ratio": false,
        "uv_size": [
            128,
            16
        ],
        "alpha": 1,
        "controls": [
            {
                "title_message": {
                    "type": "label",
                    "anchor_from": "center",
                    "anchor_to": "center",
                    "color": "$tool_tip_text",
                    "layer": 31,
                    "text": "$title_text",
                    "localize": false,
                    "alpha": "@hud.anim_title_text_alpha_out"
                }
            }
        ],
        "bindings": [
            {
                "binding_name": "#title_text"
            },
            {
                "binding_type": "view",
                "source_property_name": "(not ((#title_text - '§r§c') = #title_text))",
                "target_property_name": "#visible"
            }
        ]
    }
chilly yacht
#

if its bigger than 32767 x or y it will crash

pine furnace
#

One message removed from a suspended account.

plucky token
#

Hey, somone can help me?, idk how to make the animation duration longer without affecting the image
"loading_spin_animation": { "anim_type": "flip_book", "initial_uv": [ 0, 0 ], "frame_count": 61, "frame_step": 1, "looping": false, "reversible": false, "easing": "linear" }, "loading_spin": { "type": "image", "layer": 31, "texture": "textures/ui/counter2", "anchor_from": "right_middle", "anchor_to": "right_middle", "offset": [ 0, 0 ], "size": [ 54, 15 ], "uv_size": [ 174, 60 ], "uv": "@loading_spin_animation" },

vernal jacinth
#

Yo can someone write me a script

#

Or help me copy n paist a manifest

haughty saddle
#

i did find this in some json ui files what is it

| default

for example this
"$focus_id|default": "",

chilly yacht
#

like

#

javascript

#

basically variables with |default are changabale

#

like a let variable in javascript

#

ones without are const

haughty saddle
#

can you give an example in how they are changable

chilly yacht
#

like if you call that element you can do "$var": "ahaha" and change the variable

haughty saddle
#

thx

unkempt nest
#

Actually searching JSON-UI dev ->

  • Changing server_form -> custom_form completly

Message me please

polar frigate
#

Does anybody knows how to add default text input? Not placeholder one... But the default text... I've been looking for it but couldn't find any (or i miss something?)

#
"$text_alignment": "center",
"text": "text 1",
"default": "text 2",
"$text_edit_text_control" : "texthahdhe"```

No output 😔
plucky token
#

Can someone show some animation examples with json ui? The wiki is very incomplete :((

turbid nimbus
polar frigate
turbid nimbus
polar frigate
weak cape
#

create a panel with size

#

and in this panel your aseprite animation image

#

you can change the panel size

#

instead the image size

#

you can look into my super advanced texture pack with flip book anims

#

#1325257811654869092

haughty saddle
#

How to make a buttun that ehen pressed it make an element invisible and when pressed again it make it visible i

outer juniper
#

Does "/hud" affect vanilla hud elements or all

haughty saddle
#

what the main difference between a button and a toggle?

normal moat
normal moat
normal moat
#

Button can also play animations

outer juniper
#

Or did i misunderstand

normal moat
#

Yeah if it's in root_panel

outer juniper
#

Ok thank you

outer juniper
#

Is there a list of available variables that i can use in my ui, such as player health, etc

#

Cuz ik they exist, i just don't know where to find them

west dawn
#

Best way is still to look how vanilla used them

outer juniper
#

Can there be different bindings that are determined by, e.g. user tags

#

Like, conditions in a sense

west dawn
#

The only way to pass data from behaviour to json ui is with either title, actionbar or even chat

weak cape
outer juniper
#

Yes scoreboard is possible from what i remember

#

Don't take my word for it tho

haughty saddle
#

how are common files used when making a ui? it it like presets that are used by the vanilla ui? and are they necessary for us to use in creating thing or they just make it easier to do thing for custom ui

vernal jacinth
#

Can someone help me with json ui

turbid nimbus
outer juniper
#

How do i select a specific score to bind to?

#

Since there doesn't seem to be an option

turbid nimbus
sharp zinc
#

how to do json UI 2025

torpid axle
oak verge
#

making a ui just for that screen to be replaced with ore ui next update bao_ext_toldyouso

#

this is how it feel to code a chest ui container now

torpid axle
oak verge
#

yeah, it just feel weird working on something that will eventually get deprecated

torpid axle
oak verge
#

if you already worked with them before, yeah
but is it worth it to go through learning json ui at this point
for the record i did work with containers before and i don't find it that hard.
we coding something, most of the time we code it to last

#

it feel like working with experimental stuff knowing they can get deprecated anytime

west dawn
#

tbh I do not think the ui is gonna get replaced that soon

#

The leaks might be for an event or something

torpid axle
outer juniper
#

Cuz i could have many scores

weak cape
#

personal floating text like "Your key amount: 1" is possible?

turbid nimbus
outer juniper
outer juniper
#

Wait

#

Is subtitle accessible?

#

Since technically it doesn't show so it wouldn't be inconvenient for the player

placid geode
clever maple
normal moat
outer juniper
#

Oh damn, might use that to discretely pass data

normal moat
#

i may be wrong but it only updates if title text exist

hallow mason
#

can anyone here help me with my ui ive got it set where finally theres an image as the background now i just need my buttons from the server fourm in specific places on the image

quiet breach
#

How can i modify the position of a popup

livid vault
#

Can someone help me fix this the problem is the text changing I want only change if it it has same or have text '§€§¥§™§®§✓§L§•§l'

{
"namespace": "hud",
"black_conditional_image": {
"type": "label",
"text": "#text",
"bindings": [
{
"binding_name": "#hud_title_text_string",
"binding_type": "global"
},
{
"binding_type": "view",
"source_property_name": "('%.34s' * #hud_title_text_string)",
"target_property_name": "#text"
},
{
"binding_type": "view",
"source_property_name": "(('§€§¥§™§®§✓§L§•§l') = #text)"

   },
     
              {
       "binding_type": "view",
       "source_property_name": "(#hud_title_text_string - ('%.34s' * #hud_title_text_string))",
  "binding_name_override": "#text"
   }
     
]

},

"black_conditional_image_factory": {
"type": "panel",
"factory": {
"name": "hud_title_text_factory",
"control_ids": {
"hud_title_text": "[email protected]_conditional_image"
}
}
},

"root_panel": {
"modifications": [
{
"array_name": "controls",
"operation": "insert_front",
"value": {
"[email protected]_conditional_image": {}
}
}
]
}

}

#

I use the command /title @s title
And the text

#

So if the title has the /title @s title §€§¥§™§®§✓§L§•§lHiii the text gonna change but it just like this /title @s title hii is not gonna change

#

Sorry for my grammar

turbid nimbus
torpid axle
#

😂

haughty saddle
#

guys what are property bag and collection

outer juniper
torpid axle
#

"visible": false?

mental crystal
# torpid axle "visible": false?
{
  "chat_grid_item/chat_background": {
    "size": [ "100%", "100%cm" ],
    "alpha": 0.0,
    "anims": [],
    "controls": [
      {
        "chat_background_controlled": {
          "type": "image",
          "texture": "textures/ui/Black",
          "alpha": 0.7,
          "size": [ "100%", "100%c" ],
          "anims": [ "@hud.anim_chat_bg_wait" ],
          "controls": [
            {
              "chat_text@chat_label": {
                "anchor_from": "top_left",
                "anchor_to": "top_left",
                "offset": [ 2, 0 ]
              }
            }
          ]
        }
      }
    ],
    "bindings": [
      {
        "binding_type": "collection",
        "binding_name": "#chat_text",
        "binding_name_override": "#text",
        "binding_collection_name": "chat_text_grid"
      },
      {
        "binding_type": "view",
        "source_property_name": "(not (#text = '_coddy:'))",
        "target_property_name": "#visible"
      }
    ]
  }
}```
#

I did this instead
-# mybad for tag

torpid axle
mental crystal
#

it doesn't right?

torpid axle
clever maple
outer juniper
#

I can use source_property_name

#

Though, I'm actually not sure

#

I mean would this work

"source_control_name": "[email protected]_score",
"source_property_name": "#text",
"target_property_name": "$scoreText"
mental crystal
outer juniper
#

Ight

last pollen
#

@quiet breach

quiet breach
outer juniper
mental crystal
#

Hey does anyone know how to remove the animation of the item in the hotbar like the animation when pickedUp like it stretched the item icon.

outer juniper
#

How tf do collections work

#

Do you like

#

Hardcode a list of items

#

Or use a container as a reference

#

Or neither

torpid axle
livid vault
mental crystal
outer juniper
round grove
#

Alright. I am trying to learn JSONUI so I can make a new mana meter that can be controlled using a scoreboard. I am finding the documentation rather unhelpful, so if someone could point me in the right direction to get started I would appreciate it.

chilly yacht
#

i wouldnt use scoreboards

#

since if its not custom server software itll be server side instead of client

#

so everyone will have the same mana

outer juniper
#

Oh nvm, collections are literally just grouped ui elements

chilly yacht
#

yeah

#

just an array of information

#

array of arrays

#

basically

outer juniper
#

Is there like

#

Hold up

#

How do containers have the ability to store items?

#

Is it hardcoded?

mental crystal
#

You can't create a container without inheriting from the chest, horse, hopper or other containers....

outer juniper
#

Ight

outer juniper
#

Wait hold up

#

How would i even make it for example, for a custom container

#

Cuz i would assume l

#

That it would just use the items found in a vanilla container instead of a custom one

#

Or just be blank completely

blazing sonnet
#

Is there any way to get the identifier of the inventory items with a binding?
Something like #hover_text

runic portal
#

how do i overlay hud screen onto the chat screen?

sharp zinc
#

How would i make an animation start/reset when something gets turned visible?

sharp zinc
#

factory?

rocky quail
#

yes

sharp zinc
#

sorry i am very new to json ui, only thing i've done before this was make an image visible based on title text lol

rocky quail
#

oh, then it might be confusing

#

but it's an element that creates other elements

#

you can use that to make a for example an image have a fade in or out animation which you can toggle using bindings

sharp zinc
#

ooo alright

#

i shall look into factory things

#

i did it

#

i am impressing myself today woohoo

oak verge
#

good job

rocky quail
sharp zinc
#

am i able to change the size of a label?

rocky quail
#

use font_size or font_scale_factor

sharp zinc
#

okie, ty

#

hmm

#

the text doesn't seem to scale correctly with the ui for some reason

outer juniper
#

How did you manage to stop /title from showing

outer juniper
placid geode
#

the easiest way Is just using /title @a times 0 0 0

#

or modifying the default title control

outer juniper
#

Ight I'll try that

mental crystal
placid geode
#

XD

outer juniper
sharp zinc
pine furnace
#

One message removed from a suspended account.

mental crystal
#

Guys.

#

how do i make the value is flip

#

Just like ! A not operator

hybrid aurora
#

Hello, npc dialog can be modified ? In which files ?

mental crystal
#
"custom_toggle_panel@server_form.custom_toggle_panel": {
                "$name": "toggle3",
                "$name_toggle": "toggle2",
                "$option_toggle": true,
                "$text": "3",
                "$index": 3,
                "$padding": [
                  52,
                  31
                ],
                "bindings": [
                  {
                      "binding_type": "view",
                      "source_control_name": "toggle1",
                      "source_property_name": "#toggle_state",
                      "target_property_name": "#visible"
                  }
                ]
              }```
I want the button to be not visible when the toggle is not clicked
mental crystal
mental crystal
#

Oh another one... When the opening form with toggle it automatically makes the button defaultly click a button

#

is there a way to make that no button is clicked at all?

#
{
  "custom_toggle_panel": {
    "type": "panel",
    "$toggle_size|default": [
      52,
      21
    ],
    "$padding|default": [
      52,
      21
    ],
    "$index|default": 1,
    "$name_toggle|default": "view_toggle",
    "$text|default": "Toggle",
    "$option_toggle|default": true,
    "size": "$padding",
    "controls": [
      {
        "custom_toggle@common_toggles.light_text_toggle": {
          "$toggle_name": "$name_toggle",
          "$button_text": "$text",
          "size": "$toggle_size",
          "$toggle_view_binding_name": "$name",
          "$radio_toggle_group": "$option_toggle",
          "$toggle_group_default_selected": 1,
          "$toggle_group_forced_index": "$index"
        }
      }
    ]
  }
}```
torpid axle
#

That's also one of the few problems i had, i figured it has something to do with focus properties.

mental crystal
#

guys, how do I add a divider to a form?

#

i mean by divided are those white lines

mental crystal
#

Does json ui support operators like : ? > < <= >= ?!?

safe geyser
#

Although ai is so bad at Json ui

mental crystal
plain trellis
#

Is it possible to adjust the size of an element depending if the player is in full screen or not?

livid vault
#

So is it possible to make UI using html

torpid axle
mental crystal
#

how do I get the value of the slider on the ModalForm?

#

this is not a custom slider it's a slider that already exists in the modalform

#

I have 4 sliders, is there a way to get each value separately

torpid axle
broken trail
torpid axle
#

To tell you how optimized this is written, only used 8 binding objects.

#

(Excluding the object that gets data and putting it to text, they don't really value that much.)

broken trail
torpid axle
broken trail
#

owh yeah that way

#

alr why not just display numbers tho, tlgm something like this in his pack

#

well at all it's shit, because it should be provided by game I mean that there may be some really edge cases where xp bar logic is custom, e.g. on servers, I even was in one that implemented such custom logic

#

in conclusion, jsonui lacks everything and the way to get it is creating some software and digging to memory

torpid axle
#

without tying it to something that changes the entire UI.

mental crystal
torpid axle
bitter ether
#

Is there any way to get the text after 4 characters in the anvil?

oak verge
bitter ether
#

is this the part?

"text_edit_panel": {
    "type": "panel",
    "anchor_from": "bottom_left",
    "anchor_to": "bottom_left",
    "size": [ "100%", "70%" ],
    "offset": [0, 2],
    "controls": [
      { "[email protected]_edit_control": { } }
    ]
  },
    "[email protected]_edit_box": {
    "anchor_from": "top_left", // the parent
    "anchor_to": "top_left", // this control
    "property_bag": {
      "#property_field": "#item_name"
    },
    "max_length": 30,
    "$text_edit_binding_name": "#text_box_item_name",
    "$text_edit_box_label_size": [ "default", 10 ]
  }
oak verge
#

try
#text_box_item_name
or
#item_name

bitter ether
#

i have try too, not work..

placid geode
#

using #exp_progress (#clip_ratio)

torpid axle
#

u just multiplied it with 100

oak verge
#

@hexed briar is what Mia asking for possible? (getting the anvil input text)
i assumed from the message i forwarded it is not

placid geode
pine furnace
#

One message removed from a suspended account.

hexed briar
#

the forwarded message i meant is a literal custom one.

#

you can't use custom textbox unless server form is involved.

outer juniper
#

Custom server forms can be made using factories, correct?

hexed briar
#

Only Modal form.

#

and secondly, you will need to submit the form order to actually apply or send the packet to the server.

outer juniper
#

Waet

opal aurora
hexed briar
#

sigh.

#

You will need to submit the form for the client-side to apply or send the packet to the server just to make it understand.

normal moat
mental crystal
mental crystal
#

an array thing can't accept variables inside them right? Only whole array?

#
// invalid
{ "color": [ "$r", "$g", "$b" ] }

// valid
{ "$r": [ 2, 0, 0 ], "$g": [ 0, 5, 0 ], "$b": [ 0, 0, 20 ] }
cunning bridge
#

how can i break from the parent element size and give an element the full screen size?

#

I want to display this text element to the side of the inventory when i hover over an item but it takes the parent size.
what can i do to break from the parent size to be able to place it anywhere?

mental crystal
#

i have three sliders, and i want to put the slider value in the color

#

Do I just stack three images?

haughty saddle
#

in vscode you can press ctrl with leftclick on function names to go to the function body. Is there something similar for json ui so when you ctrl left click press on @namespace.element it take you to that element?

haughty saddle
#

i'm a beginner and iam confused about what hardcoded bindings exist and how they are used. I'm also confused about collection. Can anyone explain how to identify them?

mental crystal
#

I literally searched the docs for this thing

mental crystal
#
{
              "image": {
                "type": "image",
                "anchor_to": "top_right",
                "anchor_to": "top_right",
                "offset": [0,-50],
                "layer": 1,
                "color": [1,0,0],
                "texture": "textures/ui/white",
                "alpha": "#alpha",
                "size": [64,64],
                "$max_alpha": 255.0,
                "bindings": [
                  {
                    "binding_type": "view",
                    "source_control_name": "alpha",
                    "source_property_name": "#custom_slider_step_text",
                    "target_property_name": "#alpha_value"
                  },
                  {
                    "binding_type": "view",
                    "source_property_name": "((#alpha_value * 1) / $max_alpha)",
                    "target_property_name": "#alpha"
                  }
                ]
              }
            }```

ok what did I do wrong here now.
torpid axle
mental crystal
#

I don't think that's the case since this is in the script. .slider('alpha', 0, 255, 1, 0)

mental crystal
torpid axle
mental crystal
mental crystal
#

I tried #slider_value because it's on the property bag of the slider but it doesn't work

normal moat
torpid axle
#

The lag 💀

normal moat
outer juniper
mental crystal
#

Anyways, maybe can you check my set-up? Maybe the set-up made it don't work or I did it entirely wrong lol....

#

Wait, bruh I'm Stoopid

#

I'm in the correct direction, I just need to add the collection thingy lmfao

outer juniper
#

You know what's a pain?

#

When you learn how to make something in json ui but you don't have any practical applications for it yet

normal moat
mental crystal
#

5 years ago I think? But I started Minecraft bedrock related things a year later

#

Minecraft Bedrock 1.16.100 is crazy ☠️

normal moat
outer juniper
mental crystal
#

I can confidently say a lot happened from that version to the current one

#

Both good and bad honestly

mental crystal
#

-# god, I'm even more Stoopid, I just realized you meant half a decade not a decade

mental crystal
#

i didn't modify your json ui and the slider in the modal form is .slider('hello', 0, 20, 1, 0);

mental crystal
mental crystal
#

do I need to edit the custom_button accept collection index?

torpid axle
#

first off your "form" element is a panel, change it to stack panel then add "collection_name": "custom_form"

#

in order to use collection_index, ur thing must be on a collection first

mental crystal
#

It works now man... Thanks

#

Another question tho, is there a way to make the image accept values in each slider to our in the color?

#

does it have a property bag or something or impossible

torpid axle
mental crystal
mental crystal
mental crystal
mental crystal
#

Guys what's the problem here? I use this to my images to have clip ratio but when I use this I to my label I can't open it since it hangs or crashes my game, do i need to convert the number back as a string?

{
                "label": {
                    "type": "label",
                    "size": [
                        "100%",
                        "100%"
                    ],
                    "layer": 2,
                    "text": "#text",
                    "$clip_max": 100.0,
                    "bindings": [
                        {
                            "binding_type": "global",
                            "binding_name": "#hud_title_text_string",
                            "binding_name_override": "#text"
                        },
                        {
                            "binding_type": "view",
                            "source_property_name": "(('%.4s' * #text) = 'bar.')",
                            "target_property_name": "#visible"
                        },
                        {
                            "binding_type": "view",
                            "source_property_name": "(#text - ('%.4s' * #text))",
                            "target_property_name": "#bar"
                        },
                        {
                            "binding_type": "view",
                            "source_property_name": "((#bar * 1) / $clip_max)",
                            "target_property_name": "#text"
                        }
                    ]
                }
            }```
#

i planned to have a percentage of it.

placid geode
placid geode
sharp zinc
whole latch
sharp zinc
#

:[

#

ty

#

does title not normally work with \n?

#

i thought it did before ig not

whole latch
#

no, since it is parsed as normal text, whereas JSON (used for rawtext) converts "\n" to a line feed

sharp zinc
#

ahh, alrighty

#

Tis been a bit since i've used commands for actionbar/title stuff

#

am only using commands to test in-game tho

whole latch
#

if you're going to set it with JS you won't need anything extra

onScreenDisplay.setTitle("text\ntext")
sharp zinc
#

oh nice

outer juniper
#

Hey one question guys

sharp zinc
outer juniper
#

Ik to append an element to the hud i must make modifications to the root_panel, but what would be the pause menu equivalent?

sharp zinc
#

putting stuff in pause screen content

outer juniper
#

So there is no specific element i must append the new elements to?

sharp zinc
#

"pause_screen_content" i think is what you're referring to

#

is there a way to make a sound play for an animation?

normal moat
sharp zinc
#

guess i gotta play it from scripts

normal moat
#

yeah

sharp zinc
#

i think i am done with this notification thing now

normal moat
mental crystal
mental crystal
sharp zinc
mental crystal
weak cape
#

How do i make the Background not affect the image?

#

THe background is the sibling of the image

jolly rock
#

Add it on a top layer

torpid axle
weak cape
weak cape
true laurel
mental crystal
#

Guysu have an custom xo bar type thing in android or touch device the size doesn't match since there's inventory button

#

How do I make that it stretched too?

#

In desktops devices the size matches the xp bar's width size

mental crystal
hexed briar
#

typing 100

mental crystal
hexed briar
mental crystal
#

I can't see what I'm typing especially since my keyboard keys are stucked lmfao

torpid axle
#

any ways there is binding for that

mental crystal
#

If you mean this. Yes I tried this and it breaks my bar

torpid axle
#

only put the x binding

#

remove other ones

mental crystal
#

the empty bar doesn't get reized but the bar itself does

#

I need to add a property bag right?

mental crystal
#

I'll create a post but I doubt anyone would answer there lmao

#
{
  "m": {
    "type": "image",
    "texture": "textures/ui/emptybar",
    "anchor_from": "bottom_middle",
    "anchor_to": "bottom_middle",
    "size": [
      182,
      5
    ],
    "offset": [
      0,
      -32
    ],
    "layer": 10,
    "property_bag": {
      "#size_binding_x": 0.0
    },
    "controls": [
      {
        "h": {
          "type": "image",
          "size": [
            "100%",
            "100%"
          ],
          "layer": 10,
          "texture": "textures/ui/fullbar",
          "clip_pixelperfect": true,
          "clip_direction": "right",
          "$clip_max": 100.0,
          "color": [
            1,
            1,
            0
          ],
          "bindings": [
            {
              "binding_type": "global",
              "binding_name": "#hud_title_text_string",
              "binding_name_override": "#text"
            },
            {
              "binding_type": "view",
              "source_property_name": "(('%.4s' * #text) = 'bar.')",
              "target_property_name": "#visible"
            },
            {
              "binding_type": "view",
              "source_property_name": "(#text - ('%.4s' * #text))",
              "target_property_name": "#bar"
            },
            {
              "binding_type": "view",
              "source_property_name": "((#bar * 1) / $clip_max)",
              "target_property_name": "#clip_ratio"
            }
          ]
        }
      }
    ],
    "bindings": [
      {
        "binding_name": "#exp_bar_size_x",
        "binding_name_override": "#size_binding_x"
      }
    ]
  }
}```
torpid axle
#

{
"binding_name": "#hotbar_size_x",
"binding_name_override": "#size_binding_x"
}

torpid axle
# mental crystal

try putting it along side the xp bar then inherit the size of sibling through 100%sm

#

so it sizes the same

mental crystal
#

Is it probably because of my image? Both of my image are 182x5 they both don't have nineslices unless they are required.

mental crystal
torpid axle
#

i realize when using touch the size go from 180 to 200

mental crystal
torpid axle
#

yes sure

mental crystal
#

I add them to both?

torpid axle
#

ye

mental crystal
#

Yeah both didn't work

gilded rivet
#

when will ore-ui come out?

torpid axle
mental crystal
#

But also F-- you

#

Another problem is the #show_survival_ui doesn't work with me

torpid axle
#

it works

#

ur probably not using it well

oak verge
mental crystal
#

how nineslices work?

oak verge
normal moat
oak verge
#

bao_ext_toldyouso the sub domain

normal moat
#

ngl the website is great

oak verge
#

actually, let me remove that shit done

oak verge
weak cape
#

i only have the sliders on the left

#

oh

#

i tohught it downloaded the json file lmao

oak verge
oak verge
weak cape
#

the edge cuts out for some reason

#

is there a scale for preventing this cut?

mental crystal
#

this shit saved my life

#

my bar starts to tweak out when I sized it more than his original size which is 182x5.

#

so I used nineslice tho I didn't do it on the image but directly into the json ui

#

since it's a single image with full bar and empty bar I can't nineslice it there.

mental crystal
#

-# i yapped too much.

jaunty smelt
#

smone find the error in this 😭 finish time tryna link smthing to title text

#

i want only the first 25% of the text to be displayed.

jolly rock
#
Title text - 7 = 'ow are'```
But there is a problem 
```Title text = basicto0nu
Title text - 7 = number```
#

Does your title text have numbers?

#

If this is the case, then:
"('§f'+(#hud_title_text_string - ('%.7s' * #hud_title_text_string)))"

#

That will convert the number to a string

#

Also, make sure the y size (9) It is enough for the text to be displayed

#

Alsoooo
%.75s there are a lot of letters, make sure that requirement is met

mental crystal
#
{
    "array_name": "bindings",
    "operation": "replace",
    "where": {
        "binding_name": "#example_binding_1"
    },
    "value": {
        "binding_name": "#replacement_binding"
    }
}```
#

How do I replace a control?

#

I don't know how since wiki only provided bindings

#

I just need to add an offset to it.

jaunty smelt
#

All u need to know is the control name

#

And u u write the control name and the offset only

mental crystal
# jaunty smelt All u need to know is the control name

  "centered_gui_elements_at_bottom_middle_touch": {
    "offset": [0,-12],
    "modifications": [
      {
        "array_name": "control",
        "operation": "replace",
        "where": {
          "exp_rend@exp_progress_bar_and_hotbar": {}
        },
        "values": {
          "exp_rend@exp_progress_bar_and_hotbar": {
            "offset": [0,6]
          }
        }
      }
    ]
  }```
#

is this even valid?

jaunty smelt
#

idk

placid geode
#

You can also do this:

"centered_gui_elements_at_bottom_middle_touch": {
"offset": [ 0, -12 ]
},
"centered_gui_elements_at_bottom_middle_touch/exp_rend": {
"offset": [ 0, 6 ]
},
mental crystal
#

i forgot that existed lmao

#

another question

#

example I have a title I want that if the title match it changed the offset

#

How? Do I use requires instead of bindings?

mental crystal
#
...
"offset": "$offset",
"requires": [
   {
      "requires": "",
      "$offset": [0,20]
   },
   {
      "requires": "",
      "$offset": [0,0]
   }
]```
#

How do I put the hud title text string binding?

#

Does it accept that?

weak cape
#

How do i anchor a stack panel? It places at the "top_middle" position even tho i used "bottom_middle". With buttons it does work but stack panel just wont.

placid geode
placid geode
#

'%.75s' takes the first 75 characters of a text

#

('%.3s' * 'thingy') -> thi

mental crystal
# placid geode you can use $title_text

Dude. I don't know how to fix this.

{
  "centered_gui_elements_at_bottom_middle_touch": {
    "offset": "$offset",
    "variables": [
      {
        "requires": "(not ($title_text - 'bar.') = $title_text)",
        "$offset": [0,-12]
      },
      {
        "requires": "(($title_text - 'bar.') = $title_text)",
        "$offset": [0,0]
      }
    ]
  }
}```
#

I throw an error that title text isn't defined but I don't think you can pass a variable thru bindings right?

placid geode
placid geode
#

of course don't forget to add the bindings

#

{"binding_name":"#hud_title_text_string"}

#

(I think it won't work but meh)

mental crystal
#

you think?

#

the problem is idk if the way I did my requires is correct

#

like when the text bar. Is included in it work

placid geode
#

yeah its ok

#

Bro wait

mental crystal
#

It doesn't actually work LMFAO

mental crystal
#
{
  "centered_gui_elements_at_bottom_middle_touch": {
    "offset": "$offset",
    "$update_string": "bar.",
    "$is_title": "#is_title",
    "variables": [
      {
        "requires": "($is_title)",
        "$offset": [0,-6]
      },
      {
        "requires": "(not ($is_title))",
        "$offset": [0,0]
      }
    ],
    "bindings": [
      {
        "binding_name": "#hud_title_text_string"
      },
      {
        "binding_name": "#hud_title_text_string",
        "binding_name_override": "#preserved_text",
        "binding_condition": "visibility_changed"
      },
      {
        "binding_type": "view",
        "source_property_name": "(not (#hud_title_text_string - $update_string = #hud_title_text_string))",
        "target_property_name": "#is_title"
      }
    ]
  }
}```
#

you guys anyway to make this work?

#

I want that if the title exists it would change the offset if not retain to original offset

#

Yes my binding works I tried with just #visible and it hides it when the bar. Is not in the title anymore

placid geode
#

sorry xD i got bussy

placid geode
#

i think the Best way Is using anchored offset

mental crystal
#

like currently it only does tru and fals

pure frost
#

hi guys i’m looking for an advanced JSON UI designer who can handle somewhat complex things. Please feel free to reach out I pay pretty well.

gloomy plover
#

Hey guys... I'm looking for someone who can help me through all JSON UI, can anyone help?

vale turtle
#

Is it correct you can only remove the item “Attack damage” but not the +7?

torpid axle
#

is there a variable if player is playing on a server?

placid geode
#

$is_on_3p_server

#

or something like that

placid geode
#

or multiply that true or false by a number

#
false * 16 -> 0
true * 16 -> 16
torpid axle
placid geode
#

there is also $is_pregame, but maybe it won't work for you

livid vault
#

How I can get the score without displaying the scoreboard or like using the /scoreboard objectives and then display I want get the scoreboard then get my own score so how I do that is there any template

#

The name of scoreboard I want get is attack the name and the score

#

<--Sorry for my grammar

#

I'm not good at English

patent bramble
#

How to move a UI again?

analog snow
sharp zinc
#

i was using the pack to test performance

analog snow
#

yeah but does it reposition with fov too?

#

or not?

sharp zinc
#

idk

analog snow
#

you should try it

sharp zinc
#

probably since it uses the player model

analog snow
#

well, if you can, that would be great

analog snow
sharp zinc
#

you can try it if ya want

#

i think it's stars fps counter

#

i am working on mp thing right now so i don't really got time to

analog snow
#

okay thank you

gloomy plover
#

can anyone tell me how to define animations and use them in anims array?

nocturne python
#

Is it possible to remove the shadow on the player's name?

safe geyser
glad sluice
#

How would i go about make 2 diff forms for diff uis

#

and it only works for the said form

mental crystal
#

how to know the length of available buttons in the action from data

#

I know #form_button_length exist but idk how to get it.

torpid axle
mental crystal
torpid axle
mental crystal
hexed briar
#

found something interesting about vanilla UI.

apparently there's some bindings error on few screens and somehow does not have any error on the content log. but when i reference them with correct variables and stuff, content log just screams.

so it looks like they just made vanilla UI completely silent when it comes to content log, that's honestly strange.

opal aurora
#

or, only visible in development builds

west dawn
#

Or its just because certain bindings/variables are only available in certain screens and contexts

hexed briar
#

I did literally forked the entire element that prone to bindings errors on the exact same screen and it pretty much shows up no matter of what.

#

The only thing i could fix is to get rid of bindings all together but that will cause some issues to some screens that use them as bindings rather than just text.

#

it's safe to say that mojang internationally did the hacky moment and trying to avoid by not making them shows up on content log

mental crystal
#

can you detect right click in JSON UI?

#

Or impossible

safe geyser
hexed briar
#

technically since only thing you can is item slot related.

#

other than that, you can't use it for custom stuff.

rocky quail
#

if you meant detecting in json ui, not items

mental crystal
#

I guess I explained it wrong?

#

Yes I'm talking about json ui.

#

like the button or slider can be only clicked if the player right click it instead not left click

hexed briar
#

though kinda not worth it considering its the mapping. not like hover and right click it.

runic portal
#

anyone got the template for putting a text field in an action form?

weak cape
#

Can anyone tell me how do i add a animation on hovering over a button?

#
{
    "hover": {
        "type": "image",
        "texture": "texture/ui/banner",
        "alpha": "@server_form.button_hover_animation",
        "bindings": [
            {
                "binding_name": "#form_button_texture",
                "binding_name_override": "#texture",
                "binding_type": "collection",
                "binding_collection_name": "form_buttons"
            },
            {
                "binding_name": "#form_button_texture_file_system",
                "binding_name_override": "#texture_file_system",
                "binding_type": "collection",
                "binding_collection_name": "form_buttons"
            }
        ]
    }
}

this is what i came up with but it doesnt work. My animation is a offset anim

sharp zinc
#

i wonder how i could get multiple pieces of data from one string

#

is there more documentation on whatever this lang is from?
example: (not (('%.13s' * #text) = 'notification.'))

#

like, am i able to do for loops and what not in there?

placid geode
#

"offset": "@server_form.button_hover_animation"

#

or "anims": [ "@server_form.button_hover_animation" ]

weak cape
#

oh

#

well when i put the anim in anims

#

it just doesnt work

#

when i put it as offset it works, but broken. No transition at all, just the offset it higher

weak cape
#

im just dumb

mental crystal
#

Guys

#

there's a player_icon right? Can we access it?

#

if yes how does it show the icon? Id too?

livid vault
#

Is it possible to make chat UI in huds_creen like in Roblox can I remake it in Minecraft is it possible?

weak cape
#

Yeah

normal moat
#

in pause screen, there is some other thing

fading mauve
#

Where's the texture for the lore background? Is it even accessible?

turbid nimbus
weak cape
#

Yup

#

I saw that

#

And just decided to have no animation

#

But are there other ways?

weak cape
turbid nimbus
weak cape
#

To add animatons

#

When hovering over a button

turbid nimbus
mental crystal
weak cape
mental crystal
#

Is it a toggle or button?

#

If it's a toggle you could try to use in the controls the checked_hover and unchecked_hover

slim oyster
#

it's not

#

bruh

#

lmao I haven't talked here for so long

mental crystal
oak verge
#

i hate when i am wrobg

mental crystal
oak verge
#

we all make mistakes, ||i am stopping my self from continuing this joke||

weak cape
weak cape
weak cape
slim oyster
near osprey
#

yo

#

im wondering how to scale this because nothing that I've tried worked i want to make it smaller

"abcdave": {
"type": "panel",
"anchor_from": "bottom_middle",
"anchor_to": "bottom_middle",
"size": [
"25px",
"10px"
],
"scale": 0.5,
"controls": [
{
"promo_text": {
"type": "label",
"visible": "($actionbar_text != '')",
"$actionbar_text": "$actionbar_text",
"text": "$actionbar_text",
"text_alignment": "right",
"anchor_from": "bottom_middle",
"anchor_to": "bottom_middle",
"shadow": false,
"offset": [
0,
-100
],
"font_size": "8px"
}
}
]
},

#

editing "font_size": "8px", "scale": 0.5 or "size": [
"25px",
"10px"
], did nothing

placid geode
#

"scale" doesnt exist

#

"font_size" only works with "normal", small, large, extra_large

#

use "font_scale_factor"

#

"font_scale_factor": 0.5

near osprey
#

that worked

#

one more quick question. How do you edit how much space there is between each letter?

placid geode
#

each letter i think isnt possible

#

for each line you use "line_padding"

near osprey
#

I'm trying to get rid of the gaps in this.
anyway of doing that?

sharp zinc
#

is there a way i could only make binding only run once?

torpid axle
sharp zinc
#

that didn't seem to stop it

#

am i doing something wrong?

#

is it because i'm using a factory?

sharp zinc
#

nvm

tough imp
#

I have a problem, when I use server_form to give textures to my script menus, and I want to add an image for example of a square size [50, 50]. But when I want to make it rectangular nothing happens, it is still a square of the same size or larger but I cannot make it rectangular

#

{
"image": {
"type": "image",
"texture": "textures/ui/menu/button3",
"size": ["200%", "25%"],
"offset": [50, 0],
"anchor_from": "center",
"anchor_to": "center",
"layer": 4
}
},

#

This is a block fragment

tough imp
#

I don't know if it was understood xd, but basically the texture doesn't stretch, it just gets bigger

placid geode
#

did you set nineslice size?

livid vault
#

Why I can't click the button how to fix this

{
"namespace": "hud",
"[email protected]": {
"$pressed_button_name": "button.hotbar_inventory_button",
"size": [
50,
50
],
"controls": [
{
"default@default_borderless_button_layout": {}
},
{
"hover@hover_borderless_button_layout": {}
},
{
"pressed@pressed_borderless_button_layout": {}
},
{
"elipses@elipses_image": {}
}
]
},
"root_panel": {
"modifications": [
{
"array_name": "controls",
"operation": "insert_front",
"value": {
"[email protected]": {}
}
}
]
}
}

tough imp
tough imp
#

But thanks for the help

near osprey
#

I'm trying to get rid of the gaps in this.
any way of doing that?

chilly yacht
near osprey
#

Do you mean bigger resolution?
The textures are touching both sides of it

chilly yacht
#

im able to do 32x32 textures

#

do you use aseprite?

gaunt apex
mental crystal
#

Guys, there's no way to stop players being able to open the pause screen right?

#

Like while in-game then click the back button

weak cape
#

what do i do wrong???

{
    "default": {
        "type": "image",
        "variables": [
            {
                "requires": "(#form_button_texture = 'locked')",
                "texture": "texture/ui/grey_banner"
            },
            {
                "requires": "(#form_button_texture = '')",
                "texture": "$texture"
            }
        ],
        "bindings": [
            {
                "binding_name": "#form_button_texture",
                "binding_type": "collection",
                "binding_collection_name": "form_buttons"
            }
        ]
    }
}
#

it just doesnt show any texture

#

the grey banner doesnt show nor does the chosen one as $texture

normal moat
weak cape
#

bruh

weak cape
#

or is it just impossible?

shadow spire
#

how do i go back to the old ui, i current have 200+ texture packs and when im srolling its laggy af

#

but with the old ui i didnt have that problem

hexed briar
#

what

#

how do you even have 200+ texture packs

chilly yacht
#

some xbox user making a 2020 type kit pvp realm

outer juniper
#

Ik to make custom chest UIs i need to edit chest_screen.json and make some binding for it to show, but how do i actually make it functional?

gaunt apex
#

How can I make sure this text doesn't have limits, look at what I sent, it looks like it has limited text, how do I fix it?

    "size": ["33.3333%",
      20],
    "controls": [{
      "button@common_buttons.light_text_button": {
        "$button_type_panel": "npc_interact.student_slim_button_label_panel",
        "$pressed_button_name": "button.student_button",
        "layer": 4,
        "size": ["100% - 2px",
          "100% - 2px"],
        "bindings": [{
          "binding_type": "collection_details",
          "binding_collection_name": "student_buttons_collection",
          "binding_collection_prefix": "student_buttons"
        }]
      }
    }],
    "bindings": [{
      "binding_name": "#student_button_visible",
      "binding_type": "collection",
      "binding_name_override": "#visible",
      "binding_collection_name": "student_buttons_collection"
    }]
  }
rancid garden
#

does anyone know how to stop the default behavior of text edit boxes from being that they accept input when you hover over them?

gaunt apex
#

unsolved

normal moat
outer juniper
earnest acorn
#

how would i make a modal form text input have Multi-line?

mental crystal
#
{
  "namespace": "hud",
  "up": {
    "type": "image",
    "texture": "textures/ui/tnt/up",
    "size": [
      47,
      43
    ],
    "layer": 0,
    "anchor_from": "top_right",
    "anchor_to": "top_right",
    "bindings": [
      {
        "binding_name": "#hud_title_text_string"
      },
      {
        "binding_type": "view",
        "source_property_name": "(not (#hud_title_text_string - 'up') = #hud_title_text_string)",
        "target_property_name": "#visible"
      }
    ]*l
  },
  "up_on": {
    "type": "image",
    "texture": "textures/ui/tnt/up_on",
    "size": [
      47,
      43
    ],
    "layer": 1,
    "anchor_from": "top_right",
    "anchor_to": "top_right",
    "bindings": [
      {
        "binding_name": "#hud_title_text_string"
      },
      {
        "binding_type": "view",
        "source_property_name": "(not (#hud_title_text_string - 'up_on') = #hud_title_text_string)",
        "target_property_name": "#visible"
      }
    ]
  },
  "root_panel": {
    "modifications": [
      {
        "array_name": "controls",
        "operation": "insert_front",
        "value": [
          { "[email protected]": {} },
          { "[email protected]_on": {} }
        ]
      }
    ]
  }
}```

Why this doesn't work, like the image would only show up when the text is included but no luck.
west dawn
#

you may have to put (#hud_title_text_string - 'up_on') = #hud_title_text_string) in () as well

placid geode
#

XD

#

just modify your condition

#

"(not (#hud_title_text_string - 'up_on' = #hud_title_text_string))"
"(not (#hud_title_text_string - 'up' = #hud_title_text_string))"

#

like this

tough imp
#

Does anyone know how to add textures to the player screen? I have this base but it doesn't work

{
  "namespace":"bar",

  "bar_panel": {
    "type":"panel",
    "alpha": true,
    "controls":[
      {
        "hudbar":{
          "type":"image",
          "alpha":true,
          "texture":"textures/ui/hud/hudbar",
          "anchor_from":"top_left",
          "anchor_to":"top_left",
          "layer":2,
          "size": [106, 10],
          "offset": [5, 43.5]
        }
      },
      {"[email protected]":{}},
      {
        "none": {
          "type": "image",
          "texture": "textures/ui/none",
          "anchor_from": "top_right",
          "anchor_to": "top_right",
          "layer": 5,
          "size": [18, 18],
          "$value":"[none]",
          "offset": [0, 80],
          "bindings": [
            {"binding_name": "#hud_title_text_string"},
            {"binding_type": "view","source_property_name": "(not((#hud_title_text_string - $value) = #hud_title_text_string))","target_property_name": "#visible"}
          ]
        }
      }
    ]
  },
  "health10":{
    "type":"image",
    "texture":"textures/ui/hud/health1",
    "anchor_from":"top_left",
    "anchor_to":"top_left",
    "layer": 5,
    "size": [144, 12],
    "$value":"[health10]",
    "clip_ratio":0,
    "clip_direction":"left",
    "offset": [6, 10],
    "bindings":[{"binding_name":"#hud_title_text_string"},{"binding_type":"view","source_property_name":"(not((#hud_title_text_string - $value) = #hud_title_text_string))","target_property_name":"#visible"}]
  }
}
mental crystal
#

It works now.. thank you lmfoa

mental crystal
#
{
  "hud_title_text/title_frame/title": {
      "modifications": [
        {
            "array_name": "bindings",
            "operation": "insert_back",
            "value": {
              "binding_type": "view",
              "source_property_name": "(not (#text - 'view.' = #text))",
              "target_property_name": "#visible"
            }
        }
      ]
  }
}```
#

Why doesn't this work? I want to hide the title if it's has the view. included

#

I'm always confused with operators lol

#

Fixed it lol...

{
  "hud_title_text/title_frame/title": {
      "$hud_string": "view.",
      "modifications": [
        {
            "array_name": "bindings",
            "operation": "insert_back",
            "value": {
              "binding_type": "view",
              "source_property_name": "(not (('%.5s' * #text) = $hud_string))",
              "target_property_name": "#visible"
            }
        }
      ]
  }
}```
normal moat
mental crystal
#

You mean this?

normal moat