Local variables are variables that only exist for a short time typically within a single function. This is useful for when you need to store data without wanting to make entirely new global variables. This is a new method however from my previous versions (scattered within other projects). This method has 2 lists that manage it. The Local Stack is what stores the chain of local variables when utilizing nested functions. The Local Data list is what stores the current data. So since this one is just a single list of your current variables, you can easily use the item get operator that scratch provides for easy variable access. Unlike before where I would make a get function that stored the local variable in a global variable. But since it was one global variable it was impossible to do operations between local variables without making another global variable. Doesn't really matter what the details are, all you need to know is that this is much better and really easy to use. Also since it is so small, you can easily bring this sprite into your existing project and click drag each function to your made sprite or where ever you want these functions. There are only 7 functions. Easy to move!
The demo shows a simple creation of 3 variables (1, 2, 3) and then another batch of 2 (banana, apple) and then a third of 3 (chair, table, lamp). This shows that you can create variables in the local data list like normal. And then call the Push function that will take it all and store it in the stack. And the Pop function will remove the current data and move the top of the stack (bottom in this case) over to the data list.