I have looked over the selecting a label and typing tutorials however now i am trying to combine them. Im not sure exactly how to do this but im guessing its something as simple as where the code goes.
This is the code ive currently made:
if action_id == hash("touch") and action.pressed then
local button = gui.get_node("new_highScore")
local text = gui.get_node("new_highScore_label")
if gui.pick_node(button, action.x, action.y) then
print("ih")
if action_id == hash("type") then
self.message = self.message .. action.text
gui.set_text(gui.get_node("new_highScore_label"), self.message)
elseif action_id == hash("backspace") and action.repeated then
local l = string.len(self.message)
self.message = string.sub(self.message, 0, l-1)
gui.set_text(gui.get_node("new_highScore_label"), self.message)
end
end