Separate SetGem and SpawnGemGameObject
This commit is contained in:
@@ -85,15 +85,13 @@ namespace Views {
|
||||
this.transform.localScale = Vector3.one;
|
||||
}
|
||||
|
||||
private async UniTask FallDelay() {
|
||||
float fallDelay = 1 * (this.gem.Position.y / 10f);
|
||||
await UniTask.WaitForSeconds(fallDelay);
|
||||
private void FallDelay() {
|
||||
this.isFalling = true;
|
||||
}
|
||||
|
||||
public async UniTaskVoid UpdatePosition(Vector2Int positionBasedOnIndex, float gemSpeed) {
|
||||
public void UpdatePosition(Vector2Int positionBasedOnIndex, float gemSpeed) {
|
||||
if (!this.isFalling) {
|
||||
await FallDelay();
|
||||
FallDelay();
|
||||
}
|
||||
|
||||
if (!this.isFalling)
|
||||
|
||||
Reference in New Issue
Block a user