Cade
The Rainman, (Administrator)
- Joined
- Feb 28, 2005
- RedCents
- 1,041¢
I've seen how to do a noauth compile in one place and how to remove the plugin date/time check in another and what to remove to get warp to work somewhere else. Haven't seen how to put string back in but I imagine it's here somewhere, but I know how. So to save people the time of searching around, here's how to do what I just listed.
[size=+1]Noauth compile:[/size]
With a hex editor (I recomend hex workshop) open MQ2Auth.exe before you run it and replace (Ctrl+H usually, if that doesn't work go to Edit -> Replace. If you don't have that option you will have to go to find and do it manually)
with
After that's done, run MQ2Auth.exe [size=+3]and do the same thing to MacroQuest2.exe in the release folder.[/size]
[size=+1]Removing the date/time check:[/size]
Remove these bits of code from PluginHandler.cpp:
Alternate:
[size=+1]Removing anti-warp code:[/size]
EDIT: This section once contained instructions for removing antiwarp and antizone code, due to recent changes it only contains information for removing antiwarp code, so any combination warp/zone plugins will only warp.
In EQData.h replace
with
AND in MQ2Main.h:
Replace the 0 in this line:
with the warp offset (0x043D7C5 as of 11/1)
AND in MQ2Commandapi.cpp remove:
AND in PluginHandler.cpp remove:
[size=+1]Putting string back in:[/size]
In MQ2Data.cpp change
to
[size=+1]Compiling Plugins With VS6[/size]
Download the latest zip and save it to your desktop, name it MQLatest.
Follow my instructions on making a noauth compile.
I'm going to use MQ2Twist as my example
First, open a command prompt (Start -> Run -> Type: cmd)
Navigate to your MQ2 source folder withing the command prompt by typing:
Now type
This will create a folder within the MQLatest folder named MQ2Twist.
Open that folder then open MQ2Twist.cpp (NOT ISXEQTwist.cpp or ISXEQTwist.h) and replace everything in it with the plugin source. Save and close.
Now go back to the main MQLatest folder and double click macroquest2.dsw.
Once that's open, go to Project -> Insert Project Into Workspace. In the window that pops up, open the MQ2Twist folder and double click MQ2Twist.dsp.
Now go to Build -> Set Active Configuration and double click
Now go to Build -> Batch Build and make sure everything is checked. Click Build and it should start compiling.
[size=+1]Compiling Plugins With VS.NET[/size]
Download the latest zip and save it to your desktop, name it MQLatest.
Follow my instructions on making a noauth compile.
I'm going to use MQ2Twist as my example
First, open a command prompt (Start -> Run -> Type: cmd)
Navigate to your MQ2 source folder withing the command prompt by typing:
Now type
This will create a folder within the MQLatest folder named MQ2Twist.
Open that folder then open MQ2Twist.cpp (NOT ISXEQTwist.cpp or ISXEQTwist.h) and replace everything in it with the plugin source. Save and close.
Now go back to the main MQLatest folder and double click macroquest2.sln
Go to File -> Add Project -> Add Existing Project.
In the window that pops up, open the MQ2Twist folder and double click MQ2Twist.vcproj.
Go to the Build menu and select Configuration Manager. Select Release, and place a check in each dll you want compiled. Click the Close button.
Go to Build -> Batch Build. Click Select All then click Build. It should start compiling.Alternate:
[size=+1]Noauth compile:[/size]
With a hex editor (I recomend hex workshop) open MQ2Auth.exe before you run it and replace (Ctrl+H usually, if that doesn't work go to Edit -> Replace. If you don't have that option you will have to go to find and do it manually)
Rich (BB code):
microsoft\
Rich (BB code):
microsoap\
[size=+1]Removing the date/time check:[/size]
Remove these bits of code from PluginHandler.cpp:
Rich (BB code):
DWORD checkme(char *module)
{
char *p;
PIMAGE_DOS_HEADER pd = (PIMAGE_DOS_HEADER)module;
PIMAGE_FILE_HEADER pf;
p = module + pd->e_lfanew;
p += 4; //skip sig
pf = (PIMAGE_FILE_HEADER) p;
return pf->TimeDateStamp;
}
static unsigned int mq2mainstamp = 0;
Rich (BB code):
if (!mq2mainstamp) {
mq2mainstamp = checkme((char*)GetModuleHandle("mq2main.dll"));
}
Rich (BB code):
return 0;
}
if (mq2mainstamp > checkme((char*)hmod)) {
DebugSpew("Please recompile %s %d %d", FullFilename, mq2mainstamp, checkme((char*)hmod));
FreeLibrary(hmod);
Alternate:
So what I do is when I make the main compile I set my system date/time back to the year 2004, do the compile, then set it back to the current date. So when I make Plunins, at a later date, that I want to send to my friends they have been loading and working fine.
[size=+1]Removing anti-warp code:[/size]
EDIT: This section once contained instructions for removing antiwarp and antizone code, due to recent changes it only contains information for removing antiwarp code, so any combination warp/zone plugins will only warp.
In EQData.h replace
Rich (BB code):
/*0x24c*/ FLOAT Unknown0x24c[0x3];
Rich (BB code):
/*0x24c*/ FLOAT SafeYLoc;
/*0x250*/ FLOAT SafeXLoc;
/*0x254*/ FLOAT SafeZLoc;
AND in MQ2Main.h:
Replace the 0 in this line:
Rich (BB code):
#define CDisplay__MoveLocalPlayerToSafeCoords 0
AND in MQ2Commandapi.cpp remove:
Rich (BB code):
if (!stricmp(Command,"/warp"))
{
Function=0;
}
AND in PluginHandler.cpp remove:
Rich (BB code):
if (!stricmp(Filename,"mq2warp")) // ^_^
{
return 0;
}
[size=+1]Putting string back in:[/size]
In MQ2Data.cpp change
Rich (BB code):
TLO(dataString)
{
WriteChatf("Due to complete misuse of the String Top-Level Object, it has been removed.");
return false;
/*
if (!ISINDEX())
return false;
strcpy(DataTypeTemp,szIndex);
Ret.Ptr=&DataTypeTemp[0];
Ret.Type=pStringType;
return true;
/**/
}
Rich (BB code):
TLO(dataString)
{
if (!ISINDEX())
return false;
strcpy(DataTypeTemp,szIndex);
Ret.Ptr=&DataTypeTemp[0];
Ret.Type=pStringType;
return true;
}
[size=+1]Compiling Plugins With VS6[/size]
Download the latest zip and save it to your desktop, name it MQLatest.
Follow my instructions on making a noauth compile.
I'm going to use MQ2Twist as my example
First, open a command prompt (Start -> Run -> Type: cmd)
Navigate to your MQ2 source folder withing the command prompt by typing:
Rich (BB code):
cd desktop\MQLatest
Now type
Rich (BB code):
mkplugin twist
Open that folder then open MQ2Twist.cpp (NOT ISXEQTwist.cpp or ISXEQTwist.h) and replace everything in it with the plugin source. Save and close.
Now go back to the main MQLatest folder and double click macroquest2.dsw.
Once that's open, go to Project -> Insert Project Into Workspace. In the window that pops up, open the MQ2Twist folder and double click MQ2Twist.dsp.
Now go to Build -> Set Active Configuration and double click
Rich (BB code):
MQ2Main - Win32 Release
Now go to Build -> Batch Build and make sure everything is checked. Click Build and it should start compiling.
[size=+1]Compiling Plugins With VS.NET[/size]
Download the latest zip and save it to your desktop, name it MQLatest.
Follow my instructions on making a noauth compile.
I'm going to use MQ2Twist as my example
First, open a command prompt (Start -> Run -> Type: cmd)
Navigate to your MQ2 source folder withing the command prompt by typing:
Rich (BB code):
cd desktop\MQLatest
Now type
Rich (BB code):
mkplugin twist
Open that folder then open MQ2Twist.cpp (NOT ISXEQTwist.cpp or ISXEQTwist.h) and replace everything in it with the plugin source. Save and close.
Now go back to the main MQLatest folder and double click macroquest2.sln
Go to File -> Add Project -> Add Existing Project.
In the window that pops up, open the MQ2Twist folder and double click MQ2Twist.vcproj.
Go to the Build menu and select Configuration Manager. Select Release, and place a check in each dll you want compiled. Click the Close button.
Go to Build -> Batch Build. Click Select All then click Build. It should start compiling.Alternate:
Last edited:


All the fixes in one loc 

changes were made to mq2, I'll get it some day...