trevius
06-26-2008, 06:58 AM
Well, while I was adding in some new code posted in the code submission section by other people, I decided to investigate what it would take to change the order than the version checks get checked in so that it always checks for Titanium first. Currently, it checks for 6.2, then Titanium, the Aniversary, then Live and cycles through that continuously until it finds a match. It does this every time a person connects or zones and maybe in other cases as well. I searched for a while and finally located where that is set and it is in the /common/patches/patches.cpp file. At first I was just going to change the order, but after I did, I thought I would try just to see what happened if I commented the other versions out. Compiled the source and started the servers and it worked! I haven't seen a single error or issue so far that is related to removing the other version checks.
Here is what needs to be changes in /common/patches/patches.cpp:
Change this:
#include "../debug.h"
#include "patches.h"
#include "Client62.h"
#include "Titanium.h"
#include "Anniversary.h"
#include "Live.h"
void RegisterAllPatches(EQStreamIdentifier &into) {
Client62::Register(into);
Titanium::Register(into);
Anniversary::Register(into);
Live::Register(into);
}
void ReloadAllPatches() {
Client62::Reload();
Titanium::Reload();
Anniversary::Reload();
Live::Reload();
}
To this:
#include "../debug.h"
#include "patches.h"
#include "Titanium.h"
//#include "Client62.h"
//#include "Anniversary.h"
//#include "Live.h"
void RegisterAllPatches(EQStreamIdentifier &into) {
Titanium::Register(into);
// Client62::Register(into);
// Anniversary::Register(into);
// Live::Register(into);
}
void ReloadAllPatches() {
Titanium::Reload();
// Client62::Reload();
// Anniversary::Reload();
// Live::Reload();
}
Very simple fix to something that has bugged me for a while now. It probably doesn't make a huge difference, but I imagine it will reduce the size of the log files, since I have seen it cycle through all of those enough to cause MBs of log entries. I was also thinking that it could possible make a very slight improvement in client connections, since the checks will be done faster. And, maybe even a very slight improvement in server performance, since there are less things to be checked, which might make an impact on a server with a ton of players on it. Though, most likely, this change won't make much if any noticeable change overall. I just didn't like that it was checking for versions that aren't even supported anymore/yet. This can always be changed back at anytime very quickly and easily.
I didn't post this in the code submission forum because I doubt this is something the team would want to put in the source (or the would have changed it themselves long ago). But, I know a few people have asked about this and would probably appreciate the fix for it.
I will keep an eye out for any issues that might be related to this change, but I don't suspect any. I will also watch for any performance increases (doubtful) and post here if I see any.
Here is what needs to be changes in /common/patches/patches.cpp:
Change this:
#include "../debug.h"
#include "patches.h"
#include "Client62.h"
#include "Titanium.h"
#include "Anniversary.h"
#include "Live.h"
void RegisterAllPatches(EQStreamIdentifier &into) {
Client62::Register(into);
Titanium::Register(into);
Anniversary::Register(into);
Live::Register(into);
}
void ReloadAllPatches() {
Client62::Reload();
Titanium::Reload();
Anniversary::Reload();
Live::Reload();
}
To this:
#include "../debug.h"
#include "patches.h"
#include "Titanium.h"
//#include "Client62.h"
//#include "Anniversary.h"
//#include "Live.h"
void RegisterAllPatches(EQStreamIdentifier &into) {
Titanium::Register(into);
// Client62::Register(into);
// Anniversary::Register(into);
// Live::Register(into);
}
void ReloadAllPatches() {
Titanium::Reload();
// Client62::Reload();
// Anniversary::Reload();
// Live::Reload();
}
Very simple fix to something that has bugged me for a while now. It probably doesn't make a huge difference, but I imagine it will reduce the size of the log files, since I have seen it cycle through all of those enough to cause MBs of log entries. I was also thinking that it could possible make a very slight improvement in client connections, since the checks will be done faster. And, maybe even a very slight improvement in server performance, since there are less things to be checked, which might make an impact on a server with a ton of players on it. Though, most likely, this change won't make much if any noticeable change overall. I just didn't like that it was checking for versions that aren't even supported anymore/yet. This can always be changed back at anytime very quickly and easily.
I didn't post this in the code submission forum because I doubt this is something the team would want to put in the source (or the would have changed it themselves long ago). But, I know a few people have asked about this and would probably appreciate the fix for it.
I will keep an eye out for any issues that might be related to this change, but I don't suspect any. I will also watch for any performance increases (doubtful) and post here if I see any.