Trying to send to all worlds

Posted by Forestsofbliss on Mon 19 Jul 2004 06:45 PM — 3 posts, 14,006 views.

#0
Ok, I've given my main char the following script, and I have an alias:
alias name: :*
send window: %1
script: sendtoallworlds

script:

Sub sendtoallworlds(name, command, wild)
dim otherworld

for each name in world.GetWorldList
set otherworld = world.getworld (name)
otherworld.send command
next

end Sub

What I want is to type :blah blah, and have blah blah
sent to every world that I have open. What it does is send
:blah blah, and does not drop the : for all worlds, and on top of that it sends just blah blah to my main world. I figure that the alias itself is sending the blah blah to the main world, which I know I can stop, but how do I get it to drop the :, cuz i keep avatar chatting all of my commands? Thanks for any help.
Australia Forum Administrator #1
The field "command" in your script is the entire command you type, hence the : in it. However the wildcard (the asterisk) is returned in wild (1), so what you want is this:


otherworld.send wild (1)
#2
Thanks lots.