Daved2010-04-07 01:07:51
So I'm rewriting my system, looking at treant as a guide. I've put up my main script file and a snippet from my affliction tracking script file on lua.pastebin here:
http://lua.pastebin.com/A36csk44
http://lua.pastebin.com/buTiziBm
I'm getting this error from MUSHClient:
Any advice is appreciated.
http://lua.pastebin.com/A36csk44
http://lua.pastebin.com/buTiziBm
I'm getting this error from MUSHClient:
CODE
Run-time error
World: AMTS
Immediate execution
.\\affs.lua:21: attempt to index global 'affs' (a nil value)
stack traceback:
        .\\affs.lua:21: in main chunk
        : in function 'require'
        :7: in main chunk
World: AMTS
Immediate execution
.\\affs.lua:21: attempt to index global 'affs' (a nil value)
stack traceback:
        .\\affs.lua:21: in main chunk
        : in function 'require'
        :7: in main chunk
Any advice is appreciated.
Unknown2010-04-07 01:39:39
First, you need to initialize affs before putting functions and things into it. Second, you need to return the table at the end for the require to do its job right.
Sylphas2010-04-07 02:09:27
QUOTE (Zarquan @ Apr 6 2010, 09:39 PM) <{POST_SNAPBACK}>
First, you need to initialize affs before putting functions and things into it. Second, you need to return the table at the end for the require to do its job right.
You do? I don't return any of mine and they work fine.
Unknown2010-04-07 11:43:06
Well, you don't have to, but the behavior is just a little different in certain uses of the module.
Unknown2010-04-08 15:08:01
For those who don't visit the MUSHclient forums, here's a screencast from Nick on the basics of scripting in MUSHclient. Nick has several excellent tutorials in video form now, so I highly recommend you subscribe to his YouTube channel and learn more about his software!
Unknown2010-04-09 16:53:53
QUOTE (Zarquan @ Apr 8 2010, 11:08 AM) <{POST_SNAPBACK}>
For those who don't visit the MUSHclient forums, here's a screencast from Nick on the basics of scripting in MUSHclient. Nick has several excellent tutorials in video form now, so I highly recommend you subscribe to his YouTube channel and learn more about his software!
While I don't use MUSHclient myself (much prefer using native than running something in WINE) I think that's a very cool thing, and would second Zarquan in encouraging users of MUSHclient (which by all acounts is a fine piece of software, even though I'm Mudlet biased myself) to learn as much as they can from the creator of the program. It's an opportunity which should not be passed up, IMNSHO
Unknown2010-04-16 18:41:18
Is it possible to do this, for example:
I have VariableA, which at first has a value of 0. Then, I want to add values to VariableA but without removing the initial value. So, for example, VariableA would have a value of 0, 1, then 0, 1, 2, and so on.
I have VariableA, which at first has a value of 0. Then, I want to add values to VariableA but without removing the initial value. So, for example, VariableA would have a value of 0, 1, then 0, 1, 2, and so on.
Eldanien2010-04-16 18:48:17
If you're storing them as strings, then you'd use a concatenating function. In lua, it's ..
VariableA = VariableA .. ", 2"
VariableA = VariableA .. ", 2"
Unknown2010-04-16 20:40:01
Thanks!
Siam2010-04-18 16:23:54
What's the mush equivalent of #wait in Nexus?
Unknown2010-04-18 17:07:38
QUOTE (thisismydisplayname @ Apr 18 2010, 05:23 PM) <{POST_SNAPBACK}>
What's the mush equivalent of #wait in Nexus?
Using a temporary timer.
Assuming Lua:
DoAfter (3, "say Three seconds seems like so long!")
If you need to send it to something besides world, use DoAfterSpecial.
DoAfterSpecial (3, 'EnableTriggerGroup ("mygroup", 1)', sendto.script)
Siam2010-04-18 17:13:12
QUOTE (AllergictoSabres @ Apr 19 2010, 01:07 AM) <{POST_SNAPBACK}>
Using a temporary timer.
Assuming Lua:
DoAfter (3, "say Three seconds seems like so long!")
If you need to send it to something besides world, use DoAfterSpecial.
DoAfterSpecial (3, 'EnableTriggerGroup ("mygroup", 1)', sendto.script)
Assuming Lua:
DoAfter (3, "say Three seconds seems like so long!")
If you need to send it to something besides world, use DoAfterSpecial.
DoAfterSpecial (3, 'EnableTriggerGroup ("mygroup", 1)', sendto.script)
thanks!
Unknown2010-04-20 00:10:33
Ok, I got a problem. I was trying to get treant to work, but all this copying and pasting for all triggers become tiresome when I get stuff that keeps breaking off. I'll keep highlighting all this...
(example, lets say I want this to activate a trigger or something)
"Spreading its great wings, the eagle resounds a single sharp cry before soaring off to the ether."
(So then I go to paste it, to the trigger, and then I get this.)
"Spreading its great wings, the eagle reso"
(It just cuts off! Another thing, I was told to make wrap output 0, but then I get this kinda stuff.)
look
The Aetherplex Chamber.
The spherical chamber is formed from a hollow geode comprised of do
zens of precious gemstones. Large jagged formations of ru
bies, sapphires, diamonds and emeralds line the walls and ceiling.
The floor has been cut and polished to a brilliant shine, reveali
ng concentric circles of brilliant colours. Upon close examinati
(AGH! I hate that! But apparently Treant needs to be set up to wrapwidth 0! I only wanted to change the text style, Courier gives me a headache. The only time I can fix this is when I right click the screen and wrap output, which I'm not supposed to from the instructions.)
Also, what could a good front be? I can't stand small letters that look funny. And when I find an ok type of font, the map and such are all messed up. SYSTEM is ok, just a little too big. I'd take a picture of my settings, but I can't for some stupid reason.
This is all on the OUTPUT configuration by the way.
(example, lets say I want this to activate a trigger or something)
"Spreading its great wings, the eagle resounds a single sharp cry before soaring off to the ether."
(So then I go to paste it, to the trigger, and then I get this.)
"Spreading its great wings, the eagle reso"
(It just cuts off! Another thing, I was told to make wrap output 0, but then I get this kinda stuff.)
look
The Aetherplex Chamber.
The spherical chamber is formed from a hollow geode comprised of do
zens of precious gemstones. Large jagged formations of ru
bies, sapphires, diamonds and emeralds line the walls and ceiling.
The floor has been cut and polished to a brilliant shine, reveali
ng concentric circles of brilliant colours. Upon close examinati
(AGH! I hate that! But apparently Treant needs to be set up to wrapwidth 0! I only wanted to change the text style, Courier gives me a headache. The only time I can fix this is when I right click the screen and wrap output, which I'm not supposed to from the instructions.)
Also, what could a good front be? I can't stand small letters that look funny. And when I find an ok type of font, the map and such are all messed up. SYSTEM is ok, just a little too big. I'd take a picture of my settings, but I can't for some stupid reason.
This is all on the OUTPUT configuration by the way.
Everiine2010-04-20 01:36:50
You need to set Lusternia's in game wrapwidth to 0, but you can have the MUSHclient wrapwidth at anything you want (like 80). The reason is if the Lusternia wrapwidth is set, it sends the equivalent of a line break to the client, and thus MUSH won't capture the entire line. But it doesn't break the line with its own wrapwidth.
Or something to that effect. I only know it works.
Or something to that effect. I only know it works.
Dynami2010-04-22 03:09:12
I have been trying to incorporate something into my target alias that will allow me to announce who I target if I have the raid variable set to on. I have had no problems setting the variable, but I am stuck on how to get the other part to work.
EDIT: NEVERMIND! Thank you, Sidd!
CODE
SetVariable("announce", "%1")
Note("Announcements: " .. GetVariable("announce"))
Note("Announcements: " .. GetVariable("announce"))
CODE
SetVariable("target", "%1")
Note("Target: " .. GetVariable("target"))
announce = GetVariable("announce")
if announce == on then
  Send(clt4 Targetting: ".. GetVariable("target"))
Note("Target: " .. GetVariable("target"))
announce = GetVariable("announce")
if announce == on then
  Send(clt4 Targetting: ".. GetVariable("target"))
EDIT: NEVERMIND! Thank you, Sidd!
Unknown2010-04-22 03:42:57
Just so people know the solution in case someone has a similar problem:
CODE
SetVariable("target", "%1")
Note("Target: " .. GetVariable("target"))
if GetVariable("announce") == "on" then
Send("clt2 Targetting: " .. GetVariable("target"))
end
Note("Target: " .. GetVariable("target"))
if GetVariable("announce") == "on" then
Send("clt2 Targetting: " .. GetVariable("target"))
end
Unknown2010-04-25 20:49:12
I think this might be a serious bug. I have auto sipping, but it's been trying to heal my health even though I'm not hurt one bit. It happens everytime I turn it on. I've debugged it, and here's as follows.
sip health
You take a drink from a garnet vial.
The potion heals and soothes you.
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
» Debug messages ENABLED
You may drink another health, mana, or bromide potion.
» Disabled 'offbal_health' failsafe
» OnBalanceGained health
» Checking 2 queues: balance healing
» Balance scan
» Healing scan
» .. aff = health_high, cure = sip health
» Flag 'health_try' set to 'true'
» OnBalanceLost health
» Flag 'elixir' set to 'health'
» !! Failsafe setup with 2 second delay: health
» OnPrompt 2520 2100 2550 10 ex-
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
sip health
You take a drink from a garnet vial.
» Sipped health
» Flag 'health_try' removed
» !! Failsafe setup with 8 second delay: offbal_health
» Disabled 'health' failsafe
» Flag 'last_cure' set to 'sip health'
» Flag 'elixir' removed
» Poison afflictions enabled
The potion heals and soothes you.
» Flag 'last_cure' removed
» Queued action - function: 021FA188
» Checking 1 queues: elixir
» Elixir scan
» Poison afflictions disabled
» OnPrompt 2520 2100 2550 10 ex-
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
» Auto sipping DISABLED
You may drink another health, mana, or bromide potion.
» Disabled 'offbal_health' failsafe
» OnBalanceGained health
» Checking 2 queues: balance healing
» Balance scan
» Healing scan
» OnPrompt 2520 2100 2550 10 ex-
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
I haven't changed a flipping thing with the Treant settings.
I even reinstalled the Treant package to try to fix this
sip health
You take a drink from a garnet vial.
The potion heals and soothes you.
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
» Debug messages ENABLED
You may drink another health, mana, or bromide potion.
» Disabled 'offbal_health' failsafe
» OnBalanceGained health
» Checking 2 queues: balance healing
» Balance scan
» Healing scan
» .. aff = health_high, cure = sip health
» Flag 'health_try' set to 'true'
» OnBalanceLost health
» Flag 'elixir' set to 'health'
» !! Failsafe setup with 2 second delay: health
» OnPrompt 2520 2100 2550 10 ex-
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
sip health
You take a drink from a garnet vial.
» Sipped health
» Flag 'health_try' removed
» !! Failsafe setup with 8 second delay: offbal_health
» Disabled 'health' failsafe
» Flag 'last_cure' set to 'sip health'
» Flag 'elixir' removed
» Poison afflictions enabled
The potion heals and soothes you.
» Flag 'last_cure' removed
» Queued action - function: 021FA188
» Checking 1 queues: elixir
» Elixir scan
» Poison afflictions disabled
» OnPrompt 2520 2100 2550 10 ex-
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
» Auto sipping DISABLED
You may drink another health, mana, or bromide potion.
» Disabled 'offbal_health' failsafe
» OnBalanceGained health
» Checking 2 queues: balance healing
» Balance scan
» Healing scan
» OnPrompt 2520 2100 2550 10 ex-
2520h, 2100m, 2550e, 10p, 10400en, 11150w ex-
I haven't changed a flipping thing with the Treant settings.
I even reinstalled the Treant package to try to fix this
Unknown2010-04-25 21:09:20
I'm 99% sure it's not a bug in my code, but you should always e-mail me these things instead of posting them here.
Tip: check your variables to see what Treant thinks is your max health.
Tip: check your variables to see what Treant thinks is your max health.
Ardmore2010-04-25 21:46:37
Yeah that's what I was curious about. Do you have an alt who you also play that has more health?
Aidyn2010-04-27 13:48:19
Not only the max health but check the sipping value. If it is set higher than your current health could also create the same issue. I haven't played in so long, but I use Treant myself. Albeit, I can't remember whether it had a minimum value for health or not...