Quantcast
Channel: Questions in topic: "portals"
Viewing all articles
Browse latest Browse all 85

seamless portals like in the game portal

$
0
0
The script that I have teleports the player from one object to another with collisions but I'm looking for it to be more like a gateway sort of like in portal where you could have one foot in one and the other foot out the other. Any help or code for this would be greatly appreciated. using UnityEngine; using System.Collections; public class Portals : MonoBehaviour { public GameObject otherPortal; void OnTriggerEnter (Collider other) { if(other.tag == "Player") { other.transform.position = otherPortal.transform.position + otherPortal.transform.forward * 2; } } }

Viewing all articles
Browse latest Browse all 85

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>