Fix splash text size
This commit is contained in:
@@ -3660,7 +3660,7 @@ MonoBehaviour:
|
|||||||
m_EditorClassIdentifier: Assembly-CSharp::BouncyText
|
m_EditorClassIdentifier: Assembly-CSharp::BouncyText
|
||||||
frequency: 8
|
frequency: 8
|
||||||
minSize: 0
|
minSize: 0
|
||||||
maxSize: 2
|
maxSize: -2
|
||||||
add: 1
|
add: 1
|
||||||
--- !u!1 &1314896801
|
--- !u!1 &1314896801
|
||||||
GameObject:
|
GameObject:
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ public class BouncyText : MonoBehaviour
|
|||||||
text = GetComponent<TextMeshProUGUI>();
|
text = GetComponent<TextMeshProUGUI>();
|
||||||
if (add)
|
if (add)
|
||||||
{
|
{
|
||||||
|
text.ForceMeshUpdate();
|
||||||
startSize = text.fontSize;
|
startSize = text.fontSize;
|
||||||
text.enableAutoSizing = false;
|
text.enableAutoSizing = false;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user