game.gd cleaning and partial results screen implementation

This commit is contained in:
Haze Weathers 2023-09-10 19:28:42 -04:00
parent b126484109
commit e2b3db0b93
16 changed files with 425 additions and 436 deletions

View file

@ -38,9 +38,9 @@ func _physics_process(delta):
if not nodes.empty():
var player = nodes[0]
var mouse_position = SceneManager.viewport.get_mouse_position() / SceneManager.viewport_container.rect_scale
mouse_position.x = clamp(mouse_position.x, 8.0, Game.resolution.x - 8.0)
mouse_position.y = clamp(mouse_position.y, 8.0, Game.resolution.y - 8.0)
var world_position = mouse_position + Game.current_sector * Game.resolution
mouse_position.x = clamp(mouse_position.x, 8.0, Game.RESOLUTION.x - 8.0)
mouse_position.y = clamp(mouse_position.y, 8.0, Game.RESOLUTION.y - 8.0)
var world_position = mouse_position + Game.current_sector * Game.RESOLUTION
player.position = world_position
# Game.get_map().get_node("Player").position = get_viewport().get_mouse_position()