added a keyboard panel and a toggle button

This commit is contained in:
2026-06-10 04:39:23 -05:00
parent 625f1eb1f9
commit 6c38b05832
20 changed files with 826 additions and 0 deletions

View File

@@ -0,0 +1,37 @@
extends Node3D
signal isFinished(text) ## enter button
var text = ""
var isShift = false
func typeText(char:Variant):
if char == "<=":
if text.length() != 0:
text = text.substr(0, text.length()-1)
elif char == "Shift":
return
elif isShift:
text += char.to_upper()
else:
text += char
func _process(delta: float) -> void:
$Label3D.text = text
func _on_shift_button_pressed(char: Variant) -> void:
isShift = true
func _on_shift_button_released() -> void:
isShift = false
func _on_return_button_pressed(char: Variant) -> void:
isFinished.emit(text)