Добавил перемещение текста счёта
This commit is contained in:
@ -27,7 +27,7 @@ public class ScoreManagerScript : MonoBehaviour
|
||||
|
||||
private void Start()
|
||||
{
|
||||
UppdateScore(_ScoreText);
|
||||
|
||||
}
|
||||
|
||||
public void Increase()
|
||||
@ -41,8 +41,9 @@ public class ScoreManagerScript : MonoBehaviour
|
||||
text.text = $"Счёт - {_CurrentScore}";
|
||||
}
|
||||
|
||||
public void UpdatePos(GameObject tile)
|
||||
public void UpdatePos()
|
||||
{
|
||||
_ScoreText.gameObject.transform.position = tile.transform.position;
|
||||
Vector3 newVector = new Vector3(_ScoreText.gameObject.transform.position.x, _ScoreText.gameObject.transform.position.y, _ScoreText.gameObject.transform.position.z + _tileManagerScript.DistanceTiles);
|
||||
_ScoreText.gameObject.transform.position = newVector;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user