 |
demoneyoungblood Apprentice
Joined: 16 Dec 2002 Posts: 114 Location: USA
|
Posted: Fri Apr 22, 2005 2:39 am
Channel flags and whatnot. |
Ok... im familiar with using ismember and variable lists and whatnot, but not quite sure how to go about doing this one:
there are the following channels:
ooc
clan
ask
answer
gossip
auction
music
grat
shout
tell
reply
bitch
ic
newbie
now... ive set them all in a variable (channels)
and I want to accomplish the following
rather than have to setup an alias for all channels
I want to invoke a flag on all of the channels...
IE:
When i type ooc <text>, i want it to do
ooc Demone speaks <text i type here>
Demone speaks being the flag that goes on *all* the channels
so i also want to be able to do
gossip blabla
it will:
gossip Demone speaks <text>
not sure how to do that the most effectively, as normally id just setup an alias for each channel. I know ill be using a few channel flags, so ill be setting up a variable for them as well, i just need to know how to do the channel sorting itself so i dont have to do repetitive aliases. Any help would be appreciated, as i dont know how to refer to the command issued itself :-D |
|
_________________ -Demone YoungBlood |
|
|
 |
Maelstrom Apprentice
Joined: 10 Feb 2005 Posts: 158
|
Posted: Fri Apr 22, 2005 3:14 am |
#VAR channels {ooc|clan|ask|answer|gossip|auction|music|grat|shout|tell|reply|bitch|ic|newbie}
#ONINPUT {^({@channels}) (*)$} {#SUBSTITUTE {%1 Demone speaks %2}} |
|
|
 |
demoneyoungblood Apprentice
Joined: 16 Dec 2002 Posts: 114 Location: USA
|
Posted: Fri Apr 22, 2005 7:17 am hrm... broken color reset sucks |
ok... got that working, even using the random stuff i wanted... but now i have another problem...
The reset color symbol is broken on the mud, so i have to manually set the return color for each channel....
now if i do
gossip lalala
and it sends the:
gossip <myflag,mycolors> how do i append a tag on the end of mycolors based on the channel being used as each channel is a different color :-D
example: goss blablah
returns: goss <mytag,mycolor> <onecolortoken> blahblah
ooc blabla
returns: ooc <mytag,mycolor> <anothercolortoken> blahblah
* spends too much time playing with useless stuff i guess *
seing as i use a string list variable to store 36 different flags and use the same 36 on all channels randomly, i cant just change the flags to use one single color reset token at the end, as it would mess up the other channels.... any ideas? |
|
_________________ -Demone YoungBlood |
|
|
 |
Vijilante SubAdmin

Joined: 18 Nov 2001 Posts: 5182
|
Posted: Fri Apr 22, 2005 9:36 am |
Change your channel list to a record variable with the channel names as keys and the color codes as values. Then you can use %db to retrieve the correct sequence.
|
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
 |
|
|