[Home] [Downloads] [Search] [Help/forum]

Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  General
. . -> [Subject]  Recalling text via command line?

Recalling text via command line?

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Posted by Winddancer   (26 posts)  [Biography] bio
Date Sun 06 Nov 2022 05:33 PM (UTC)
I found the nice recall text functionality in the Display menu.
Is there a way to
a) call the recall functionality along with options via commandline
b) have the output of the recall search be displayed inside the active world window?

Reason being is that my mud produces messages when you improve a skill in the format of "*** You improved your 'xxx' skill ***"
And I like to occasionally check which skills improved within a given time. When I use the entry from the Display menu or call it directly via its shortcut, ctrl-u, I get the info displayed in a separate window from which I have to choose my world window to continue mudding.
[Go to top] top

Posted by Nick Gammon   Australia  (23,016 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Sun 06 Nov 2022 08:13 PM (UTC)

Amended on Wed 09 Nov 2022 05:16 AM (UTC) by Nick Gammon

Add this alias:

   match="recall *"

local matchWanted = string.lower ("%1")
if matchWanted == '' then
  print "No text to recall given"
end -- if

for line = 1, GetLinesInBufferCount () do
  local lineText = GetLineInfo (line, 1)
  -- do a simple (non regexp) find
  if string.find (lineText:lower (), matchWanted, 1, true) 
     and not GetLineInfo (line, 4)   -- not a Note
     and not GetLineInfo (line, 5)   -- not player input
    ColourNote ("gray", "", lineText)

Template:pasting For advice on how to copy the above, and paste it into MUSHclient, please see Pasting XML.

Then type: recall improved your

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Winddancer   (26 posts)  [Biography] bio
Date Reply #2 on Sun 06 Nov 2022 09:26 PM (UTC)
Perfect! Thanks once again
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum

[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at HostDash]