Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
auth_update crash
Dec 23, 2017, 10:15 pm
By Remcon
check_tumble
Dec 18, 2017, 7:21 pm
By Remcon
parse description bug
Dec 15, 2017, 10:08 pm
By Remcon
Couple bugs
Dec 12, 2017, 5:42 pm
By Remcon
Bug in disarm( )
Nov 12, 2017, 6:54 pm
By GatewaySysop
LoP 1.46
Author: Remcon
Submitted by: Remcon
LOP 1.45
Author: Remcon
Submitted by: Remcon
LOP Heroes Edition
Author: Vladaar
Submitted by: Vladaar
Heroes sound extras
Author: Vladaar
Submitted by: Vladaar
6Dragons 4.3
Author: Vladaar
Submitted by: Vladaar
Users Online
CommonCrawl, Yandex

Members: 0
Guests: 10
Stats
Files
Topics
Posts
Members
Newest Member
478
3,708
19,242
612
Jacki72H
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » General » Coding » Customizable ANSI Color Code
Forum Rules | Mark all | Recent Posts

Customizable ANSI Color Code
< Newer Topic :: Older Topic > SWR port

Pages:<< prev 1 next >>
Post is unread #1 Aug 19, 2003, 2:53 pm   Last edited Nov 24, 2007, 3:59 pm by Samson
Go to the top of the page
Go to the bottom of the page

Greven
Magician
GroupMembers
Posts204
JoinedMar 5, 2005

I'm trying to port this to code to SWR. It use slightly modified SMAUG color code, but I still really hate it's inconsistancy, so I went with this package. Some modifacations, of course, pretty easy, until I hit this:
void ch_printf( CHAR_DATA *ch, char *fmt, ... )
{
    char buf[MSL*2];
    va_list args;
    va_start( args, fmt );
    vsprintf( buf, fmt, args );
    va_end( args );
    send_to_char_color( buf, ch );
}
void pager_printf( CHAR_DATA *ch, char *fmt, ... )
{
  char buf[MSL*2];
  va_list args;
  va_start( args, fmt );
  vsprintf( buf, fmt, args );
  va_end( args );
  send_to_pager_color( buf, ch );
}

Last thing, of course, but SWR does not have va_list as any part of the code. Am I missing something terribly obvious? Or is this something that was in SMAUG that Sean took out? Thanks for the help.
Greven
       
Post is unread #2 Aug 19, 2003, 2:56 pm
Go to the top of the page
Go to the bottom of the page

Greven
Magician
GroupMembers
Posts204
JoinedMar 5, 2005

Nevermind, I figured its out, color.c was missing:

#include
#include

Probably just a difference in the code bases. Sorry bout the waste of forum space.
       
Post is unread #3 Aug 22, 2003, 2:20 am
Go to the top of the page
Go to the bottom of the page

Greven
Magician
GroupMembers
Posts204
JoinedMar 5, 2005

I guess that I do have a problem, all my calls in db.c are producing no colors. Any ideas?
       
Post is unread #4 Aug 22, 2003, 3:22 am
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,639
JoinedJan 1, 2002

Specifically which calls are you referring to? And is this a new install of SWR or one you've been working on for awhile?
       
Post is unread #5 Aug 22, 2003, 8:11 am
Go to the top of the page
Go to the bottom of the page

Greven
Magician
GroupMembers
Posts204
JoinedMar 5, 2005

Sorry, I was really tired, thought that I had put it in, all my calls to send_to_desc_color(). My login screeen has color, and if its an old player, the color shows up, but not if someone is creating a character. And this has been modified alot, but the only modification in this aspect was the placement of send_to_desc_color, and the customizable ansi stuff much later. It did work before, but I think maybe I have to specify somewhere that the new send_to_desc_color needs to be outputting color. Thanks for the help.
       
Pages:<< prev 1 next >>