Make research tree vertically scrollable
This commit is contained in:
parent
06081c41b0
commit
13492a52e2
6 changed files with 70 additions and 13 deletions
|
|
@ -282,6 +282,8 @@ func _unhandled_input(event: InputEvent) -> void:
|
|||
if skill_menu.visible:
|
||||
if event is InputEventScreenTouch:
|
||||
skill_tree.handle_touch(event)
|
||||
elif event is InputEventScreenDrag:
|
||||
skill_tree.handle_drag(event)
|
||||
# Handled either way. A touch that lands on the panel but misses a
|
||||
# node is still a touch ON THE PANEL - letting it through moved the
|
||||
# fleet and pinch-zoomed the world behind the menu, because
|
||||
|
|
@ -409,6 +411,7 @@ func _on_action_pressed() -> void:
|
|||
|
||||
if current_building.building_type == GameState.BUILDING_MOTHERSHIP:
|
||||
skill_menu.visible = true
|
||||
skill_tree.reset_scroll()
|
||||
_refresh_skill_menu()
|
||||
elif current_building.building_type == GameState.BUILDING_SHIP_CRAFTER:
|
||||
# Remembered explicitly: _process() clears current_building while any
|
||||
|
|
|
|||
Loading…
Reference in a new issue