world.window? world.openwindow? Something like that..

Posted by Deqitosv on Tue 19 Jun 2001 07:43 PM — 8 posts, 29,614 views.

USA #0
I was wondering if it would be possible to cause the world, from a script, to open a new window (with various properties setable from the script such as dimensions, always on top, and location), where we could place our own customizable text (either basic text, maybe a world.htmlwindow, that would allow us to load a homepage to modify with scripts etc). I would use such a thing for a status (of sorts) window.
Also the mud I play on does not send a line feed after it's prompt, until I, or it, sends text. Is it possible to add a check mark option in triggers to "match on on non-linefed text", so I could use information in my prompt in a window such as that, or in variables, etc? Thanks!
Australia Forum Administrator #1
The script functions 'sendtonotepad' and 'appendtonotepad' will do that.

You can't control their location, but you can send basic text.

You can send to them from triggers to, so with a bit of work you can make a script that detects (say) inventory output, and makes a copy in the extra window.

As for matching on non-linefeed text, this is on the drawing board, but so far MUSHclient waits for a newline. You can always match once the newline arrives, so you can update your HP etc., it just won't be updated until a second later.

Also, on MXP-enabled MUDs they can send stuff like HP, movement points etc. as tags, which update immediately, linefeed or no linefeed.
USA #2
The notepad is all well and good, but not quite what I wanted. I like running my world maximized, and for using the notepad, I'd have to swap out of it, whereas I'd like a small window that I can place ontop of everything (like in the upper right hand corner). Ah well good client! I advertise it on the mud I'm on!
Australia Forum Administrator #3
For small amounts of status information you can use:


world.setstatus "blah"


You can use this to monitor HP, current exits, that sort of thing. You can also send direct to the status line from a trigger.
USA #4
Well I do use world.setstatus for some things, but this amount of data would be too much for that status bar, but too little, and too much work to swap out to a notepad. There's no way we could have a little defineable "status" window added? (I've heard rumour, though I've never used zmud, that it has something like this)
Australia Forum Administrator #5
Well, anything's possible. :)

Right now I'm getting MXP perfected, so that sort of thing will have to wait a little while.

If you are familiar with COM programming you could always make another little app, that MUSHclient scripts could invoke and send text to. Make it "always on top" and you have your status window.
#6
Is there a way to take statistics such as hitpoints/spellpoints and display them in the status bar using scripts?
Australia Forum Administrator #7
Sure, that is easy enough.

You can use world.setstatus in a script to do that.

For a reasonably simple case, the latest versions of MUSHclient let a trigger send directly to the status line.

For example:


Match on: <*hp *m *mv>
Send: %1 hp %2 mana %3 movement
Send to: Status


The trigger would match on the prompt line (each asterisk is a wildcard) and then send the results to the status line, where %1 %2 and %3 represent the 3 matching wildcard values.