|
Problem calling script from an alias
|
Reply to this subject
Start a new subject
 
Refresh page
| Posted by |
Vink
(7 posts) bio
|
| Date |
Sat 03 Nov 2001 08:43 PM (UTC) [ quote
] |
| Message |
in my auto-target setup i an alias
Alias: target *
Send:
Enabled: checked
All other options: unchecked
Label: Target_Alias
Script: OnAliasTarget
and in my script file
sub OnAliasTarget (thename, theoutput, thewildcards)
world.setvariable "target", thewildcards (1)
world.note "Victim set to " & thewildcards (1)
end sub
and another alias
Alias: b
Send: backstab @target
Enabled: checked
Expand variables: checked
All other options: unchecked
when i type "target man"
it should send the message "Victim set to man"
but it does not
when i type "b" it should backstab man, but i get a popup
box that says variable target not defined
why doesn't it work? | top |
|
| Posted by |
Nick Gammon
Australia (18,772 posts) bio
Forum Administrator |
| Date |
Reply #1 on Sun 04 Nov 2001 04:20 AM (UTC) [ quote
] |
| Message |
I tried what you did and it worked OK.
Your problem with the second alias is that the first one didn't work and set the variable, why I don't know.
Do you have scripting enabled, and the appropriate script file in the "Script file" box in the scripting configuration tab? |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
| Posted by |
Nick Gammon
Australia (18,772 posts) bio
Forum Administrator |
| Date |
Reply #2 on Sun 04 Nov 2001 04:44 AM (UTC) [ quote
] |
| Message |
Also, be cautious when typing in the alias that you don't slip in an extra, unnoticed, space.
For example, this won't work:
target *(space)
or
target(space)(space)*
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|
| Posted by |
Vink
(7 posts) bio
|
| Date |
Reply #3 on Sun 04 Nov 2001 03:58 PM (UTC) [ quote
] |
| Message |
yep i didn't have scripting enabled, i assumed it was automatically enabled for some reason
*whap me*
thanks nick | 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.
1,467 views.
Reply to this subject
Start a new subject
 
Refresh page
top
Comments to:
Gammon Software support
Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )