aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Gone2Daly <71726742+Gone2Daly@users.noreply.github.com>2023-04-09 21:53:44 +0200
committer Gone2Daly <71726742+Gone2Daly@users.noreply.github.com>2023-04-09 21:53:44 +0200
commitf1995b5ab16366eb0c005c0cafdfd797b6cfd1d2 (patch)
treef2c4b3cbbcec53acfb80a1a695c6bef4eb703cb2
parent9c74c5d67569c7ca6c08a2f0ef5a27272332f31d (diff)
Minimap hover fix
Added check for hovering over provinces when mouse on minimap
-rw-r--r--game/src/GameSession/MapView.gd3
1 files changed, 2 insertions, 1 deletions
diff --git a/game/src/GameSession/MapView.gd b/game/src/GameSession/MapView.gd
index 0d85706..05da6d5 100644
--- a/game/src/GameSession/MapView.gd
+++ b/game/src/GameSession/MapView.gd
@@ -232,7 +232,8 @@ func _update_minimap_viewport() -> void:
func _update_mouse_map_position() -> void:
_mouse_pos_map = _viewport_to_map_coords(_mouse_pos_viewport)
- _map_shader_material.set_shader_parameter(_shader_param_hover_pos, _mouse_pos_map)
+ if not _lock_movement:
+ _map_shader_material.set_shader_parameter(_shader_param_hover_pos, _mouse_pos_map)
func _on_map_control_panel_mouse_entered():
_lock_movement = true