Рефакторинг VitrinaBox
This commit is contained in:
parent
af8062ec59
commit
58ad8dd3b6
@ -1,6 +1,4 @@
|
||||
using System.Collections;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using System.Collections;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
|
||||
@ -15,7 +13,7 @@ public class VitrinaBox : MonoBehaviour
|
||||
public bool shake;
|
||||
Coroutine pingpongCoroutine;
|
||||
|
||||
[Header("Íàñòðîéêè àíèìàöèè")]
|
||||
[Header("Настройки анимации")]
|
||||
[SerializeField] private float amplitude = 0.1f;
|
||||
[SerializeField] private float frequency = 7;
|
||||
private void OnEnable()
|
||||
@ -56,7 +54,7 @@ public class VitrinaBox : MonoBehaviour
|
||||
yield return null;
|
||||
}
|
||||
|
||||
//Âîçâðàò â èñõîäíóþ
|
||||
//Возврат в исходную
|
||||
while (ImageTransform.localScale != Vector3.one)
|
||||
{
|
||||
ImageTransform.localScale = Vector3.MoveTowards(ImageTransform.localScale, Vector3.one, Time.deltaTime);
|
||||
@ -81,7 +79,4 @@ public class VitrinaBox : MonoBehaviour
|
||||
yield return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user