public static float3 GetMouthPosition(AnimalScript animal, MouthScript mouth) { if (mouth != null) { return(mouth.mouth.position); } return(animal.position); }
public override void MakeOrganism(BasicOrganismScript newOrganism) { MouthScript mouthScript = speciesScript.InstantiateNewOrgan(mouth, newOrganism).GetComponent <MouthScript>(); mouthScript.biteSize = biteSize; mouthScript.eatTime = eatTime; mouthScript.eatRange = eatRange; mouthScript.SetupBasicOrgan(this, newOrganism); }