Targetting using an 'Info here' function

Posted by Peglegz on Fri 21 Oct 2005 11:30 PM — 5 posts, 17,233 views.

#0
I play the MUD Achaea, and the mud has a function called Info Here, that allows you to go IH and get the items / mobs in a room, with their name and specific number. An Example is

"shrine52858" a shrine of Ourania
"grate56283" a sewer grate
"totem153509" a runic totem
"sigil225276" a monolith sigil
"dracolich107415" a skeletal dracolich
"virago273631" a fierce virago
"virago264894" a fierce virago
"tsalmaveth70077" a mounted tsalmaveth
"virago217859" a fierce virago
"virago177770" a fierce virago
"snake173997" a green eyelash viper
"box88259" a comical jack-in-the-box
"snake295309" a green eyelash viper
Number of objects: 13

Now, I'd like to see about getting a targetting system that would grab preset names and random numbers, and target them as they show up, while ignoring what I don't need. For example, if there's an IH like:

"totem102020" a runic totem
"mingruk7760" a burly mingruk slave
"gnoll10102" a formidable gnoll guard

I want it to ignore the totem, target the mingruk, and switch the target to gnoll on the message:

You have slain a burly mingruk slave, retrieving the corpse.

That line would show up after every kill, so the slain object could be replaced with a wildcard.

I've seen a script written to do this for zMud, and I'd willingly take that script, and re qrite it to work in MUSHclient, but well... I don't rightly know how. Basically, I'd have it use IH (gagged of course) when I enter a room (as long as the plugin is enabled, I don't want to do it all over the place, such as walking through the forests, that'd be needless)and target based on a preset list of targetables, and ignore based on a list of ignoreable things.
Australia Forum Administrator #1
Can you give a bit more detail? Like the IH function, does it start with a line that could be the basis for starting gagging?

How do you target things? eg. maybe "target "mingruk7760""

How would you decide what to attack? eg. a list of things like "mingruk", "gnoll" etc.?

You don't really need a list of things to attack AND a list of things to ignore do you? Either you attack everything that is not on the ignore list, or you attack only things on the attack list.
#2
The info here doesn't start with any specific lines, it simply lists the items in the room, I *think* it does so in the order they came to be in the room. the only thing that comes with every info here is the alias used to bring it up (as I said, IH, so it's not one that I made)

I target using something I found here actually, just an alias t * that sends %1 to a variable of target. All my attacks are directed @target. If I want to kill a mingruk, I t mingruk and attack it until it's dead, then switch targets as needed.

I suppose I don't need a list of things to ignore, as long as it were to only attack what was on an allowable list, because sometimes in a room there are things I can attack, and things I can't (because they'd lay me out). Also, I don't have, nor will I ever have a group attack, so it'd have to be able to keep the targets seperate.
#3
Sorry to bump this, but has anyone anymore ideas on this subject?
Australia Forum Administrator #4
I don't really want to write the script for you, but I would be trying to make a trigger to match the general line, something like:

"*" a *

And then when that matches have a script that targets the first one that matches your list. I have done a post recently on Lua's find command, but if you want to use VBscript there are heaps of posts about doing scripts here too.