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: 8
Stats
Files
Topics
Posts
Members
Newest Member
478
3,708
19,242
614
BenitoVirg
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » Bugfix Lists » AFKMud Bugfix List » AFKMud Bug Archive » [Bug] Wizlock is blocking imm...
Forum Rules | Mark all | Recent Posts

[Bug] Wizlock is blocking immortals from logging on when it shouldn't
< Newer Topic :: Older Topic > AFKMud 1.63

Pages:<< prev 1 next >>
Post is unread #1 Nov 22, 2004, 5:21 am   Last edited Nov 13, 2005, 12:11 pm by Samson
Go to the top of the page
Go to the bottom of the page

Samson
Black Hand
GroupAdministrators
Posts3,639
JoinedJan 1, 2002

Bug: Wizlock is blocking immortals from logging on when it shouldn't.
Discovered in: AFKMud 1.63
Danger: Low
Found by: Halex and Samson
Fixed by: Samson and Zarius

---

save.c

In fread_char, locate the following:

            if( !str_cmp( word, "Password" ) )
            {
               ch->pcdata->pwd = fread_string_nohash( fp );
               fMatch = TRUE;
               if( preload )
                  return;
               else
                  break;
            }


Change it to:

            if( !str_cmp( word, "Password" ) )
            {
               ch->pcdata->pwd = fread_string_nohash( fp );
               fMatch = TRUE;
               break;
            }


Then locate the following:

            if( !str_cmp( word, "Status" ) )
            {
               line = fread_line( fp );
               x1=x2=x3=x4=x5=x6=x7=0;
               sscanf( line, "%d %d %d %d %d %d %d", &x1, &x2, &x3, &x4, &x5, &x6, &x7 );
               ch->level        = x1;
               ch->gold         = x2;
               ch->exp          = x3;
               ch->height       = x4;
               ch->weight       = x5;
               ch->spellfail    = x6;
               ch->mental_state = x7;
               fMatch = TRUE;
               break;
            }


Change it to:

            if( !str_cmp( word, "Status" ) )
            {
               line = fread_line( fp );
               x1=x2=x3=x4=x5=x6=x7=0;
               sscanf( line, "%d %d %d %d %d %d %d", &x1, &x2, &x3, &x4, &x5, &x6, &x7 );
               ch->level        = x1;
               ch->gold         = x2;
               ch->exp          = x3;
               ch->height       = x4;
               ch->weight       = x5;
               ch->spellfail    = x6;
               ch->mental_state = x7;
               fMatch = TRUE;
               if( preload )
                  return;
               else
                  break;
            }


Basically the only problem was the placement of the preload check on passwords. Previously before the pfile format was reorganized the level of the person was stored before it read the password. Now it's stored afterward in the status line. So it ended up that even if you were the supreme of supremes, the wizlock check thought you were level 0 and refused to let you in.
       
Pages:<< prev 1 next >>