-
+/* FIX ... rewrite this to simply check for the existence of the twitroom,
+ * and create it if necessary. No slot-numbers will need to be loaded.
+ */
void loadtroom(void) {
struct quickroom qrbuf;
int a;
/*
- * move a message to another room
+ * move a message to another room FIX Rework this to use name indices
*/
void cmd_move(char *args)
{
c=0;
getuser(&CC->usersupp,CC->curr_user);
+
+ /* FIX This is the primary bit of code that needs to be rewritten
+ * during the cutover. Search for rooms by name rather than by
+ * position in the file. A total rewrite may be necessary.
+ */
for (a=0; a<MAXROOMS; ++a) {
getroom(&QRscratch,a);
if ((a==0)&&(!strcasecmp(towhere,"_BASEROOM_"))) {
* Find a free slot to create a new room in, or return -1 for error.
* search_dir is the direction to search in. 1 causes this function to
* return the first available slot, -1 gets the last available slot.
+ *
+ * FIX This function can be eliminated during the cutover.
*/
int get_free_room_slot(int search_dir)
{
/*
- * create a new room
+ * create a new room FIX Rework this to use name indexing
*/
void cmd_cre8(char *args)
{
CC->usersupp.axlevel = 6;
}
-/* A room's generation number changes each time it is recycled. Users are kept
- * out of private rooms or forget rooms by matching the generation numbers. To
- * avoid an accidental matchup, unmatched numbers are set to -1 here.
- *
- * FIX - This can get removed once the new relationships system is in place.
- *
- */
+ /******************************************************************************/
+ /* FIX It is safe to remove this segment during the cutover */
for (a=0; a<MAXROOMS; ++a) {
getroom(&qr,a);
if (CC->usersupp.generation[a] != qr.QRgen)
if (CC->usersupp.forget[a] != qr.QRgen)
CC->usersupp.forget[a]=(-1);
}
+ /******************************************************************************/
lputuser(&CC->usersupp,CC->curr_user);
strcpy(CC->curr_user,username);
strcpy(CC->usersupp.fullname,username);
+ strcpy(CC->usersupp.password,"");
(CC->logged_in) = 1;
+ /********************************************************/
+ /* FIX this can safely be removed during the cutover... */
for (a=0; a<MAXROOMS; ++a) {
CC->usersupp.lastseen[a]=0L;
CC->usersupp.generation[a]=(-1);
CC->usersupp.forget[a]=(-1);
}
- strcpy(CC->usersupp.password,"");
+ /********************************************************/
/* These are the default flags on new accounts */
CC->usersupp.flags =