Re: alias.c

From: Argus (argus@argy.com)
Date: 07/14/96


> I am also having a problem with alias.c
> Took it off the FTP site and put in all the changes par alias.README on 
> the ftp site.  Put aliases don't save.  it seems that it is creating junk 
> files in my circle/lib directory though.  Any ideas??

are you sure you created the directories needed in lib??  you need 
plralias directory under lib then the alpha directories under that

circle
   |--lib
        |--- plralias
                   |--- A-E
                   |--- F-J
                   |--- K-O
                   |--- P-T
                   |--- U-Z
                   |--- ZZZ
(notice they are caps)

in utils.c you need to make sure it looks something like this:

int get_filename(char *orig_name, char *filename, int mode)
{
  char *prefix, *middle, *suffix, *ptr, name[64];

  switch (mode) {
  case CRASH_FILE:
 prefix = "plrobjs";
 suffix = "objs";
 break;
  case ETEXT_FILE:
 prefix = "plrtext";
 suffix = "text";
 break;
  case ALIAS_FILE:
 prefix = "plralias";
 suffix = "alias";
 break;
  case PLAN_FILE:
 prefix = "plplan";
 suffix = "plan";
 break;
  default:
return 0;
    break;
  }

  if (!*orig_name)
    return 0;

  strcpy(name, orig_name);
  for (ptr = name; *ptr; ptr++)
    *ptr = LOWER(*ptr);

  switch (LOWER(*name)) {
  case 'a':  case 'b':  case 'c':  case 'd':  case 'e':
    middle = "A-E";
    break;
  case 'f':  case 'g':  case 'h':  case 'i':  case 'j':
    middle = "F-J";
    break;
  case 'k':  case 'l':  case 'm':  case 'n':  case 'o':
    middle = "K-O";
    break;
  case 'p':  case 'q':  case 'r':  case 's':  case 't':
    middle = "P-T";
    break;
  case 'u':  case 'v':  case 'w':  case 'x':  case 'y':  case 'z':
    middle = "U-Z";
    break;
  default:
    middle = "ZZZ";
    break;
  }

  sprintf(filename, "%s/%s/%s.%s", prefix, middle, name, suffix);
  return 1;
}

this tells the mud where to store the files...

Hope this helps


-Peace
Argus

http://www.argy.com
telnet: eclipse.argy.com 7777



This archive was generated by hypermail 2b30 : 12/07/00 PST