Mudlet Questions

by Rika

Back to Mechanic's Corner.

Unknown2011-02-11 22:22:15
QUOTE (AquaNeos @ Feb 11 2011, 11:57 AM) <{POST_SNAPBACK}>
Latest version does it, but it's kinda broken(might be just for me though) or you can use the screendump script someone posted on the mudlet forums.


Uhhh. Using Mudlet for linux. Didn't see anything. Tried using the screendump script, it wouldn't work for me. Maybe I'm just a dunce.
Dysolis2011-02-12 04:57:16
Hey if I do this send ("Phantomsphere attack" ..target). I tried doing the normal way which aliases work , like ^w5$. I did numbers because I think it's easier to remember that. It seems that unite look and move work but not attach shatter or detonate.
Lysandus2011-02-12 07:39:44
Ok, a noob question:

How do you check where the variables are?

Also, how do I flag the variable true or false?

For example, I got a trigger line where enemy uses shield, as a warrior my next attack should be a cleave or raze.

Any thoughts? Mudlet plus Lua is all very confusing for me, just came from MUSHclient. :/
Unknown2011-02-12 07:53:54
The variables aren't stored in a single place that you can look up, unless you create a script to track and echo them yourself.

Lua code like this should work:
To set your variables:
tar = "orc" -- for words, aka strings, put it in quotation marks. The default assumes numbers, which have no quotation mark requirement.

To see your variables:
echo("\\ntarget = " .. target) -- gives the value of the variable called "target."
echo("\\neshield = " .. eshield) -- gives the value of the variable called "eshield."

To do what you put into your example:
if eshield == 1 then
send("cleave " .. target .. " head") -- sends the command "cleave orc head" to Lusternia, if your target is orc and eshield is 1.
else
send("swing " .. target) -- normal swing if they aren't shielded.
end

To my knowledge you should just be able to paste the above things into trigger lines or aliases and they should start working.
Lysandus2011-02-12 09:50:43
Edit:

Ok, forget the last question I posted, how do I set an alias or trigger to use an existing Alias?

example, the alias 1 is to drink water

so I made a script on alias 2 where

If Hungry == true then
send ("eat food")
else
send ("")
end
Unknown2011-02-12 09:52:45
QUOTE
How do you check where the variables are?

Just make an alias with the following Lua code:

CODE
for k, v in pairs(_G) do    
   echo("Variable:", k, "has the value:", v)
end


For local variables, you will have to use debug.getlocal()
Unknown2011-02-12 09:53:51
QUOTE (Lysandus @ Feb 12 2011, 09:50 AM) <{POST_SNAPBACK}>
Hrm, How do you put color in your echos?


cecho()

CODE
cecho("Hi! This text is red, blue, and green.")

cecho("<:green>Green background on normal foreground. Here we add an ivory foreground.")

cecho("All of this text is green.", "green")

cecho("All of this text is navy on cyan.", "navy", "cyan")
Unknown2011-02-12 10:12:10
QUOTE (Lysandus @ Feb 12 2011, 09:50 AM) <{POST_SNAPBACK}>
Edit:

Ok, forget the last question I posted, how do I set an alias or trigger to use an existing Alias?

example, the alias 1 is to drink water

so I made a script on alias 2 where

If Hungry == true then
send ("eat food")
else
send ("")
end


expandAlias() is what you need.
Unknown2011-02-13 14:34:43
Has anyone had an issue with logging not working correctly? I had logging turned on for almost the entire ascension event, but all it captured in the file was a little piece of the middle.

The logging button in mudlet was highlighted the entire time, too.
Vadi2011-02-13 15:11:30
Some people had it using 2.0 snapshots with html... are you on that?

(I personally just set my buffer to 10mil lines and screendumped at the end)
Unknown2011-02-13 15:20:55
Yep, I am on 2.0 and using HTML, thanks for the heads up.

Whenever you do a screen dump, is there a command somewhere to export everything in the buffer, or do you just copy and paste it all?
Vadi2011-02-13 16:13:37
Diamondais2011-02-16 20:08:18
Would you be able to put mudlet and any work done on it on an external harddrive and still be able to have it work?
Unknown2011-02-16 21:03:36
QUOTE (diamondais @ Feb 16 2011, 08:08 PM) <{POST_SNAPBACK}>
Would you be able to put mudlet and any work done on it on an external harddrive and still be able to have it work?


Not as yet, sadly. The paths are still hard-coded at present, as far as I am aware.
Fuyu2011-02-26 12:26:21
Help. Help. I just got back after two weeks or so of "ghosting" and have only checked the code stuff now. I noticed I wasn't able to use the search function. E. g. If I tried searching for the trigger line for eq recovery, search turns up nothing. I replaced my version with the most current one and had refreshed my m&m version as well. At first, the search function worked..then it suddenly stopped working while I was preoccupied with setting pipe stuff in m&m.sad.gif
Fuyu2011-02-26 12:27:39
QUOTE (Fuyu @ Feb 26 2011, 08:26 PM) <{POST_SNAPBACK}>
Help. Help. I just got back after two weeks or so of "ghosting" and have only checked the code stuff now. I noticed I wasn't able to use the search function. E. g. If I tried searching for the trigger line for eq recovery, search turns up nothing. I replaced my version with the most current one and had refreshed my m&m version as well. At first, the search function worked..then it suddenly stopped working while I was preoccupied with setting pipe stuff in m&m.sad.gif


okay..it suddenly worked. I have no idea what's happening.sad.gif
Fuyu2011-02-26 12:47:15
Can I ask for help regarding setting colors in cecho?I can't tolerate uber bright colors and while I prefer dark colors, my eyes can't see too dark colors, too. I'm leaning towards having sky blue, lavender colors and such, but I don't know how to set them. Was only able to set cyan so far. Thanks!
Vadi2011-02-26 12:55:54
Put showColors() into an alias and run it
Fuyu2011-02-26 13:58:22
QUOTE (Vadi @ Feb 26 2011, 08:55 PM) <{POST_SNAPBACK}>
Put showColors() into an alias and run it


just make an alias and put showColors() in the big box?
Anisu2011-02-26 17:51:27
QUOTE (Fuyu @ Feb 26 2011, 02:58 PM) <{POST_SNAPBACK}>
just make an alias and put showColors() in the big box?

yep!