Jump to content

Matt's Scripts for FL


English lad

Recommended Posts

Thanks - I previously had a targetting script which I remember downloading at the same time as this one, Part of it seems to be present in the Default World, but the other was far more powerful and flexible - Anybody know if its about anywhere?

Bah this is going to frustrate the hell out of me - mainly because I should know how to write a script that will do this myself - I just haven't written anything for so long I'm messing up basic commands.

Matt if your still out there it was the Macro script - I.E the one where you could set variables for f5 through 8 for different skills spells, and also set f2 f3 f4 for quick weapons changes.

Link to comment
Share on other sites

Guest emp_newb
use alias to change weapons and save the F's for Skills you wish to lead with.

I have my 9 key from keypad bind to : F(string) @target

With F5 Dirt, F8 charge ...

f9 tell Did you at least leave my things?

:)

Link to comment
Share on other sites

As long as were on the topic of Mushclient, do you guys know how to create an alias for a target player.

For example, theres an alias: Target Chayesh

"Chayesh" will now be your target and will link with your other macros/aliases such as: Bash "target", trip "target", charge "target", etc.

Know what I mean?

Link to comment
Share on other sites

Re: WoS, Bash "target", trip "target", charge "target", etc.

Re-produce the murder aliases and macro then change 'murder' to 'dirt.' I'll explain it a little.

The 'target *' alias sets the target variable - you don't need to mess with this. The f5 macro outputs f5_macro_alias. The alias named f5_macro_alias fires when its output is matched and does what's in it's send box.

There's a bit of backwards-ness here because the macros don't have scripting capability. When you push one of the f-keys all mush is doing is sending what's there as if you had typed it out. Don't ask me why this is how it is. I remember Nick G saying something about how the macros were the first thing he made for the client before scripting or anything and just never bothered re-coding them b/c you can just do it this way. Don't quote me, though.

So you go to the f6 macro and have it output 'f6_macro_alias'. Now, whenever you push f6 it's sending 'f6_macro_alias.' To catch that you make a new alias that fires on 'f6_macro_alias.' Normally you'd have an alias for like cdi to cast detect invis - and the idea here is the same. If you really wanted to you could type out 'f6_macro_alias' instead of pushing the f-key is what I'm getting at here.

Anyway, you make a new alias called f6_macro_alias. Make sure the send to dropdown box is changed from world to script and the expand variables box is checked. That box is what makes the "@whatever" work.

With that stuff set you go into the alias' big send box and do: world.send "dirt @target"

Whenever you push f6 the macro sends 'f6_macro_alias' and that text is caught by the alias that matches the text and instead what you send to the mud is 'dirt @target' - THAT is caught and @target catches the target variable you set with the alias to whatever text you type in. Repeat for 7 and 8 and whatever.

You can just paste this into the alias configuration and then make the f6 macro into f6_macro_alias to see another example.


match="f6_macro_alias"
enabled="y"
expand_variables="y"
send_to="12"
sequence="100"
>
world.send "dirt @target"

If you have the alias window open, like where you can click Add.. Edit.. Remove.. and stuff mush knows if you paste an alias.

CHECK on what script your mush is set to run. World details>Scripting>Scripts and look at the top for the Scripting Language: dropdown. The world.send thing is a vbscript command. If you want to use lua or whatever you can lookup the syntax http://www.gammon.com.au/scripts/function.php If you want to use what I posted it has to be set to vbscript and the little enable script checkbox has to be on.

------------------------

Edit: I found the old macro stuff EL was asking for buried in the 50megs site. They're there if you want to look at them or get 'em again.

Link to comment
Share on other sites

Thats the one I wanted !!! Thanks Matt.

As there your scripts this sounds a little silly but i'm suprised you scrapped the earlier one as it is TONS more powerful than the later one used.

Oh and for anybody else who decides to use it - theres even a snazzy helpfile if you type MacroHelp character sensitive - not sure if it prompts you to that anywhere in it.

Link to comment
Share on other sites

  • 2 years later...

Ok just started using Mushclient so I figured I'd add these. I'm trying to tweak the ticktimer for my prompt but don't see what I need to change in the plugin. I see where Matt has his prompt but do I need to put my entire prompt in there to replace that one or do I need to change where it gets the time from entirely?

Edit: My prompt is: <1/1hp 1/1m 1/1mv> D 16 4452 <6388 GOLD>

