mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Re-fixed setting DIALOG game mode flag
This commit is contained in:
@@ -381,6 +381,7 @@ const DWORD gdialog_barter_cleanup_tables_ = 0x448660;
|
||||
const DWORD gdialog_barter_pressed_ = 0x44A52C;
|
||||
const DWORD gdialogActive_ = 0x444D2C;
|
||||
const DWORD gdialogDisplayMsg_ = 0x445448;
|
||||
const DWORD gdialogFreeSpeech_ = 0x4450C4;
|
||||
const DWORD gdProcess_ = 0x4465C0;
|
||||
const DWORD gdReviewExit_ = 0x445C18;
|
||||
const DWORD gdReviewInit_ = 0x445938;
|
||||
|
||||
@@ -620,6 +620,7 @@ extern const DWORD gdialog_barter_cleanup_tables_;
|
||||
extern const DWORD gdialog_barter_pressed_;
|
||||
extern const DWORD gdialogActive_;
|
||||
extern const DWORD gdialogDisplayMsg_;
|
||||
extern const DWORD gdialogFreeSpeech_;
|
||||
extern const DWORD gdProcess_;
|
||||
extern const DWORD gdReviewExit_;
|
||||
extern const DWORD gdReviewInit_;
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
long __stdcall GetInvenApCost() ;
|
||||
long __stdcall GetInvenApCost();
|
||||
void __fastcall SetInvenApCost(int cost);
|
||||
DWORD __stdcall sf_item_total_size(TGameObj* critter);
|
||||
|
||||
|
||||
@@ -475,16 +475,10 @@ static void __declspec(naked) DialogHookStart() {
|
||||
}
|
||||
}
|
||||
|
||||
static void __declspec(naked) DialogHook() {
|
||||
static void __declspec(naked) DialogHookEnd() {
|
||||
__asm {
|
||||
test inLoop, DIALOG; // check byte flag
|
||||
jz changeMode;
|
||||
jmp gdProcess_;
|
||||
changeMode:
|
||||
or inLoop, DIALOG;
|
||||
call gdProcess_;
|
||||
and inLoop, (-1 ^ DIALOG);
|
||||
retn;
|
||||
jmp gdialogFreeSpeech_;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -652,7 +646,7 @@ void LoadGameHookInit() {
|
||||
//HookCall(0x4A73EB, CharacterHook); // character creation
|
||||
//HookCall(0x4A740A, CharacterHook); // character creation
|
||||
MakeCall(0x445285, DialogHookStart); // gdialogInitFromScript_
|
||||
HookCall(0x445748, DialogHook);
|
||||
HookCall(0x4452CD, DialogHookEnd); // gdialogExitFromScript_ (old 0x445748)
|
||||
HookCall(0x443463, PipboyHook);
|
||||
HookCall(0x443605, PipboyHook);
|
||||
HookCall(0x4434AC, SkilldexHook);
|
||||
|
||||
Reference in New Issue
Block a user