How to have 2D Editable text

How do i make it so i can show a variable as a text and allow someone to click and enter a number.

Use the built in Unity GUI. It’s pretty hard and (in my opinion) ridiculously annoying, but it gets the job done.
Also, what you could do is use NGUI, which is amazing. They have better editable text stuff, and its much more powerful.