// Jimmy Vegas Unity Tutorials // This Script will grip your player on the ledge and complete the level using System.Collections; using System.Collections.Generic; using UnityEngine; public class PlatformGripper : MonoBehaviour { public GameObject theLedge; public GameObject thePlayer; void OnTriggerEnter() { thePlayer.transform.parent = theLedge.transform; } void OnTriggerExit() { thePlayer.transform.parent = null; } } using System.Collections; using System.Collections.Generic; using UnityEngine; public class FinishLevel : MonoBehaviour { public GameObject levelMusic; public AudioSource levelComplete; public GameObject levelTimer; void OnTriggerEnter() { levelMusic.SetActive(false); levelTimer.SetActive(false); levelComplete.Play(); } }