Difference between revisions of "Mudlet"

From icesus
Jump to navigation Jump to search
(put the new mudlet trigger zip in the link)
Line 17: Line 17:
 
<br>
 
<br>
 
<br>
 
<br>
[https://naga.icesus.org/wiki/images/8/86/Mudlet_basic_triggers.zip Download the .zip file here]
+
[https://naga.icesus.org/wiki/images/8/86/11.8.20.cleaned.zip Download the .zip file here]
  
  

Revision as of 20:13, 11 August 2020

Mudlet is a modern MUD client which is supported by ICESUS.

You can get it from here:

Mudlet download page

Notice about upgrading from version 4.5.1: Mudlet version 4.5.1 is missing the update function, so you need to manually update from mudlet website, or you will not be able to update via the client for future updates.



Here you can download a .zip file containing a mudlet .trigger file, in which you can find some basic triggers you can perhaps use, and maybe get a more hands-on feel on how things work in mudlet if you are not experienced with it.

Some included types of triggers: buff/debuff highlights/party alerts, few EQ-related triggers, some maneuver/spellcast highlight/reports, potion timer, and so on.

Download the .zip file here


Tips for Mudlet:

Keybinds and triggers 101:

How to set keybindings: Click the "keys" button on toolbar (image 1), then click "add item", name the key, define a command the key will send once pressed (like "up", "dig grave" etc)., then on the right side of "key binding" there is "Grab new key" button. click it, then press the button you wish to bind, then press "save item", and then "activate". you will want a green check-mark to appear next to they key on the list (image 2). And you are done!

Triggers:

Mudlet triggers have many options to choose from when making one (image 5). Say you want to highlight a message for when Power of Earth buff ends on you. First you get the message for it, paste it to a new trigger you added by clicking "add item" (just like in making a keybind), and then you must select what type of type trigger it will be. For our purposes we selected "Start of line" (image 3), so it will trigger only when the message appears in the start of a line. After this, we click "highlight" box on lower right side, and select colours for background and foreground (background will be ON what color the text will be written, and foreground is font color basically). then Save item, make sure it is activated (again like in keybinding), and you are done! All code goes in the big white box below pattern and trigger type, when creating a trigger in mudlet.

You can test triggers by using built-in echo system (image 4), used by

`echo <your line here> 

The ` mark is done with (shift + ´) (above enter button in my keyboard) and then press space so it wont end up on top of the following letter.


Now, say you want to make an trigger that echoes something back. Start like in previous trigger, but now, we choose "perl regex" as the type, instead of "start of the line". Perl regex will be used (as far as i know) on all triggers that use any sort of commands (such as echo, send, etc).

Echo is done like so:

echo ("hello world")

put in the big white box under trigger selection/pattern section. If you want the echo on a new line, do

echo ("\nHello world!") 

If you wish to send a command into the mud, do

send ("dig grave") 

If you wish to choose the colour of the echo, you can use

fg("cyan")  
echo ("\nHello world!")

Other kind of echo command is

cecho (" <red>Hello <white>World") 

that would color "Hello" as red and "world" as white.


Highlighting an entire line by using triggers is done with

selectCurrentLine() 

In image 6 we select the entire line that has "party report" in it, and change it's foregroundcolor to yellow (rbg).


Timers:

So far i only used tempTimer() myself, so I will use that as an example here. See image 7, it echoes two messages, both on a new line. Command is

tempTimer(time in seconds here, [[ your code here ]]) 

Multi-line triggers:


Rather self-explaining, you can set multiple patterns that will fire the same trigger, as shown in the image 8.


Wildcards (is this what they are called? i dont remember!):


Say you want to make "x mastery increased!" party report trigger. Tthe pattern will be:

Your (.+) mastery increased!

In this case the (.+) will choose any amount of characters that are between the words "Your" and "mastery".

The code to send it to the game is:

send ("party report " ..matches[2] .. " mastery increased!")


If you were to select "matches[1]" you would get the entire line (i think!). If you had more than one (.+) in the code, (I guess) the second would be "matches[3]". The concatenation is done with " .. ", and the result of this code is shown in image 9.


(you can choose to not show your lines send (the echo test part here) from Settings -> Input line -> uncheck "show the text you send"-box.


You can send multiple commands/echos/etc with Perl regex-type triggers, just put them on their own lines.

If a pattern varies, like it has a gender specific word in it, you can use

you whack (him|her|it) in the head with your axe!

to cover all the options

This pretty much covers my knowledge of Mudlet at this point.