Skip to content

API > MLMicrophone


MLMicrophone⚓︎

MLMicrophone inherits from Component

API for MLMicrophone component. MLMicrophone allows to create a live audio binding between Massive Loop MLPlayers audio and AudioSources through MLSpeaker component. Basically, a Microphone and Speaker setup for players. A single Microphone can handle input from multiple players and pipe it to multiple speakers.

Members⚓︎

Properties⚓︎

Name Description
MLMicrophone.ActiveProperty Is microphone active?

Methods⚓︎

Name Description
MLMicrophone.AddSpeaker(newSpeaker) Method Bind a new speaker to the microphone. Wont effect anything if the speaker is already bound.
MLMicrophone.GetSpeakers() Method Returns an array of currently bound Speakers.
MLMicrophone.RemoveSpeaker(speaker) Method Remove a currently bound speaker.

Inherited Members⚓︎

Inherited Properties⚓︎

Name Description
MLMicrophone.gameObjectPropertyReadonly Property The game object this component is attached to. A component is always attached to a game object.
MLMicrophone.tagPropertyReadonly Property The tag of this game object.
MLMicrophone.transformPropertyReadonly Property The Transform attached to this GameObject.
MLMicrophone.hideFlagsProperty Should the object be hidden, saved with the Scene or modifiable by the user?
MLMicrophone.nameProperty The name of the object.

Inherited Methods⚓︎

Name Description
MLMicrophone.BroadcastMessage(methodName, parameter=nil)Method Calls the method named methodName on every Lua Script in this game object or any of its children.
MLMicrophone.CompareTag(tag)Method Is this game object tagged with tag ?
MLMicrophone.GetAllLuaScripts()Method Returns an array of all Lua scripts that attached to the game object.
MLMicrophone.GetComponent(type)Method Returns the component of Type type if the game object has one attached, nil if it doesn't.
MLMicrophone.GetComponentInChildren(t)Method Returns the component of Type type in the GameObject or any of its children using depth first search.
MLMicrophone.GetComponentInParent(t)Method Returns the component of Type type in the GameObject or any of its parents.
MLMicrophone.GetComponents(type)Method Returns all components of Type type in the GameObject.
MLMicrophone.GetComponentsInChildren(t)Method Returns all components of Type type in the GameObject or any of its children.
MLMicrophone.GetComponentsInParent(t)Method Returns all components of Type type in the GameObject or any of its parents.
MLMicrophone.SendMessage(methodName, value=nil)Method Calls the method named methodName on every Lua Script in this game object.
MLMicrophone.SendMessageUpwards(methodName, value=nil)Method Calls the method named methodName on every LuaScript in this game object and on every ancestor of the behaviour.
MLMicrophone.TryGetComponent(type)Method Gets the component of the specified type, if it exists.
MLMicrophone.GetInstanceID()Method Returns the instance id of the object.