diff --git a/src/logic-scenes/board/card.gd b/src/logic-scenes/board/card.gd index a0e49ca..eefcb21 100644 --- a/src/logic-scenes/board/card.gd +++ b/src/logic-scenes/board/card.gd @@ -211,7 +211,6 @@ func remove_sticky_note() -> StickyNote: current_sticky_note = null former_child.reparent(get_parent()) former_child.owner = self.owner - former_child.current_handle = false former_child.on_board = true former_child.attached_to = null return former_child diff --git a/src/logic-scenes/board/sticky-note.gd b/src/logic-scenes/board/sticky-note.gd index 51505c0..f636f6d 100644 --- a/src/logic-scenes/board/sticky-note.gd +++ b/src/logic-scenes/board/sticky-note.gd @@ -12,7 +12,7 @@ var attached_to: Node = null: set(new_attatchement): attached_to = new_attatchement # cannot be explicitly typed, as this can be bnoth handled by picker and physics-board -var current_handle +var current_handle: Node signal transform_tween_finished @@ -30,7 +30,6 @@ signal transform_tween_finished set(highlight): if highlight != highlighted: highlighted = highlight - print("hightlight_set") if is_inside_tree() and is_node_ready(): if modulate_tween: modulate_tween.kill() @@ -131,12 +130,13 @@ func _on_area_enter(card: Area2D): attached_to.create_gap() func _on_area_exit(card: Area2D): - if hovering_cards.has(card): - hovering_cards.erase(card) - card.highlighted = false - if hovering_cards == []: - hover_pos_shift = 0 - $Content.position = Vector2.ZERO + if hovering_cards != []: + if card in hovering_cards: + hovering_cards.erase(card) + card.highlighted = false + if hovering_cards == []: + hover_pos_shift = 0 + $Content.position = Vector2.ZERO elif card is StickyNote and is_sticky_note_in_panel(): attached_to.collapse_gap()