Limit a max number of characters in the character name

Posted: 25 Jan 2024 13:24
by Pititia12

Hello, it's my first time here, I looked for a question similar to mine on the forum and couldn't find it.

I would like to use the comand @imput to let the player chose the Main Character's name, but I would like to limit a max number of caracteres.

I wouldn't like the player to choose a name like "Hubert Blaine Wolfeschlegelsteinhausenbergerdorff Sr." for MC, for UI reasons, so I would like to limit it to between 10 and 12 characters maximum. How could I do this?

Thank you very much <3


Re: Limit a max number of characters in the character name

Posted: 25 Jan 2024 14:06
by Elringus

Hey, Make a custom variable input UI (https://naninovel.com/guide/user-interf ... uilt-in-ui) and use Character Limit property on the input field component: https://docs.unity3d.com/Packages/com.u ... Field.html


Re: Limit a max number of characters in the character name

Posted: 25 Jan 2024 14:24
by Pititia12

I got it here, thank you! ^^