Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ MUSHclient
➜ Lua
➜ I just learned what a function is 10minutes ago. Who wants to help! :)
I just learned what a function is 10minutes ago. Who wants to help! :)
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Pages: 1
2
Posted by
| Shaun Biggs
USA (644 posts) Bio
|
Date
| Reply #15 on Mon 09 Apr 2007 01:54 AM (UTC) |
Message
| is assist a function, or an alias? If it's a function, then it needs to be assist(). If it's an alias, then it needs to be Execute( "assist" ). If it's a mud command, then Send( "assist" ). |
It is much easier to fight for one's ideals than to live up to them. | Top |
|
Posted by
| ReallyCurious
USA (50 posts) Bio
|
Date
| Reply #16 on Mon 09 Apr 2007 02:04 AM (UTC) Amended on Mon 09 Apr 2007 02:22 AM (UTC) by ReallyCurious
|
Message
| thanks Shaun. works now.
Yea it was a mud command. I'm still very used to using simple triggers from my old client, "#action {you are hungry} {eat food}" for example.
Does this way seem too sloppy? Is there something else I should be doing here?
Here is the end result:
World1.
<aliases>
<alias
match="autto *"
enabled="y"
send_to="12"
sequence="100"
>
<send>world2 = assert (GetWorld ("world2"),
"world2 not open") -- get world
assert (world2:IsConnected(),
"world2 is not connected") -- check connected
world2:SetVariable("assister1", "%1")
world2:SetVariable("assister2", "%1")</send>
</alias>
</aliases>
World2:
<triggers>
<trigger
enabled="y"
match="*is dead! R.I.P."
send_to="12"
sequence="100"
>
<send>SetVariable ("assister1",GetVariable("assister2"))</send>
</trigger>
<trigger
enabled="y"
expand_variables="y"
match="@assister1 misses *"
send_to="12"
sequence="100"
>
<send>Send ("assist")
SetVariable ("assister1", "kdfjskfjsf")</send>
</trigger>
</triggers>
| Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #17 on Mon 09 Apr 2007 04:26 AM (UTC) Amended on Wed 18 Apr 2007 10:30 PM (UTC) by Nick Gammon
|
Message
|
Quote:
I'm still very used to using simple triggers from my old client, "#action {you are hungry} {eat food}" for example.
You can easily make an alias to do just that:
<aliases>
<alias
match="#action {*} {*}"
enabled="y"
send_to="12"
sequence="100"
>
<send>
require "addxml" -- addxml extension
-- add the trigger
addxml.trigger {
match = "%1",
send = "%2",
sequence = 100,
enabled = true,
}
ColourNote ("white", "green", "Added trigger to match on '%1', sending '%2'")
</send>
</alias>
</aliases>
Now if I type:
#action {you are hungry} {eat food}
I see echoed:
Added trigger to match on 'you are hungry', sending 'eat food'
And, this trigger is now added to the trigger list:
<triggers>
<trigger
enabled="y"
match="you are hungry"
sequence="100"
>
<send>eat food</send>
</trigger>
</triggers>
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #19 on Mon 09 Apr 2007 08:48 AM (UTC) |
Message
| You know what a really strange thing is?
On the zMUD forum, there is a posting from Reallycurious, entitled "I just learned what a function is 10minutes ago. Who wants to help! :)" - and it reads:
Quote:
I'm going to have multiple connections to a mud and I want to create an 'auto assist' type thing for some of the windows. In my old client I'd just trigger something like "$assistvariableguy massacres" = assist, etc and then make an alias #alias {autto %1} {#var assistvariableguy %1}.
Are you posting exactly the same question on all the client forums?
Here is the link:
http://forums.zuggsoft.com/phpbb/viewtopic.php?t=27001 |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| ReallyCurious
USA (50 posts) Bio
|
Date
| Reply #20 on Mon 09 Apr 2007 07:12 PM (UTC) |
Message
| Sure, I did post 'almost' the same question on the zmud forum, but there was 1 difference I didn't mention on zmud forum.
I'm shopping for a new mud client and I want to make sure whichever one I commit to is going to be the right choice for me(support/functionality).
I probably wouldn't have even found MUSHclient if the latest zmud 7.21 didn't cause a code4 error and crash immediately when i ran it. So I asked my friends in irc for what I should do and I got 3 suggestions: dl an earlier version of zmud/dl MUSHclient(i never heard of it)/dont bother switching your client.
Now it's been about a week since I've been using mushclient and I'm liking it a lot. I think the forum support here has been great these last few days too. I don't see myself switching to zmud...
On another note, I'm going to try and get a rescue script and heal script working with LUA with both of them being accessable from other worlds. I'll be posting those soon :) | Top |
|
Posted by
| Nick Gammon
Australia (23,133 posts) Bio
Forum Administrator |
Date
| Reply #21 on Mon 09 Apr 2007 09:28 PM (UTC) |
Message
| I'm glad you like it, and look forwards to seeing your scripts posted here. :) |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Onoitsu2
USA (248 posts) Bio
|
Date
| Reply #22 on Tue 10 Apr 2007 02:07 AM (UTC) |
Message
| I too tried to install zMud, not planning on switching, would not over my own dead body either, but wanted to attempt to make conversions from zmud a ton easier for myself. I failed miserably with v7.21 due to the same crash error, and just used an older version, 6.16 in fact. I am attempting to determine the DB formatting, whether it is using SOME standard system, or a system all its own, because IF it is a standard system, then that is a step in the right direction for a mapper, or at least using maps made using zMud :)
Laterzzz,
Onoitsu2 | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
61,732 views.
This is page 2, subject is 2 pages long:
1
2
It is now over 60 days since the last post. This thread is closed.
Refresh page
top