%n%P%C<%h/%Hhp %m/%Mm %v/%Vmv> %l6%i%L %l6%t%L %l8%X%L <%l3%g%L GOLD> %c

Messing with it, still have no clue how to tweak it to my prompt.

Link to comment
Share on other sites

What's the ticker code look like? If I saw the code I'm pretty certain I could help you tweak it.

Jibber, is there anything you can't do? :)

I think Nasa is looking for someone to figure out how to colonize mars, you might want to give them a ring ;)

Also, to Hilltop for my prompt I use $%g that way gold just shows up with a dollar sign in front, well unless you're not in america, then maybe your keyboard doesn't have a dollar sign. Do other countries keyboards have the dollar sign as the shift 4? I imagine not.

Link to comment
Share on other sites

<?xml version="1.0" encoding="iso-8859-1"?>

name="FlTicker"

author="Mattamue"

id="4217787a996a35824e97226a"

language="VBscript"

purpose="Notify a player of an incoming tick."

date_written="2006-04-11 23:57:16"

requires="3.73"

version="1.0"

>

</p><p> Get out your favorite text editor and open up the plugin file. You'll need to change some of the code for this plugin to work with your own personal promt. The promt will need to have the hour listed somewhere. If you don't know how to list the hour in your promt you're already in trouble. Ask on the forums and you should get friendly hugs and help.</p><p>

enabled="y"

match="^\[(\d+)\/(\d+) (\d+)\/(\d+) (\d+)\/(\d+) (\d+) (\d+) (D|M) (\d+)\]"

name="TickTrigger"

regexp="y"

script="TickTimer"

sequence="100"

>

enabled="y"

match="Abandon hope, all ye who enter here..."

script="OnLoad"

sequence="100"

>

>

world.note "Twenty-five past."

</p><p> ' Dim globals - I don't know what dim is, I just know you have to dim things.</p><p> dim hour</p><p> dim hourly</p><p> ' Called from the "Abandon hope, all ye who enter here..." trigger</p><p> ' this script gives the hour variable a numeral when you connect - can't hurt to be safe</p><p> sub OnLoad (name, line, wildcards)</p><p> hour = 0</p><p> end sub</p><p> ' this next subroutiene is called from the trigger that matches my promt:</p><p> '</p><p> ' [715/715 752/752 412/412 3850 16623 D 22] which is, in regular terms:</p><p> ' ^&#092;[(&#092;d+)&#092;/(&#092;d+) (&#092;d+)&#092;/(&#092;d+) (&#092;d+)&#092;/(&#092;d+) (&#092;d+) (&#092;d+) (D|M) (&#092;d+)&#092;]</p><p> '</p><p> ' This is the trigger you'll have to change to get the thing to work with</p><p> ' your promt.</p><p> sub TickTimer (name, line, wildcards)</p><p> ' "hourly" is a variable that gets checked every time the mud spits out my</p><p> ' promt. When I "GetTriggerWildcard" blah blah 10 - I'm telling the script</p><p> ' to get the 10th variable which is the hour of the day I've put into my promt.</p><p> '</p><p> ' If you put your own promt in you'll have to figure out its regular expression</p><p> ' and what variable place it holds.</p><p> hourly = GetTriggerWildcard ("TickTrigger", "10")</p><p> ' Here's the simple if statement that runs the ticker. Every time I hit enter</p><p> ' the promt is spit out again. The script sees the promt and grabs the number</p><p> ' for the hour and puts it into the "hourly" variable.</p><p> '</p><p> ' If it's the same as the "hour" variable then nothing happens. If it's different</p><p> ' that means that the hour changed and THAT means that a tick happened. The script</p><p> ' puts the new number for the hour into the "hour" variable and starts watching</p><p> ' for another change. Simple.</p><p> '</p><p> ' It's a lot of variable checking, but Mush is fast enough to handle it.</p><p> if hour <> hourly then</p><p> hour = hourly</p><p> world.resetTimer "Ticker"</p><p> end if</p><p> end sub</p><p>

script="OnHelp"

match="FlTicker:help"

enabled="y"

>

</p><p> Sub OnHelp (sName, sLine, wildcards)</p><p> world.Note world.GetPluginInfo (world.GetPluginID, 3)</p><p> End Sub</p><p>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...