I ask because it does nothing for me.
What it does is that it pulls out the list of all variables you can edit in the game. After that, to change stuff, you actually have to change those values. Let's say you type in
JavaScript:
SugarCube.state.active.variables
and hit enter, you should see the console print out something. If you click on it (in Chrome, at least), it will open up with a bunch of values. Now, you have 2 ways of changing variables. One way is (in Chrome, haven't tested in other browsers), you double-click the value you want to edit - say, money, for example. Double-click on the numerical value (you do NOT wanna change the variable name), which will give you the option to edit it. You can then change it to some other number, and then just hit enter to save it. After you click on anything that navigates you to a new screen (for example Description in the menu), you should see the changes reflect in your game.
The other option (and my preferred way, as it's much faster), is to just use the console command. You can instead type in
JavaScript:
SugarCube.state.active.variables.money = 5000
and hit enter to change the values. This is much faster in my opinion, since the console will give autofill the values for you - if you just type
JavaScript:
SugarCube.state.active.variables.
, you'll get a dropdown list of all the values you can edit, which is for me as a coder much faster than scrolling and double-clicking things.
One thing to note, if you want to change something that's not numerical in value - your name, for example - make sure to wrap the text in quotes. This is for other Twine games, because I don't think this one allows you to edit any String variables, but if there was a game where you could change your name, you would have to type stuff like
JavaScript:
SugarCube.state.active.variables.playerName = 'James'