mIRC Home    About    Download    Register    News    Help

Print Thread
#249235 19/11/14 07:23 PM
Joined: Dec 2013
Posts: 779
N
Nillen Offline OP
Hoopy frood
OP Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
I'd like to see an implementation for forcing variables to re-evaluate in a timer like %!variables that's similar to the $!ident. My variable is being updated every second and I'm using the timer to display the variable every second as well. My workaround was to use
Code:
.timer 30 1 echo -a $!t 
alias -l t return $iif(%variable,$v1,0)


While on the topic, could we also get wildcard support for $timer(examp*)?



Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Joined: Jul 2006
Posts: 4,150
W
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 4,150
We can't get this because %!variable is already a valid variable name, adding this would break scripts, you can use the simple $+ to workaround this:

Code:
.timer 30 1 echo -a % $+ variable


And check this https://forums.mirc.com/ubbthreads.php/topics/232005/$timer%28%29#Post232005


#mircscripting @ irc.swiftirc.net == the best mIRC help channel
Joined: Dec 2013
Posts: 779
N
Nillen Offline OP
Hoopy frood
OP Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
Ah yeah, that's true.. Didn't really think ahead there. Didn't know about % $+ variable though. It works like a charm, thanks.

Hmm, that goes way back... There shouldn't be any issues with finding wildcard matches for timers should there?


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net

Link Copied to Clipboard