mirror of
https://github.com/litruv/PNGTuber-Plus.git
synced 2026-07-24 18:46:01 +10:00
InitCommit
update 1.4.2 source code
This commit is contained in:
24
ui_scenes/mouse/mouse_cursor.gd
Normal file
24
ui_scenes/mouse/mouse_cursor.gd
Normal file
@@ -0,0 +1,24 @@
|
||||
extends Node2D
|
||||
|
||||
var text = ""
|
||||
|
||||
@onready var label = $Tooltip/Label
|
||||
@onready var area = $Area2D
|
||||
|
||||
func _ready():
|
||||
Global.mouse = self
|
||||
|
||||
func _process(delta):
|
||||
if Global.main.editMode:
|
||||
if text != "":
|
||||
label.text = text
|
||||
visible = true
|
||||
else:
|
||||
visible = false
|
||||
global_position = get_global_mouse_position()
|
||||
if Input.is_action_just_pressed("mouse_left"):
|
||||
Global.select(area.get_overlapping_areas())
|
||||
else:
|
||||
visible = false
|
||||
|
||||
text = ""
|
||||
Reference in New Issue
Block a user