public virtual List <ArdenAudioClip> GetFootstep(MaterialSound external, Vector3 position) { if (external == null || material == null) { return(null); } MaterialSound.MaterialInteraction matint = material.GetInteraction(external); return(matint.sounds); }
public MaterialInteraction GetInteraction(MaterialSound material) { foreach (MaterialInteraction interaction in interactions) { if (interaction.material == material) { return(interaction); } } return(null); }
public override List <ArdenAudioClip> GetFootstep(MaterialSound material, Vector3 position) { if (terrain == null) { terrain = GetComponent <Terrain>(); } int index = GetMainTexture(position); MaterialSound.MaterialInteraction matint = soundList.materialSounds[index].GetInteraction(material); return(matint.sounds); }