Quantcast
Channel: Unity Forum
Viewing all articles
Browse latest Browse all 1466670

Change level on trigger

$
0
0
I've added this code to try to change the level when the character enters the trigger but it isn't working for some reason. I've got a box collider set to is trigger and added a rigidbody.

using UnityEngine;
using System.Collections;
public class Leveltrigger : MonoBehaviour {
void OnTriggerEnter(Collider other) { Application.LoadLevel(2); } }

Any help would be great Thanks

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



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