mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Changed the game mode check in gl_highlighting
* now opening other interfaces (inventory, options, etc.) will also turn off highlight.
This commit is contained in:
Binary file not shown.
@@ -104,7 +104,7 @@ procedure KeyPressHandler begin
|
||||
scanCode := get_sfall_arg,
|
||||
scanner, charges;
|
||||
|
||||
if scanCode == highlightKey and not(get_game_mode bwand (INTFACELOOT bwor BARTER)) then begin
|
||||
if scanCode == highlightKey and not(get_game_mode bwand bwnot(COMBAT bwor PCOMBAT)) then begin
|
||||
if pressed then begin
|
||||
set_global_script_repeat(REPEAT_FRAMES);
|
||||
if motionScanner then begin
|
||||
@@ -134,14 +134,16 @@ procedure KeyPressHandler begin
|
||||
end
|
||||
end
|
||||
|
||||
// visual glitch fix, turn off highlight when entering combat
|
||||
procedure CombatTurnHandler begin
|
||||
if isHighlight then begin
|
||||
call ToggleHighlight(false);
|
||||
end
|
||||
end
|
||||
|
||||
// visual glitch fix, turn off highlight when opening other interfaces
|
||||
procedure GameModeChangeHandler begin
|
||||
if isHighlight and (get_game_mode bwand (INTFACELOOT bwor BARTER)) then begin
|
||||
if isHighlight and (get_game_mode bwand bwnot(COMBAT bwor PCOMBAT)) then begin
|
||||
call ToggleHighlight(false);
|
||||
end
|
||||
end
|
||||
@@ -175,7 +177,7 @@ procedure start begin
|
||||
register_hook_proc(HOOK_INVENTORYMOVE, InventoryMoveHandler);
|
||||
set_global_script_type(1);
|
||||
end else begin
|
||||
if isHighlight and not(get_game_mode bwand (INTFACELOOT bwor BARTER)) then begin
|
||||
if isHighlight and not(get_game_mode bwand bwnot(COMBAT bwor PCOMBAT)) then begin
|
||||
call ToggleHighlight(true);
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user