Make levelText movable
This commit is contained in:
@@ -1957,6 +1957,7 @@ MonoBehaviour:
|
||||
highScoreText: {fileID: 1606868532}
|
||||
boostText: {fileID: 497996347}
|
||||
coinsText: {fileID: 1527994350}
|
||||
levelText: {fileID: 116559987}
|
||||
pauseButton: {fileID: 1577031227}
|
||||
restartButton: {fileID: 34767206}
|
||||
jumpButton: {fileID: 293594129}
|
||||
|
||||
@@ -16,6 +16,7 @@ public class GamePlayerPauseMenu : MonoBehaviour
|
||||
[SerializeField] private TMP_Text highScoreText;
|
||||
[SerializeField] private TMP_Text boostText;
|
||||
[SerializeField] private TMP_Text coinsText;
|
||||
[SerializeField] private TMP_Text levelText;
|
||||
[SerializeField] private Button pauseButton;
|
||||
[SerializeField] private Button restartButton;
|
||||
[SerializeField] private Button jumpButton;
|
||||
@@ -58,10 +59,12 @@ public class GamePlayerPauseMenu : MonoBehaviour
|
||||
((RectTransform)highScoreText.transform).anchoredPosition = new Vector2(0f, -140f);
|
||||
((RectTransform)boostText.transform).anchoredPosition = new Vector2(0f, -190f);
|
||||
((RectTransform)coinsText.transform).anchoredPosition = new Vector2(260f, 47.5f);
|
||||
((RectTransform)levelText.transform).anchoredPosition = new Vector2(-260f, 85f);
|
||||
PlayerPrefs.DeleteKey("DraggedUIScoreText");
|
||||
PlayerPrefs.DeleteKey("DraggedUIHighScoreText");
|
||||
PlayerPrefs.DeleteKey("DraggedUIBoostText");
|
||||
PlayerPrefs.DeleteKey("DraggedUICoinsText");
|
||||
PlayerPrefs.DeleteKey("DraggedUILevelText");
|
||||
if (Application.isMobilePlatform)
|
||||
{
|
||||
((RectTransform)pauseButton.transform).anchoredPosition = new Vector2(128f, -128f);
|
||||
@@ -151,6 +154,7 @@ public class GamePlayerPauseMenu : MonoBehaviour
|
||||
highScoreText.GetComponent<DraggableUI>().canDrag = !highScoreText.GetComponent<DraggableUI>().canDrag;
|
||||
boostText.GetComponent<DraggableUI>().canDrag = !boostText.GetComponent<DraggableUI>().canDrag;
|
||||
coinsText.GetComponent<DraggableUI>().canDrag = !coinsText.GetComponent<DraggableUI>().canDrag;
|
||||
levelText.GetComponent<DraggableUI>().canDrag = !levelText.GetComponent<DraggableUI>().canDrag;
|
||||
if (Application.isMobilePlatform)
|
||||
{
|
||||
var pauseDraggableUI = pauseButton.GetComponent<DraggableUI>();
|
||||
|
||||
Reference in New Issue
Block a user