Простой телепорт (портал) в Unity / Simple teleport (portal) in Unity

Аватар автора
Игровые Загадки
В видео будет показано как создать самый простой телепорт/портал в Unity. Код ниже! The video will show the simplest teleport/portal in Unity. Code below! CODE: using UnityEngine; public class Teleport : MonoBehaviour { [SerializeField] private Transform _outPort; private void OnTriggerEnter(Collider other) { other.transform.position = _outPort.position; float rotY = _outPort.rotation.eulerAngles.y; other.transform.rotation = Quaternion.Euler(other.transform.rotation.x, rotY - 180, other.transform.rotation.z); } } #телепорт

0/0


0/0

0/0

0/0