toggle a scoreboard between 1 and 0
So basically im trying to make an item were if u right click it, a scoreboard toggles between 1-0, with that i could make it turn on/off its ability when right clicked, but i cannot wrap my head on how i make it work, if i basically make: **if scoreboard=1 set to 0 ** and on the line below:if scoreboard=0 set to 1, every time i right clicked, it would always end on 1 because of the order i put them in the function, if these commands switch places, it would always end on 0,if theres a better method to toggle a scoreboard between 2 values, pls tell me <:great:1208570801368862730>. Thanks in advance!
Continue to help post