"How do you make a variable local in Scratch?
By clicking on the button that says Make a Variable, a window will pop up that will allow you to create your own variable. Window to create a new variable. If you want your variable to be global select the option “For all sprites” if you want your variable to be local select “For this sprite only”."