some old sounds are added

This commit is contained in:
Timur Nizamov
2025-10-17 01:54:45 +03:00
parent 16c4680d6c
commit 013ed4944c
52 changed files with 929 additions and 43 deletions

View File

@@ -65,7 +65,10 @@ public class StencilPortal : MonoBehaviour
matchOrientation = MatchOrientation.TargetUpAndForward
};
AudioManager.Instance.PlayOneShot3D(FMODEvents.Instance.PortalEnter, targetPosition);
teleportationProvider.QueueTeleportRequest(request);
other.transform.rotation = TransformRotationBetweenPortals(this, targetPortal, other.transform.rotation);
}
else
@@ -79,6 +82,7 @@ public class StencilPortal : MonoBehaviour
{
Destroy(gameObject, 0.5f);
}
}
private void OnTriggerExit(Collider other)
@@ -86,6 +90,9 @@ public class StencilPortal : MonoBehaviour
AllowTeleport();
if (!_shouldTeleport || IsInvoking(nameof(AllowTeleport))) return;
if (!other.CompareTag("Player")) return;
AudioManager.Instance.PlayAttachedInstance(FMODEvents.Instance.PortalEnter, gameObject);
Debug.Log(transform.name + " player exited");
Invoke(nameof(AllowTeleport), 1f);
}