Trying to schedule a function to make a loop.
Goal: I need a an action bar to be displayed constantly once the function
display_bank_balanceis run.Contents of function:
execute as @s run title @s actionbar {"text":"Bank Balance: ","color":"gold","extra":[{"score":{"name":"@s","objective":"bank"},"color":"green"}] schedule function home:display_bank_balance 1sThis is what I currently have. It does not work how I want it too. Heres what happens when it runs. It runs twice as @s (me), then it continues to run but as the server, therefore not displaying the actionbar to me. What does the issue appear to be and how can I fix it?
What I've tried doing:
- I added
execute as @s runin front ofschedule function justin:display_bank_balance 1s, but it does the same thing except it stops looping after 3 times. - I removed all
execute as @s runfrom the commands, but it still does the same thing.
More info:
- I'm in 1.20.1 java
- The function above is being called from another function w/
function home:display_bank_balance