Menus Fixes

This commit is contained in:
GamerClassN7 2021-01-31 04:34:54 +01:00
parent 342e41379c
commit a91cb8a6ac
3 changed files with 15 additions and 12 deletions

View File

@ -989,9 +989,9 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 673a21955a819d748b7b528d00a157e2, type: 3} m_Script: {fileID: 11500000, guid: 673a21955a819d748b7b528d00a157e2, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
ScoreText: {fileID: 1149440332} ScoreText: {fileID: 0}
ScoreOneLineText: {fileID: 1149440332}
name: {fileID: 1711357578} name: {fileID: 1711357578}
score: {fileID: 0}
--- !u!114 &989324638 --- !u!114 &989324638
MonoBehaviour: MonoBehaviour:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -1197,8 +1197,8 @@ MonoBehaviour:
m_fontSizeMin: 18 m_fontSizeMin: 18
m_fontSizeMax: 72 m_fontSizeMax: 72
m_fontStyle: 0 m_fontStyle: 0
m_HorizontalAlignment: 1 m_HorizontalAlignment: 2
m_VerticalAlignment: 256 m_VerticalAlignment: 512
m_textAlignment: 65535 m_textAlignment: 65535
m_characterSpacing: 0 m_characterSpacing: 0
m_wordSpacing: 0 m_wordSpacing: 0

View File

@ -914,9 +914,9 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 673a21955a819d748b7b528d00a157e2, type: 3} m_Script: {fileID: 11500000, guid: 673a21955a819d748b7b528d00a157e2, type: 3}
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
ScoreText: {fileID: 1149440332} ScoreText: {fileID: 0}
ScoreOneLineText: {fileID: 1149440332}
name: {fileID: 0} name: {fileID: 0}
score: {fileID: 0}
--- !u!114 &989324638 --- !u!114 &989324638
MonoBehaviour: MonoBehaviour:
m_ObjectHideFlags: 0 m_ObjectHideFlags: 0
@ -1044,8 +1044,8 @@ MonoBehaviour:
m_fontSizeMin: 18 m_fontSizeMin: 18
m_fontSizeMax: 72 m_fontSizeMax: 72
m_fontStyle: 0 m_fontStyle: 0
m_HorizontalAlignment: 1 m_HorizontalAlignment: 2
m_VerticalAlignment: 256 m_VerticalAlignment: 512
m_textAlignment: 65535 m_textAlignment: 65535
m_characterSpacing: 0 m_characterSpacing: 0
m_wordSpacing: 0 m_wordSpacing: 0

View File

@ -9,9 +9,10 @@ using TMPro;
public class MainMenu : MonoBehaviour public class MainMenu : MonoBehaviour
{ {
public TMPro.TextMeshProUGUI ScoreText; public TMPro.TextMeshProUGUI ScoreText = null;
public TMPro.TextMeshProUGUI ScoreOneLineText = null;
public InputField name; public InputField name;
public TMPro.TextMeshProUGUI score;
// Start is called before the first frame update // Start is called before the first frame update
void Start() void Start()
@ -21,8 +22,10 @@ public class MainMenu : MonoBehaviour
// Update is called once per frame // Update is called once per frame
void Update() void Update()
{ {
if (score != null) if (ScoreOneLineText != null){
score.text = "Score: " + DataManager.Score().ToString(); Debug.Log("Score 2 ");
ScoreOneLineText.text = "Score: " + DataManager.Score().ToString();
}
} }
public void PlayGame() public void PlayGame()