Topic category: Help with Minecraft modding (Java Edition)
I'm making a tool that just makes counting easier in-game, so I have an overlay that has the number I want displayed, and when clicked on bock it will raise by 1, then when id click a block in the game it would jump straight to 123412361234(repeating) how would i just have that number go up by a single unit? anything helps
i had deleted the code as i had this issue a few days ago and wanted to put it off, so i just remade the code from memory so sorry if its incomplete im just throwing it together
for the display condition its" return text (get global variable)" and for when right clicked on block its "set (global variable) to: format number (1) as (get global variable)" if anything is wrong with that let me know
for the right click on block trigger, try "set (global var) to [get(global var) + 1]"
thanks! works good now, just had to change the string variable to number, and when i did the +1 it would set to +2 in-game, so i just made it +0.5 so that works great now.
Nice, glad I could help