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


Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  Suggestions
. . -> [Subject]  Global 'Master' Buffer

Global 'Master' Buffer

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


Posted by Tricuspa   USA  (13 posts)  [Biography] bio
Date Sun 05 May 2002 05:03 PM (UTC)
Message
Presuming it hasn't been yet mentioned or already mentioned.

I wonder if its possible to set up an auto buffer for all worlds. What this would do is simply log a number of lines chosen by the user for all worlds. A master log per se. As well this would have the option to automatically save after a speicifed time.

Once in a blue moon the system crashes and can't be recovered (you have to close out). This prevents you from saving any logs or data you may have (and sometimes losing where you last left off). You lose the log data or may not even have it on. Being able to have this emergency log would be helpful.

The master log would record like this

<Name of World 1> Soinso says....
<Name of World 1> You pose
<Name of World 2> Someoneelse poses
<Name of World 1> Soinso says....
<Name of World 2> You pose...

etc...

Anyway hope this explains this idea!
[Go to top] top

Posted by Nick Gammon   Australia  (23,016 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Sun 05 May 2002 10:15 PM (UTC)
Message
You could do that now with a bit of scripting. What you need is a "master" world - maybe an existing one, or maybe one you aren't using for anything else.

The master world would have a log file open, and maybe a trigger set up to "omit from log" everything that happens in it (eg. match on "*", omit from log).

Then each other world has an appropriate trigger set to catch the things you want to log. That trigger calls a script, like this:


sub LogIt (sName, sLine, aryWildcards)
dim w

  set w = world.GetWorld ("Master World")

  if not w is nothing then
         w.writelog "<" & world.WorldName & "> " & sLine
   end if

end sub


What this is doing is using GetWorld to find the master world (by name), and then, if found, telling that world to log the line, prepended with the world name.

By using a log file, you get the benefit of automatic saving every couple of minutes.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[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.


10,149 views.

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.

[Home]


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]