Is there a way I can change a variable from the command line?

Posted by BishopOsiris on Wed 21 Dec 2016 08:44 PM — 4 posts, 20,187 views.

USA #0
I want to change existing variables from the command line while I'm logged into the mud. Is there a way to do this?

Also, is there a way to change a variable based on a trigger from the mud? Say I have a variable @food and it's set to beef. In the mud if I look in my container and I see:

(10) a whole chicken

I want the variable @food set to chicken.

Thanks
USA Global Moderator #1
Yes, either with the script prefix, set in menu Game->Configure->Scripting, or the immediate window, via Game->Imediate. Both ways should let you call SetVariable.
Australia Forum Administrator #2
There is a tutorial about variables here:

http://www.gammon.com.au/forum/?id=10863
USA #3
Useful video. Thanks Nick.