mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Fixed AP cost display on game load when using CALCAPCOST hook
(ref. fallout2-ce/fallout2-ce#376)
This commit is contained in:
@@ -139,6 +139,7 @@ WRAP_WATCOM_FUNC2(long, intface_get_attack, DWORD*, hitMode, DWORD*, isSecondary
|
||||
WRAP_WATCOM_FUNC0(long, intface_is_item_right_hand)
|
||||
WRAP_WATCOM_FUNC0(long, intface_is_hidden)
|
||||
WRAP_WATCOM_FUNC0(void, intface_redraw) // Redraws the main game interface windows (useful after changing some data like active hand, etc.)
|
||||
WRAP_WATCOM_FUNC0(void, intface_redraw_items) // Redraws only the active item button and ammo bar
|
||||
WRAP_WATCOM_FUNC0(void, intface_toggle_item_state)
|
||||
WRAP_WATCOM_FUNC1(void, intface_update_ac, long, animate)
|
||||
WRAP_WATCOM_FUNC2(void, intface_update_move_points, long, ap, long, freeAP)
|
||||
|
||||
@@ -524,6 +524,8 @@ static void InitGlobalScripts() {
|
||||
|
||||
HookScripts::InitHookScripts();
|
||||
LoadGlobalScriptsList();
|
||||
// Display the correct AP cost from the HOOK_CALCAPCOST hook for the current active item
|
||||
fo::func::intface_redraw_items();
|
||||
// Fix map lighting from Night Vision perk when loading a saved game
|
||||
fo::func::light_set_ambient(fo::var::ambient_light, 1); // refresh map lighting
|
||||
|
||||
|
||||
Reference in New Issue
Block a user