PDA

View Full Version : LostRanger's collection of assorted miscellaneous scripts



LostRanger
05-08-2017, 02:53 AM
So, back in the days before Lich, before Stormfront, and... well, GSIV was still GSIII and it was still necessary to roll for stats, I wrote the autoroller. This was probably the first widely used thing that got in between GS4 and the Wizard FE at the time... but was obsoleted when GSIV released.

Since my recent return, I've taken up writing lots of random Lich scripts... so I figured I'd make a place to mention that they exist and collect bug reports and feature requests. You can see them all with
;repo list --author=LostRanger
but here's some more info. Most of these have very detailed information (including usage) in their ;repo info

Most of my scripts have a very detailed help command, accessible as ;script help. For ;foreach, just type ;foreach by itself. The ;repo info usually contains a subset of the documentation as well.

For everyone:
xnarost: Experimental Narost fork. See its dedicated thread here (http://forum.gsplayers.com/showthread.php?109483-xnarost-eXperimental-Narost-fork)

spellmerge: Collects spammy spell effect messaging and reduces it to a single line, e.g. "<spell effect> fades from Wyrom, Kenstrom, and Haliste." instead a line for each player. Tries to retain the original messaging as much as possible, but with some adjustments for grammar. Also affects the GROUP verb, but this can be turned off. Essential for participants in large RP events.

foreach: Do some things with everything in your inventory... or in a container... or on the ground... or in your locker. Examples: ";foreach scroll in satchel;read item" or ";foreach noun=ticket in inv;get item;bundle" or ";foreach box in inv;get item;put item in locker" or ";foreach gem in sack;get item;put item in gemcutter;turn gemcutter;get item from gemcutter;put item in sack". By default it matches based on item type (not name), see docs for how to match by name/noun.

herbs2: There's an existing (partially outdated) script that simply displays a table of what herbs heal what wounds. This is a likewise-outdated copy of it, but the herbs for your current injuries are in monsterbold.

box: Lockpicking assistance for rogues and customers alike, but using your own brain. This adds commands (intended to be used with macros) for disarming and picking a box -- without needing to specify the noun for the box. (It'll target whatever is in your hands). Prior to picking, it can grab your vaalin (or other) lockpick even if it shares an adjective with a bunch of other lockpicks. There's also commands for accepting a box being given to you (and remembering who gave it to you) and returning that same box to the same person. For customers, ;box list usually shows all of your boxes and ;box grab will blindly grab one from a container to offer to your smith (or to begin picking yourself). Note that container inventories aren't always up-to-date in Lich, ;box scan tries to fix this by looking inside every container.

loglore: Loglore watches your log for your own loresinging results and the results of ANALYZE, INSPECT, ASSESS and the Abandoned Inn crystal, condenses them all together into a single entry for an item, and writes it to a timestamped logfile under Lich\Logs\GSIV-Charactername. (This is the same folder Tillmen's log script writes to.) Must be trusted to work since it writes files. The non-loresinging-related tidbits can be turned off if desired. For best results, ;autostart add loglore on your bard. Loglore does not loresing for you, but will work with any script that does.

inspect: If you ;inspect <item> (as opposed to normal 'inspect'), this script will alter all of the messaging to include some more detailed information. For example: "You estimate that a polished black leather pack can store a significant amount (100-119 lbs) with enough space for any number (10+) of items." or "Your careful inspection of a peascod-bellied doublet allows you to conclude that it is soft leather armor that covers the torso and arms. (ASG 6: Full Leather)". Since this is triggered by script, this has no performance penalty on normal gameplay. You can ;alias inspect=;inspect to have this affect all manual inspects (script-triggered commands bypass the aliasing mechanism).

findwarcamp: Findwarcamp is a fork of ;wander heavily modified to search for warcamps. Unlike the existing ;warcampfind, Findwarcamp prefers searching rooms that are adjacent to a 'warm' Sigil of Location result (i.e. those where a disturbance is detected nearby) and only searches adjacent to 'cold' rooms if no more warm options are available. This makes it somewhat more efficient at finding warcamps, and means it generally self-limits its own boundaries when started in area already known to be warm. For best results, travel in 20-30 room steps manually looking, then start findwarcamp once you're 'warm'.



For developers and cartographers:
mapnav: This is a utility script that you generally shouldn't need to use, but it can fix room connections in the mapdb if mapmap is getting them wrong. ;mapnav <command> makes a note of the current room, sends the command, waits for the room to change, and creates the appropriate linkage in the mapdb. Also useful for ;mapnav inspect, though it's basically just ;echo Room.current.inspect P.S. You should really understand how the mapdb works before using this.

logxml: Simple fork of Tillmen's log script, but this one writes raw XML rather than player-visible text. Predates the arguably-more-useful showxml script.

showxml: Creates an XML window in Stormfront and shows raw XML there in real-time. Also serves as an example on how to create custom stream windows and react to them being closed in the client.

LostRanger
05-09-2017, 07:16 PM
box 0.5 released, adding support for using calipers.

LostRanger
05-11-2017, 01:46 PM
In the pipeline/possible projects

box 0.6 - ETA: Soon(tm)
* Support for DETECT in addition to DISARM
* (Stormfront Only) Optional lockpicking window -- copy all responses to ;box commands (disarm/lockpick/etc) results to a dedicated window for easier tracking in a complicated room.

box future - ETA: None Yet
* Incorporate the functionality of ;calipers into ;box. This not only reduces number of scripts required, but also should improve global performance (since ;calipers runs all the time, ;box has the option of only hooking when it needs the info)
* Possibly add ;maxlock or some other calculation stuff into ;box as well -- maybe factoring in room effects determined by lmas sense if I can find the formulas
* Possible safety options to prevent measuring or picking a lock without disarming first or forcing confirmation.

herbs2 0.2 - ETA: Soon(tm)
* Fix Monsterbold in non-Stormfront clients

herbs2 future - ETA: None Yet.
* Rewrite from scratch to support other herbs.
* ;herbs2 target to show herbs required to heal that target based on appraise messaging.

stormsync - Stormfront Only - ETA: Real Soon Now(tm), or possibly after Savant is released.
* Add support for character-wide macros (same in all macro sets) (like ctrl/alt macros are in Wizard FE), or possibly a 'layering' system
* Add support for global names highlights like Wizard FE
* Add a way to define macros via commandline.
* Add a way to define presets for highlights and a script to add to those presets.
* Add options to make window configuration global.
Note: Stormsync most likely will require the relevant portions of the settings to be saved serverside so it has a way to capture them on change -- and I have no idea how it will manage multiple installs/conflicts yet.

Dazmar
05-11-2017, 02:40 PM
:thanx:

LostRanger
05-12-2017, 04:27 PM
box 0.6 released

version: 0.6 (2017-05-12)

known issues:
Lockpicking window message may occasionally get sent to the wrong place, resulting in duplicated messages in the main window.

changelog:
version 0.6 (2017-05-12)
* (StormFront only) add experimental support for copying all lockpicking results to a custom window.
* add support for DETECT instead of DISARM

LostRanger
05-23-2017, 01:56 PM
box 0.7 was released awhile back, mainly fixing the message duplication issues when using the results window.

Added findwarcamp: Findwarcamp is a fork of ;wander heavily modified to search for warcamps. Unlike the existing ;warcampfind, Findwarcamp prefers searching rooms that are adjacent to a 'warm' Sigil of Location result (i.e. those where a disturbance is detected nearby) and only searches adjacent to 'cold' rooms if no more warm options are available. This makes it somewhat more efficient at finding warcamps, and means it generally self-limits its own boundaries when started in area already known to be warm. For best results, travel in 20-30 room steps manually looking, then start findwarcamp once you're 'warm'.

LostRanger
05-26-2017, 04:07 PM
Added xnarost: Experimental Narost fork. More info here (http://forum.gsplayers.com/showthread.php?109483-xnarost-eXperimental-Narost-fork).

LostRanger
06-09-2017, 04:53 PM
Added spellmerge:


Spellmerge condenses the effects of certain mass spells falling off (and other similar effects) to reduce screen
scroll.

Rather than seeing:

<spell effect> fades from Wyrom
<spell effect> fades from Kenstrom
<spell effect> fades from Haliste

You'll see

<spell effect> fades from Wyrom, Kenstrom, and Haliste.

This works by slightly delaying the spell messaging while it collects additional names to add to the list. As
such, spell effect messaging may appear slightly out-of-order from how it actually happens.

Spell effects on you are not affected by either the delay nor the merging effect.

This version also traps the output of GROUP, which can be used as a quick basic test of functionality.
GROUP trapping functionality will become optional in a future release.

A new version of Spellmerge should be released today (I'm waiting for a Dreavening to give it some final testing). Preview of the upcoming changelog (this is all already implemented, just waiting for release):



version 0.3 (2017-06-09)
* Add Symbol of Disruption falloff ("The churning spectral aura suddenly vanishes from around PLAYER.")
* Added the capability of customizing which spell effects are handled and how they are handled. They can now be
squelched outright, ignored (in which case they are sent to the client normally), or merged (default behavior)
* You can now view the entire list of effects with ;spellmerge effects
* Added minor tweaks to ;spellmerge stats
* The replacement engine now supports procedurally generated effect messaging when merging effects, instead of simple substitution.
* Tweaked merge effect messaging for Kai's Triumphs (1007), Troll's Blood (1125), and Hand of the Arkati (1605).
* Check to see if we should be awake immediately on startup rather than waiting for game data.
* ;spellmerge stop now works properly instead of breaking the client's ability to communicate with the game.
* Dropped "Experimental" tag

zephyrii
06-12-2017, 02:08 PM
Thanks for the work in creating new scripts! I really like xnarost. However i suggest you change the name to narostx instead to help discovery. If you put in ;repo download narost, people won't find it whereas if you have it as narostx, it'll pop up that there's another one.

LostRanger
06-19-2017, 12:56 AM
Added foreach 0.1:

Executes a series of commands for each item matching the criteria you specify.

Some examples:



;foreach gem in cloak; get item; appraise item; put item in container
;foreach scroll in satchel;read item # Includes papyrus, palimpsets, and other scroll-like things too!
;foreach noun=ticket in inv;get item;bundle # Bundle all your tickets!
;foreach box in inv;get item;put item in locker # Shove all your boxes in a locker!
;foreach gem in sack; get item;put item in gemcutter;turn gemcutter;get item from gemcutter;put item in sack # Cut gems!


By default it matches based on item type (not name), see docs for how to match by name/noun.

LostRanger
06-19-2017, 03:38 AM
Thanks for the work in creating new scripts! I really like xnarost. However i suggest you change the name to narostx instead to help discovery. If you put in ;repo download narost, people won't find it whereas if you have it as narostx, it'll pop up that there's another one.

Possible, but I kind of like the x- prefix for a few reasons (It kind of also doubles as "experimental"), and having ;narost and ;narostx installed at the same time can make things confusing with Lich autocompleting script names if you're actually trying to use both.

Besides, I'm already trying to convince Tillmen to adopt the changes into the official version, so that may become moot anyways.

I really, really wish we had a proper actual repository ala GitHub where people can submit pull requests ("Here's a bunch of changes to your script, will you accept them? We can discuss why or why not") and whatnot, like "proper" software development has.