Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class LaneCollider : MonoBehaviour {
- public GameObject lane;
- public bool positive;
- // Use this for initialization
- void Start () {
- }
- // Update is called once per frame
- void Update () {
- }
- private void OnTriggerEnter(Collider other)
- {
- lane.GetComponent<LaneController>().enterEndZone(other.gameObject, positive);
- }
- private void OnTriggerExit(Collider other)
- {
- lane.GetComponent<LaneController>().exitEndZone(other.gameObject, positive);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement