GUI variables digit limit

Started by msrodrigues2000 on

Topic category: Help with MCreator software

Joined May 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
GUI variables digit limit

Is there a way to limit the number of digits of the number shown in the gui? For example I want the variable number that appears to be an integer or be limited to two digits after the dot. I am using global variables.

Joined Jul 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
You can use the (round) math…
Sun, 07/05/2020 - 12:51

You can use the (round) math thing just put your 

Variable number in the (round) math thing. 

You will find it in the math blocks. 

They need to add a make number integer option.

Joined Feb 2025
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
each # is a number for…
Wed, 04/02/2025 - 18:18

each # is a number for digits after the dot

return text:
	create text with
		format number:
			get number of {global variable}: for entity: {target/event entity} (optional but you can make stuff like devisions here)
				as "##.##"