"percent_text": {
"type": "label",
"text": "#text",
"text_alignment": "left_middle",
"contained": true,
"layer": 3,
"max_size": ["100%-6px", 15],
"anchor_from": "center",
"anchor_to": "center",
"text_alignment": "center",
"$one": 1.0,
"bindings": [{
"binding_name": "#form_button_text",
"binding_type": "collection",
"binding_collection_name": "form_buttons"
},
{
"binding_type": "view",
"source_property_name": "(('%.6s' * #form_button_text) - ('%.3s' * #form_button_text) * $one)",
"target_property_name": "#percent"
},
{
"binding_type": "view",
"source_property_name": "('§z' + #percent + '%')",
"target_property_name": "#text"
}
]
}
#Help percent
1 messages · Page 1 of 1 (latest)
"percent_text": {
"type": "label",
"text": "#percent",
"text_alignment": "left_middle",
"contained": true,
"layer": 3,
"max_size": ["100%-6px", 15],
"anchor_from": "center",
"anchor_to": "center",
"text_alignment": "center",
"bindings": [{
"binding_name": "#form_button_text",
"binding_type": "collection",
"binding_collection_name": "form_buttons"
},
{
"binding_type": "view",
"source_property_name": "('§z' + (('%.6s' * #form_button_text) - ('%.3s' * #form_button_text)) + '%')",
"target_property_name": "#percent"
}
]
}
try it
It remains the same.
In your script, add "§f" before your #percent
"percent_text": {
"type": "label",
"text": "#percent",
"text_alignment": "left_middle",
"contained": true,
"layer": 3,
"max_size": ["100%-6px", 15],
"anchor_from": "center",
"anchor_to": "center",
"text_alignment": "center",
"bindings": [{
"binding_name": "#form_button_text",
"binding_type": "collection",
"binding_collection_name": "form_buttons"
},
{
"binding_type": "view",
"source_property_name": "('§z' + (('%.8s' * #form_button_text) - ('%.3s' * #form_button_text)) + '%')",
"target_property_name": "#percent"
}
]
}
Oh ok
Turn it into string in your script, and if you're using the same bytes in your progress bar, just do the same: %.8s - %.3s
I'm trying to get the percentage without using JS.
Oh, if it doesn't work, you can send me the script or the code where did you put the percentage, and i will try to help you
Ok bro
Use "localize": false
% is used for localization keys so they do not show normally