|
aegir Newbie
Joined: 05 Jan 2003 Posts: 2
|
Posted: Sun Jan 05, 2003 12:44 am
random color communication script |
Can someone help me with a fun script?
On my mud we have a gossip channel that is a main communication line ... ex
gossip This is a message!
The mud shows ... Aegir gossips This is a message!
I was wondering if anyone can help me with a
script that would randomly colorize each letter... color on my mud is done by ~a through ~m
with text following after the ~"letter" qualifier.
so I want be able to ex.....type
gos This is a message!
Aegir gossips ~bT~dh~ai~ks ~ei~gs (and so on)
this would show "This is" in random color on the mud..
I am a fairly smart person but have rudimentary zmud script knowledge but any help will be VERY appreciated.
thanx
Aegir |
|
|
|
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Sun Jan 05, 2003 5:11 am |
#AL aegir {#LOOP 1,%len(%-1) {#SENDP {~~%case(%random(1, 13), a, b, c, d, e, f, g, h, i, j, k, l, m)%copy(%-1, %i, 1)}}}
Untested. Probably won't handle punctuation. May need a #CR at the end.
LightBulb
Senior Member |
|
|
|
aegir Newbie
Joined: 05 Jan 2003 Posts: 2
|
Posted: Mon Jan 06, 2003 4:16 am |
quote:
#AL aegir {#LOOP 1,%len(%-1) {#SENDP {~~%case(%random(1, 13), a, b, c, d, e, f, g, h, i, j, k, l, m)%copy(%-1, %i, 1)}}}
Untested. Probably won't handle punctuation. May need a #CR at the end.
LightBulb
Senior Member
Thank you lightbulb!!!!
Ive played with this alias and played with it..
I cant seem to get it to work ... does anyone have a similar script for another channel on another mud i may be able to adapt?
thanx
aegir |
|
|
|
LightBulb MASTER
Joined: 28 Nov 2000 Posts: 4817 Location: USA
|
Posted: Mon Jan 06, 2003 5:55 am |
Just noticed, never put the "chat" command in. You could try:
#AL aegir {#SENDP "chat ";#LOOP 1,%len(%-1) {#SENDP {~~%case(%random(1, 13), a, b, c, d, e, f, g, h, i, j, k, l, m)%copy(%-1, %i, 1)}};#CR}
LightBulb
Senior Member |
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|