I was running in circles trying to figure out why my custom atlas font wasn't displaying... Apparently, adding the atlas texture to the Texture field in the Face panel made it invisible. Setting that to None and assigning the atlas to the Debug panel's texture slot as you showed, worked. Thanks a bunch!
this tutorial saved my life! I couldn't find out how to export the atlas anywhere. I was about to make my own atlas by screenshotting text edit; good thing I found this video.
@@CodeMonkeyUnity I managed to save the atls as png but even without chaning anything in it i just use that png, it makes all the latter just white squares.
Thanks, that's very useful! But, if I am using a font with special characters from other languages as it's mine (spanish) with accent marks for example, it seems the converter doesn't works very well and the special characters are not converted properly. Any idea of how to solve this? It will be much appreciated! EDIT: Just a few minutes after publishing this message I saw I am dumbass and I can select the codification (ASCII, Extended ASCII...) so that solves the problem if anyone else had it. Greetings and thanks again!
Yes! Thank you so much! I was wondering why TMP was not generating an atlas, I figured out after watching this video. =) I was worried when the all font in my text based game up and disappeared, some who the defaults were changed. xD
I know this is kind of an old video, but do you know how to convert a sprite sheet into a font? I wanted to go for more of an arcade look, with unique shading, and can't seem to get it into my game, and other font making sites don't support the shading I used. Like FontStruct only uses black and a transparent background
What if the font I want to use comes as a png file? The font isn't a font file like a ttf or otf, was wondering if TextMeshPro has something that'll make it easier to use fonts that come in png files
I have created a TMP font asset. But when I assign my TMP font asset to any TMP Text object. The edges of my fonts are getting distorted. I have changed the shader to all the other option but the problem still retains. And my fonts are working very fine with photoshop and Illustrator. So the problem is not with the fonts... Please help me how can I fix this issue... Thanks in Advance...
Thanks, great video. Is there a way to change the basic font of the Textmesh pro component? I made my whole game and now I want to localize it, but the font does not even have extended ascii characters. I would love to just change the font for all the components at once and set it as a new default without needing to go through all prefabs and screens manualy. Is that possible?
Hmm maybe you could replace the file in the TextMeshPro folder and replace it with another font using the exact same file name. If you do that and dont touch the .meta file it might update all the references
@@CodeMonkeyUnity I did it. If you dont change the font from default font in the component, then changing the default font in Textmesh Pro settings file changes the font for all components. Your way also works, though. I did that when I found yet another wierd character I needed and was not in my new font, replacing the font asset with a new asset named exactly the same (replacing it) does change the font for all components using that font.
폰트 적용시켜서 쓰는데 The character used for Underline is not available in font asset [SO]. UnityEngine.Debug:LogWarning (object,UnityEngine.Object) MissingReferenceException: The object of type 'Material' has been destroyed but you are still trying to access it. Your script should either check if it is null or you should not destroy the object. "WHY"
The first error, seems like you're using a font that doesn't have an underscore, fonts dont all have every single character The second one, sounds like you destroyed a Material but then you're trying to access it.
BTW you also mentioned that bitmap font looks nice only on the exact size but if you try up/down scale, it will look pixelated and not crispy... so then why you switched from good quality font to bitmap in the example?
If you're working with normal custom fonts without any special effects you should use Distance Field. However the way that works is by making the font have a alpha gradient which means it cannot be easily modified for adding effects. So for adding special image effects you need a bitmap font which means you need to know the correct size that you'll use it for since it does have those limitation. For example one of the videos coming soon is making a Hit Counter like I used in Hyper Knights which uses a bitmap font with nice effects to show the number of hits.
@@CodeMonkeyUnity Thanks for your reply.So the problem I faced before was that I needed really big numbers (font size 450-600). You cannot fit 10 digits even within 2048 atlas. So what should you do in this case? If you keep font smaller, for example 300 (the max size for default Text component) and scale it 1.5x up, it will not look sharp. p.s. I will wait for your next video as well, what I love about your channel is that you share useful tips/techniques you may need "tomorrow" in your own code.
Why do you need such big numbers? A font of that size would almost occupy the entire screen. If you're trying to really fit a text to occupy an entire 4K window then making a specific texture with the text that you need would probably be the best bet, that is a very extreme use case.
It should work but follow the process in the video where you generate the spritesheet then copy paste on top of the letters you have. It's much simpler than if you try to use the image you already have and manually assign the position for each letter.
I just did it on 2019.3.11 and it worked perfect! I just had to change padding inside the materials , seems like it doesn't recognize it from the atlas
@@twnhny1994 yes! Exported the atlas to png file, then opened into PS, edit a bit and then turn it back to unity, assigned to a material bitmap custom atlas, adjusted the padding and it worked so good!
Thank you! Couldn't figure out how to set the font. I'm wondering, though, if using a shader wouldn't be better than editing it externally to achieve the effect you did? I guess it depends what you are trying to do, so it's good to know that way exists. EDIT: Except... I think the atlas is messed up. It's all gibberish and fragmented when I use it in TMP. NM: I tried again and got it to work.
If you wanted a more custom effect (perhaps a moving gradient over time) then yup a shader would be the way to go, in my case I just wanted a simple baked effect.
I used to hate Unity so much for the way it handles text, but your tutorial completely flipped my perspective. Thank you so much! :)
When I google something on how to do and your video pops up, that makes me really happy because I know I am getting a solid answer!
Thanks! I'm glad the videos have been helpful!
Thanks a lot! i was disappointed that i can't use a custom font with TextMeshPro.. but here you are!
I was running in circles trying to figure out why my custom atlas font wasn't displaying... Apparently, adding the atlas texture to the Texture field in the Face panel made it invisible. Setting that to None and assigning the atlas to the Debug panel's texture slot as you showed, worked. Thanks a bunch!
Thanks sir, 3 years later still helping people
Yup it's awesome how these videos live forever and most of them are still valid years after release!
I always come back to this video over the years, thanks!
Nice! I hope it has helped!
this tutorial saved my life! I couldn't find out how to export the atlas anywhere. I was about to make my own atlas by screenshotting text edit; good thing I found this video.
Glad you found it helpful!
@@CodeMonkeyUnity I managed to save the atls as png but even without chaning anything in it i just use that png, it makes all the latter just white squares.
THANK U!!! THANK U!!! THANK U!!! THANK U SO MUCH!!!!!
This channel deserves more subscribers
Brilliant video and explanation! Thank you for knowledge!
This is really cool! I wasn't aware of this.
Great video, very informative and good length!
wow, new background music :) I want to switch to my own custom font, so as always you create right tutorial :D
Thank you this is exactly what i was looking for, i could not figure out how to have a font asset!
Man, you always save my life. Thanks for so much knowledge
Thank you for a video this important and this overlooked by game devs. Cheers!
Tnx CodeMonkey Guy. Keep up the good work!
Thank you so much! Very useful!
Do you have an updated TextPro vid. I'm looking to set the text in code, but I want to use the richtext tags (mainly for a tool tip) of sorts Thanks
Thanks, that's very useful! But, if I am using a font with special characters from other languages as it's mine (spanish) with accent marks for example, it seems the converter doesn't works very well and the special characters are not converted properly. Any idea of how to solve this? It will be much appreciated!
EDIT: Just a few minutes after publishing this message I saw I am dumbass and I can select the codification (ASCII, Extended ASCII...) so that solves the problem if anyone else had it. Greetings and thanks again!
Yes! Thank you so much! I was wondering why TMP was not generating an atlas, I figured out after watching this video. =)
I was worried when the all font in my text based game up and disappeared, some who the defaults were changed. xD
Same!
I know this is kind of an old video, but do you know how to convert a sprite sheet into a font? I wanted to go for more of an arcade look, with unique shading, and can't seem to get it into my game, and other font making sites don't support the shading I used. Like FontStruct only uses black and a transparent background
Thank you, very useful, love your chanell!
This was so helpful thank you so much
Is there a way to do it with a custom font that you made and not an already generated font from a website.
Jessy, yeah! Ultra-useful short lesson, thanx!
Many thanks! Just what I need ;)
+1
This helped me, thanks.
Thank u once again brotha!
is it possible to use 1 font to put slightly adjusted versions of it onto multiple objects, or do I need an entirely new font?
very extremely Thank you
THANK U that was very helpful
Can you cover a topic by creating video "Making camera don't cross through objects"?
Ty as always.
Very useful thanks!
OMG!!!! THANKS!!!!!!!!
Thanks so much! it was exactly what I needed
Thanks this really helped
Thank You so Much I was Just About to Search for it.
What if the font I want to use comes as a png file? The font isn't a font file like a ttf or otf, was wondering if TextMeshPro has something that'll make it easier to use fonts that come in png files
Thank you so much!
I'm glad you found the video useful!
thanks brow !!
Just came from the Visual Scripting Udemy Course, Im on 23rd lesson, UI.
I hope you're enjoying it!
@@CodeMonkeyUnity I am!
Great Course, just finished my first funcional level
Thanks a lot! you know how to make the text appear above the sprites??
You can play around with the Sorting Layer and Sorting Order
Okay, now it complains that asset's atlas texture is unreadable and displays the old (TMPro's own) font.
how do I import the font? and what type of file does it have to be?
I have created a TMP font asset. But when I assign my TMP font asset to any TMP Text object. The edges of my fonts are getting distorted. I have changed the shader to all the other option but the problem still retains. And my fonts are working very fine with photoshop and Illustrator. So the problem is not with the fonts... Please help me how can I fix this issue... Thanks in Advance...
This vid makes me go YES
thank you thanks a lot man
Thanks, great video. Is there a way to change the basic font of the Textmesh pro component? I made my whole game and now I want to localize it, but the font does not even have extended ascii characters. I would love to just change the font for all the components at once and set it as a new default without needing to go through all prefabs and screens manualy. Is that possible?
Hmm maybe you could replace the file in the TextMeshPro folder and replace it with another font using the exact same file name. If you do that and dont touch the .meta file it might update all the references
@@CodeMonkeyUnity I did it. If you dont change the font from default font in the component, then changing the default font in Textmesh Pro settings file changes the font for all components.
Your way also works, though. I did that when I found yet another wierd character I needed and was not in my new font, replacing the font asset with a new asset named exactly the same (replacing it) does change the font for all components using that font.
폰트 적용시켜서 쓰는데
The character used for Underline is not available in font asset [SO].
UnityEngine.Debug:LogWarning (object,UnityEngine.Object)
MissingReferenceException: The object of type 'Material' has been destroyed but you are still trying to access it.
Your script should either check if it is null or you should not destroy the object.
"WHY"
The first error, seems like you're using a font that doesn't have an underscore, fonts dont all have every single character
The second one, sounds like you destroyed a Material but then you're trying to access it.
thanks, life savior
BTW you also mentioned that bitmap font looks nice only on the exact size but if you try up/down scale, it will look pixelated and not crispy... so then why you switched from good quality font to bitmap in the example?
If you're working with normal custom fonts without any special effects you should use Distance Field. However the way that works is by making the font have a alpha gradient which means it cannot be easily modified for adding effects.
So for adding special image effects you need a bitmap font which means you need to know the correct size that you'll use it for since it does have those limitation.
For example one of the videos coming soon is making a Hit Counter like I used in Hyper Knights which uses a bitmap font with nice effects to show the number of hits.
@@CodeMonkeyUnity Thanks for your reply.So the problem I faced before was that I needed really big numbers (font size 450-600). You cannot fit 10 digits even within 2048 atlas. So what should you do in this case? If you keep font smaller, for example 300 (the max size for default Text component) and scale it 1.5x up, it will not look sharp.
p.s. I will wait for your next video as well, what I love about your channel is that you share useful tips/techniques you may need "tomorrow" in your own code.
Why do you need such big numbers? A font of that size would almost occupy the entire screen.
If you're trying to really fit a text to occupy an entire 4K window then making a specific texture with the text that you need would probably be the best bet, that is a very extreme use case.
I have a few sprite sheets with fonts on them in .PNG form. Will this work with my sprite sheet?
It should work but follow the process in the video where you generate the spritesheet then copy paste on top of the letters you have. It's much simpler than if you try to use the image you already have and manually assign the position for each letter.
@@CodeMonkeyUnity OK Thanks
thanks!
thank you very very very much
thanx a lot
Is it possible that somehow not all charcters will fit into the sheet? If so, what can I do to fix it?
You can increase the texture size or decrease the size of each character
@@CodeMonkeyUnity thanks, found it already.
THank you so much
Thank you!
hello, how do i get the texture ? It only generates .asset file with texture in it and I cannot edit it :/ I am on Mac
Can you make Tutorial on Creating Main menu, Option and pause Menu? Help pls
This doesn't seem to work at all in Unity 2019.3.12 . Almost everything looks different.
I just did it on 2019.3.11 and it worked perfect! I just had to change padding inside the materials , seems like it doesn't recognize it from the atlas
@@94Kansas Hello, did you create a custom atlas with PS?
@@twnhny1994 yes! Exported the atlas to png file, then opened into PS, edit a bit and then turn it back to unity, assigned to a material bitmap custom atlas, adjusted the padding and it worked so good!
@@94Kansas ok then I'll try edit the atlas with PS because I tried with GIMP but didn't achieve anything
how i change font weight?
Can u make a multi-player game in unity .
Thank you! Couldn't figure out how to set the font. I'm wondering, though, if using a shader wouldn't be better than editing it externally to achieve the effect you did? I guess it depends what you are trying to do, so it's good to know that way exists.
EDIT: Except... I think the atlas is messed up. It's all gibberish and fragmented when I use it in TMP.
NM: I tried again and got it to work.
If you wanted a more custom effect (perhaps a moving gradient over time) then yup a shader would be the way to go, in my case I just wanted a simple baked effect.
Thanks!!!!!!!!!
Thanks, 100th comment!!
the video starts at 2:34. You're welcome
i cant use namespace 'TMPro' in visual studio Code . anyone have suggestens ?
You need to have the TextMeshPro package installed
@@CodeMonkeyUnity i have it. Also i try uninstall and instal again but nothing.
@@tornikenijaradze3017 Were you able to solve the problem?
Did they removed textmesh pro ? Because I cant find it anywhere
xdddd
Thank you very much, i would have given up and use regular text if it wasnt for you
thanks
I'm glad you found the video useful!
i cant edit the text help
TY
Your voice reminds me of Kermit the Frog I love it
Can i show chinese text using these method
Sure, as long as the font contains those character it will export the image.
Thaaaaaaanks
2:34
Why is there a dude in your game named "SummAnus?"
I just googled "random roman names" and used what came up
i hate when you skip video fast! i need to know exactly what are you doing!
What couldn't you follow?
im using this to get comic sans
WARNING!
TextMeshPro now allows the drag and drog
I am using unity version 2020.3.1
aaaaaaaaaaaaaa my eyes white photoshop
Thanks for Help thou
thanks!
2:33