Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ MUSHclient
➜ Suggestions
➜ Few suggestions
It is now over 60 days since the last post. This thread is closed.
Refresh page
| Posted by
| Xevira
(11 posts) Bio
|
| Date
| Thu 16 Feb 2006 03:53 AM (UTC) |
| Message
| On ImportXML and ExportXML, if referenced off a world object (gotten by GetWorld or GetWorldByID) to import into/export from THAT world. I've got a plugin that wishes to import keypad definitions (after prompting the user if they wish to have them). Using the "world." scope would reference the plugin/world as it does now.
-------
Allow the keypad definitions to be viewable/settable, even in plugins. Using the functions within plugins would reference the world's keypad.
-------
Add a GetFileName function that exposes the API call that opens the Open/Save file dialog box. The function would take a file filter (a list/array/table depending on the script language), a start path (empty/omitted if using current location) and an Open/Save flag (true for Save, defaults to false if omitted). The function would return a string result, either containing the filename or nothing if cancel was clicked. Errors would return back an error code.
-------
Allow the notepad buffer size to be definable? I use that for a display page for a channel logger plugin I made. I notice though that the notepad tends to LOCK if filled up with too much. I mean LOCK as in the entire text becomes selected and I can't use ReplaceNotepad to reset the text to anything new. I've since changed it to check the size of the entire log display that will be shown, stripping off old lines that will not fit, keeping it relatively small (around 10000 characters). I'm also converting it from Jscript to Lua and will use the io functions to SAVE the text to a file so the lines will not be lost (as I timestamp all the lines and mark Connect/Disconnects with full date-time stamps)
-------
That is all, for now. Great mud client, Nick! :D
| | Top |
|
| Posted by
| Nick Gammon
Australia (23,165 posts) Bio
Forum Administrator |
| Date
| Reply #1 on Fri 17 Feb 2006 03:19 AM (UTC) |
| Message
|
Quote:
On ImportXML and ExportXML, if referenced off a world object (gotten by GetWorld or GetWorldByID) to import into/export from THAT world.
What language are you using? It seems to work OK for me in Lua:
w = GetWorld ("test")
Note (ExportXML (w, 0, "mytrigger"))
This exported from the world "test" not the current world.
In VBscript the syntax is a bit different:
Set w = GetWorld ("test")
Note (w.ExportXML (0, "blockhead"))
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Nick Gammon
Australia (23,165 posts) Bio
Forum Administrator |
| Date
| Reply #2 on Fri 17 Feb 2006 03:20 AM (UTC) |
| Message
| |
| Posted by
| Nick Gammon
Australia (23,165 posts) Bio
Forum Administrator |
| Date
| Reply #3 on Fri 17 Feb 2006 03:21 AM (UTC) |
| Message
|
Quote:
Allow the notepad buffer size to be definable?
The notepad buffer is a straight Windows edit control. Its behaviour is really that of an edit control and can't be easily changed (its size varies a bit by operating system). |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Nick Gammon
Australia (23,165 posts) Bio
Forum Administrator |
| Date
| Reply #4 on Fri 17 Feb 2006 03:23 AM (UTC) |
| Message
|
Quote:
Add a GetFileName function that exposes the API call that opens the Open/Save file dialog box.
I'll look into that. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Nick Gammon
Australia (23,165 posts) Bio
Forum Administrator |
| Date
| Reply #5 on Sun 26 Feb 2006 12:57 AM (UTC) |
| Message
|
Quote:
Add a GetFileName function that exposes the API call that opens the Open/Save file dialog box.
Version 3.74 now has a utils.filepicker function (available from Lua only) which exposes the Windows file picker. See release notes for more details. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Xevira
(11 posts) Bio
|
| Date
| Reply #6 on Mon 27 Feb 2006 05:49 PM (UTC) |
| Message
| Sorry for not responding...
Some clarification, it is the Import that doesn't allow importing to outside the current world space.
I've tried this:
function OnImport()
w = GetWorld("LuaTesting")
w.ImportXML("<keypad><key name='Ctrl+2' >Test</key></keypad>")
end
Where LuaTesting is the world the test plugin was installed on. The alias used merely calls the function within the plugin script. Calling said function gives this error message:
Line 1: <keypad> tag cannot be used inside a plugin (problem in this file)
| | Top |
|
| Posted by
| Nick Gammon
Australia (23,165 posts) Bio
Forum Administrator |
| Date
| Reply #7 on Fri 03 Mar 2006 05:51 AM (UTC) |
| Message
| Plugins are not designed to allow certain things to be done, which were considered "global" to the world, such as the world name, macros and so on.
You could consider making the plug use Accelerator in its startup phase, to map keystrokes to things you want to do:
http://www.gammon.com.au/scripts/doc.php?function=Accelerator |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | 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.
25,547 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top