Oh and by the way how would I make the script to reset the calculator input when pressing the clear button?
just make a function like Reset() and in there set all those values back to nil like Input1 = nil
then you can call updatetext at the bottom of it and it will reset the text