Reverse engineering Diablo v1.09b (last patch)
#25
[Image: Diablo_Game_20180216_121609.jpg]

I was messing around with the pre-release demo and found some leftover debug/cheat code. Interesting stuff, since some of it appeared in Mock-up shots from 1995-1996. I sent this info to Mystery over at Diablo-Evolution so hopefully it can be more documented. Below is the info to recreate it yourself. I wonder how much of this could still remain in the final game, but not activated?

Hex edits to Diablo.exe, each value is a 32-bit BOOL (1 for TRUE 0 for FALSE)
Code:
0xBA958 Debug mode on/off
0xBA95C 1.0 or Pre-release
0xBA960 Show intro videos
0xBA964 Music enabled
0xBA968 Cheats on/off
0xBA96C Display framerate
0xBA970 Display yellow tile grid
0xBA974 Unknown
0xBA978 Sets lowest possible light radius
0xBA97C Unknown
0xBA980 Unknown
0xBA984 Start game paused
0xBA988 Enable all songs or just title screen
0xBA98C Unknown
Debug controls (controls prefixed with cheat only work with cheats enabled). Debug information is display in the message box between the orbs:
Code:
[CHEAT] 'P': You can hold 'P' while paused to keep moving and be invincible
[CHEAT] '*': Levels up the character one time
[CHEAT] 'M': Displays whether or not you are invincible
[CHEAT] 'T': Displays character X/Y coordinates
[CHEAT] 'L': Toggles full radius on/off
[DEBUG] 'D': Displays transparency value
[DEBUG] 'E': Displays EFlag
[DEBUG] 'R': Displays map seed
[DEBUG] 'V': Displays game version (Either V1.0 or PRE-RELEASE)

Also, here's what I have so far for the PlayerStruct (info taken from PS1 debug version). It's not fully finished yet, 0x54D8 bytes in size.
Code:
struct PlayerStruct
{
  int _pmode;
  char walkpath[24];
  int plractive;
  int destAction;
  int destParam1;
  int destParam2;
  int destParam3;
  int destParam4;
  int plrlevel;
  int WorldX;
  int WorldY;
  int _px;
  int _py;
  int field_48;
  int field_4C;
  int field_50;
  int field_54;
  int field_58;
  int field_5C;
  int field_60;
  int field_64;
  int field_68;
  int field_6C;
  int _pdir;
  int field_74;
  int field_78;
  int field_7C;
  int field_80;
  int field_84;
  int field_88;
  int field_8C;
  int field_90;
  int field_94;
  int field_98;
  int field_9C;
  int field_A0;
  int field_A4;
  int field_A8;
  int field_AC;
  int field_B0;
  int field_B4;
  int field_B8;
  int field_BC;
  __int16 field_C0;
  char _pSplLvl[36];
  char field_E6[34];
  int field_108;
  int field_10C;
  int _pMemSpells;
  int _pAblSpells;
  int field_118;
  int field_11C;
  int field_120;
  int _pSplHotKey[4];
  char _pSplTHotKey[4];
  int _pwtype;
  char _pBlockFlag;
  char _pInvincible;
  char _pLightRad;
  char _pLvlChanging;
  char _pName[32];
  int _pClass;
  int _pStrength;
  int _pBaseStr;
  int _pMagic;
  int _pBaseMag;
  int _pDexterity;
  int _pBaseDex;
  int _pVitality;
  int _pBaseVit;
  int _pStatPts;
  int _pDamageMod;
  int _pBaseToBlk;
  int _pHPBase;
  int _pMaxHPBase;
  int _pHitPoints;
  int _pMaxHP;
  int _pHPPer;
  int _pManaBase;
  int _pMaxManaBase;
  int _pMana;
  int _pMaxMana;
  int _pManaPer;
  char _pLevel;
  char _pMaxLvl;
  __int16 field_1BA;
  int _pExperience;
  int _pMaxExp;
  int _pNextExper;
  char field_1C8;
  char _pMagResist;
  char _pFireResist;
  char _pLghtResist;
  int _pGold;
  int field_1D0;
  int _pVar1;
  int _pVar2;
  int _pVar3;
  int _pVar4;
  int _pVar5;
  int _pVar6;
  int _pVar7;
  int _pVar8;
  char _pLvlVisited[17];
  char _pSLvlVisited[10];
  char align_20F;
  int field_210;
  int field_214;
  int field_218;
  int _peqN[8];
  int _pNFrames;
  int _pNFNum;
  int _peqW[8];
  int _pWFrames;
  int _pWFNum;
  int _peqA[8];
  int _pAFrames;
  int _pAFNum;
  int frame_9_unk;
  int _peqS2[8];
  int _peqS1[8];
  int _peqS3[8];
  int _pSFrames;
  int _pSFNum;
  int frame_A_unk;
  int _peqH[8];
  int _pHFrames;
  int _pHFNum;
  int _peqD[8];
  int _pDFrames;
  int _pDFNum;
  int _peqB[8];
  int _pBFrames;
  int _pBFNum;
  ItemStruct InvBody[7];
  ItemStruct InvList[40];
  int _pNumInv;
  char InvGrid[40];
  ItemStruct SpdList[8];
  ItemStruct HoldItem;
  int _pIMinDam;
  int _pIMaxDam;
  int _pIAC;
  int _pIBonusDam;
  int _pIBonusToHit;
  int _pIBonusAC;
  int _pIBonusDamMod;
  int field_5444;
  int field_5448;
  int field_544C;
  int field_5450;
  int field_5454;
  int _pISplLvlAdd;
  int field_545C;
  int field_5460;
  int _pIFMinDam;
  int _pIFMaxDam;
  int _pILMinDam;
  int _pILMaxDam;
  int _pOilType;
  char pTownWarps;
  char pDungMsgs;
  char pLvlLoad;
  char field_547B;
  int field_547C;
  int field_5480;
  char field_5348[84];
};
Reply


Messages In This Thread
RE: Reverse engineering Diablo v1.09b (last patch) - by GalaXyHaXz - 02-16-2018, 12:40 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)