mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Fix crash when calling partyMemberGetCurLevel_ on a critter that has no data in party.txt.
Updated version number.
This commit is contained in:
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
;sfall configuration settings
|
;sfall configuration settings
|
||||||
;v4.0
|
;v4.0.1
|
||||||
|
|
||||||
[Main]
|
[Main]
|
||||||
;Change to 1 if you want to use command line args to tell sfall to use another ini file.
|
;Change to 1 if you want to use command line args to tell sfall to use another ini file.
|
||||||
|
|||||||
@@ -1079,6 +1079,15 @@ end:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void __declspec(naked) partyMemberGetCurLevel_hack() {
|
||||||
|
__asm {
|
||||||
|
mov esi, 0xFFFFFFFF; // initialize party member index
|
||||||
|
mov edi, dword ptr ds:[FO_VAR_partyMemberMaxCount];
|
||||||
|
push 0x495FFC;
|
||||||
|
retn;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void BugFixes::init()
|
void BugFixes::init()
|
||||||
{
|
{
|
||||||
@@ -1377,6 +1386,9 @@ void BugFixes::init()
|
|||||||
HookCall(0x423A99, &compute_attack_hook);
|
HookCall(0x423A99, &compute_attack_hook);
|
||||||
dlogr(" Done", DL_INIT);
|
dlogr(" Done", DL_INIT);
|
||||||
//}
|
//}
|
||||||
|
|
||||||
|
// Fix crash when calling partyMemberGetCurLevel_ on a critter that has no data in party.txt
|
||||||
|
MakeJump(0x495FF6, partyMemberGetCurLevel_hack);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-3
@@ -24,13 +24,13 @@
|
|||||||
|
|
||||||
#define VERSION_MAJOR 4
|
#define VERSION_MAJOR 4
|
||||||
#define VERSION_MINOR 0
|
#define VERSION_MINOR 0
|
||||||
#define VERSION_BUILD 0
|
#define VERSION_BUILD 1
|
||||||
#define VERSION_REV 0
|
#define VERSION_REV 0
|
||||||
|
|
||||||
#ifdef WIN2K
|
#ifdef WIN2K
|
||||||
#define VERSION_STRING "4.0 win2k"
|
#define VERSION_STRING "4.0.1 win2k"
|
||||||
#else
|
#else
|
||||||
#define VERSION_STRING "4.0"
|
#define VERSION_STRING "4.0.1"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define CHECK_VAL (4)
|
#define CHECK_VAL (4)
|
||||||
|
|||||||
Reference in New Issue
Block a user