using System; using UnityEngine; using UnityEngine.Serialization; public class Pit : MonoBehaviour { public float startmass; private void OnTriggerEnter(Collider other) { if (other.isTrigger) return; startmass = other.GetComponent().mass; other.GetComponent().mass = 100; other.GetComponent().mass = startmass; other.GetComponent().Reset(); } }