Added buch of stuff
This commit is contained in:
@@ -9,10 +9,10 @@ func _on_input_event(camera: Node, event: InputEvent, event_position: Vector3, n
|
||||
if event is InputEventMouseButton and event.is_pressed():
|
||||
var button_event = event as InputEventMouseButton
|
||||
if button_event.button_index == MOUSE_BUTTON_LEFT:
|
||||
$indicator.visible = true
|
||||
$ProgrammingUI.visible = true
|
||||
selected = true
|
||||
elif button_event.button_index == MOUSE_BUTTON_RIGHT:
|
||||
$indicator.visible = false
|
||||
$ProgrammingUI.visible = false
|
||||
selected = false
|
||||
|
||||
func _unhandled_input(event: InputEvent) -> void:
|
||||
@@ -34,7 +34,8 @@ func move_to_mouse_click():
|
||||
path_finder.set_terrain(terrain)
|
||||
path_finder.set_region(AABB(Vector3.ONE * -100, Vector3.ONE * 200))
|
||||
path = path_finder.find_path(Vector3i(global_position), res.previous_position)
|
||||
path.append(res.previous_position)
|
||||
if not path.is_empty():
|
||||
path.append(res.previous_position)
|
||||
for step in path:
|
||||
print(step)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user