How To Get Text From Text Mesh Pro Input Field & Display When Button Is Clicked - Unity Tutorials c#

Поділитися
Вставка
  • Опубліковано 4 вер 2024

КОМЕНТАРІ • 53

  • @DamageSoftware
    @DamageSoftware Рік тому +6

    Ok for the people that just wanted to see what is the Type of the input and the property that contains the value > It is TMP_InputField and the property is inputVariable.text.
    He shows it at 16:23.

  • @iamteacher33
    @iamteacher33 5 місяців тому

    Dear thank you very very much , so are best teacher easy , understandable and apreciateable. I am going to subscribe you .

  • @dominikvachl8439
    @dominikvachl8439 3 роки тому +3

    MAN THANK YOU SOOOO MUCH...I tried like 4 tutorials and none of them seemed to work even when I did everything correctly...they just had it too complicated and the tutorials were too old.
    ily dude

  • @olofandreasson9814
    @olofandreasson9814 Рік тому

    finally a video who explains this with TMPro!! I've been looking for it for sooo long. Thank you so much Jason!

  • @perrygretton474
    @perrygretton474 2 роки тому

    This is the best tutorial on the subject I've come across, not that there are that many. Thanks, Jason.

  • @nuffagames5539
    @nuffagames5539 Рік тому

    Thanks Jason very thorough and the best video for using Input Fields with TextMeshPro

  • @3ial
    @3ial Рік тому

    THANK YOU YOU ARE THE BEST

  • @NavaNoidGMD
    @NavaNoidGMD 2 роки тому +1

    Thank you so much! I needed the linking part because Unity wasn't really trying to work so, thank you so much!

  • @robbayley866
    @robbayley866 Рік тому

    Many thanks for this. :)

  • @meesmeester288
    @meesmeester288 2 роки тому

    Finally something that helps on this topic!

  • @Jeea84
    @Jeea84 2 роки тому

    You saved me hours n hours of work!! Thank you very much!!

  • @solaimanisa3922
    @solaimanisa3922 3 роки тому +2

    It is really helpful for devoloper

  • @kastordark___
    @kastordark___ Рік тому

    thankyou luv u bro :)

  • @johnroney2191
    @johnroney2191 2 роки тому

    Thanks for saving me.

  • @mehmethankaya9974
    @mehmethankaya9974 3 роки тому +1

    Thank you. Your video has helped me a lot.

  • @loudichoson321
    @loudichoson321 Рік тому

    I know this is a bit late for you to answer but may I ask if instead of creating a new gameObject named "NameController", can i just add the script to the parent canvas of the inputfields? This is what I did and it worked.

  • @mohammadshahadah3993
    @mohammadshahadah3993 Рік тому

    THANK YOU SO MUCH!!

  • @nirajshah5411
    @nirajshah5411 3 роки тому +1

    awesome, thanks so much!!

  • @noxmetrica35
    @noxmetrica35 4 роки тому +4

    Precise and helpful, thanks a lot!

  • @talismanskulls2857
    @talismanskulls2857 2 роки тому

    how about different fonts inside the same text area?

  • @Sword_Falcon
    @Sword_Falcon 2 роки тому +1

    Thanks, though the only thing I wanted is this: TMP_InputField ;

  • @dominikvachl8439
    @dominikvachl8439 3 роки тому +1

    How can I do mathematical operatins with a number from input field?? I know that the number is string and that it can not be for example devided but I do not know how to do what I want it to do.

    • @dominikvachl8439
      @dominikvachl8439 3 роки тому +2

      I've found it out. If someone needs to know, here is the link: answers.unity.com/questions/933639/how-do-i-addmultiply-input-field-boxes.html
      The link is for multiplying 2 input fields so you have to figure out how it needs to be writen to multiply number from input field by some number.

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому

      Hi, sorry for the late reply. What you need to do is convert that string to an Integer. you can do it like this by using Int32.Parse :
      public TMP_inputfield f_num;
      public TMP_inputfield s_num;
      public void calculate()
      {
      int num2 = Int32.Parse(f_num.text);
      int num2 = int32.Parse(s_num.text);
      Add(num1, num2);
      }
      private int Add(int num1, int num2, int result)
      {
      result = num1 + num2;
      return result;
      }
      Hope this helps :D

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому

      So you can use Int32.Parse or Convert.ToInt32 the only difference is that Int32.Parse does not allow for a null value and will throw and error.
      Let me know if you need any more assistance with what you trying to achieve.

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому

      Please consider subscribing for more awesome tutorials.

  • @locusruizlopez5997
    @locusruizlopez5997 2 роки тому

    thanks!

  • @onatkorucu842
    @onatkorucu842 2 роки тому

    Good part starts at 6:25

  • @1ronbuttmonkey870
    @1ronbuttmonkey870 3 роки тому +1

    next time you should show how to save it when you exit the game so that when you get back in the name saves

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому

      Thank you, I will make a video soon on that. Please consider subscribing and look out for that video soon.

    • @1ronbuttmonkey870
      @1ronbuttmonkey870 3 роки тому

      @@theultimatedeveloper4736 i will and sorry if i seemed a little stand off'ish i have the same thing working its just not in TMP its regular text and i cant use Playerpref since TMP doesnt like that :( but yes pleasee make a video, if youd like i can show you my way of doing it if i figure it out aswell, up to you :)

  • @hyperadoi
    @hyperadoi 3 роки тому +1

    its not working by me it says: Error: The type of name "user_name" Couldnt not be found

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому +1

      Hi Nissyns, Please can you send me a screen shot off your error and I will help you solve it.

    • @hyperadoi
      @hyperadoi 3 роки тому +2

      @@theultimatedeveloper4736 i dont know how to send a screenshot but plssss can u make how u can get the InputField text to your profil secne?, so! i mean the player tipes his name in the entername secne and then he goes to the lobby and in the lobby ( up - right ) is a button where is Profi and when the player click on it, then it shows the text that he enters in the InputField???? hope that u make a tutorial for this😁

    • @hyperadoi
      @hyperadoi 3 роки тому +2

      @@theultimatedeveloper4736 so i used another video but its not working with another secne😞😞, i entered a text in the InputField and clicked on 'DONE' and the Done button brings me to the lobby and then i clicked on 'PROFIL' button and the text didnt show😞😞 plsss help me to reach my dream in my game😕😕

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому +1

      @@hyperadoi Hi, Okay I understand what you saying, I will make a video and post shortly, hope it helps.

    • @hyperadoi
      @hyperadoi 3 роки тому +2

      @@theultimatedeveloper4736 THANK YOUU!! IS SWEAR YOU'RE BETTER THEN BRACKEYS😀😀😀😀

  • @fabulusinvictus2198
    @fabulusinvictus2198 3 роки тому

    Hello, Name.... is simpler

  • @jeeva3984
    @jeeva3984 3 роки тому

    I guess the title suitable content 2 min but why so long ??? please skip unnecessary or change suitable title 😪

    • @theultimatedeveloper4736
      @theultimatedeveloper4736  3 роки тому

      Hi Jeeva, Thanks for the feedback. This tutorial is for beginners so I tried to explain almost everything that I did. Yes you right I should of mentioned it was beginners.

  • @wilsonjustinesison5113
    @wilsonjustinesison5113 Рік тому

    test