[FIX] Locked Status

Old bugs stored here for reference.
Locked
User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

[FIX] Locked Status

Post by John Adams » Sun Jun 01, 2008 8:05 am

Edit: Clarifying
In the `variables` table is an override called "minlockedstatus", which by default is set to 100. If you set Locked=true in your LoginServer.ini, players cannot enter your Locked server unless their status is at least "minlockedstatus".
I noticed while running a locked Dev server that new characters created with a status of 0 were (of course) not being allowed into the locked server. So, to give the appearance I was LOCKED, but still allow me to create new toons, I set my minlockedstatus to 0, so new chars could get in.
A bug found in the "status > 0" check prevented me from overriding this status. Here's a simple fix to get locked status to allow admin_status=0 through.

Code: Select all

Index: LoginServer.cpp
===================================================================
--- LoginServer.cpp	(revision 99)
+++ LoginServer.cpp	(working copy)
@@ -294,7 +294,7 @@
 	if( var != NULL )
 	{
 		int status = atoi ( var->GetValue ( ) );
-		if(status > 0)
+		if(status >= 0)
 			minLockedStatus = status;
 	}

You may not have intended for status=0 players into a locked server, but I think this is a good option to show a server as LOCKED but still allow new characters to be created. For me, my Dev server is locked - but if you make a char there, expect it to be deleted, etc...
Setting minlockedstatus > 0 in the variables table will prevent new chars from entering that server until the admin bumps their characters.admin_status field to match.
Edit: Sorry I just woke up and wasn't super clear what the bug was in the first place.
Last edited by John Adams on Sun Jun 01, 2008 8:46 am, edited 1 time in total.

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Sun Jun 01, 2008 8:26 am

That is the way it was intended to work (admin level has to be > 0 to join a locked server). Maybe I'll add a variable that will allow people to specify the minimum status to override the lock. That way they can just update their variables table in the DB to change it.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Sun Jun 01, 2008 8:29 am

Sorry LE. You do have an override. That's what this fix is to address. I set my "minlockedstatus" to 0, and because of the status > 0 check, I could not get in as a new player.
I assumed it was a bug, because if I set minlockedstatus=0, I should be able to get in anyway. :)

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Sun Jun 01, 2008 8:34 am

Ah nevermind then, guess I should read your post more careful next time. :P I'll make the change. That is one of the things left over from EQEmu that I completely forgot about.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Sun Jun 01, 2008 8:48 am

Naw you probably read it fine. My bad for being sleepy and not writing it up properly. heh.
Thanks for the fix. Hopefully I can help out a little more here and there.

Locked

Who is online

Users browsing this forum: No registered users and 0 guests