Register forum user name Search FAQ

Gammon Forum

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 ➜ SMAUG ➜ SMAUG coding ➜ adding color

adding color

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Frobozz   (75 posts)  Bio
Date Tue 16 Nov 2004 04:21 PM (UTC)
Message
Version, stock SMAUG FUSS.

I've been trying to add color into the channels so that just the channel name is in a different color with the output text in another.

In other words Immtalk would come out as say.. Blue and the message text comes out as yellow.

Thoughts?

This is what my code looks like right now:

case CHANNEL_IMMTALK:
case CHANNEL_AVTALK:
sprintf( buf, "<Immortal: $n %c $t", channel == CHANNEL_IMMTALK ? '>' : ':' );
position = ch->position;
ch->position = POS_STANDING;
act( AT_IMMORT, buf, ch, argument, NULL, TO_CHAR );
ch->position = position;
break;
}
Top

Posted by Zeno   USA  (2,871 posts)  Bio
Date Reply #1 on Tue 16 Nov 2004 09:54 PM (UTC)
Message
Just use the stock prompt symbol colors. Such as &R is red. SmaugFUSS should have that enabled.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
Top

Posted by Robert Powell   Australia  (367 posts)  Bio
Date Reply #2 on Wed 17 Nov 2004 06:21 AM (UTC)
Message
in color.c or color.h you can difine the color of many things, if you look in there, there are a couple of tables

char * const pc_displays[MAX_COLORS] = and
const sh_int default_set [MAX_COLORS] = both in color.c

You can change the values there to suit the color that you want, also you would have to reset the colors ingamne to apply the new values, cant remember the command off hand tho color reset all i think it is, if i make no sence im totaly sorry as im realy tired and should be in bed.


Just a guy having a bit of fun. Nothing more, nothing less, I do not need I WIN to feel validated.
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.


12,804 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.