mNo edit summary |
Hail12Pink (talk | contribs) No edit summary |
||
Line 6: | Line 6: | ||
|raw_recipe = {{#invoke:GetPartInfo|getField|Raw recipe}} |
|raw_recipe = {{#invoke:GetPartInfo|getField|Raw recipe}} |
||
|malleability = {{#invoke:GetPartInfo|getField|Malleability}} |
|malleability = {{#invoke:GetPartInfo|getField|Malleability}} |
||
|durability = {{#invoke:GetPartInfo|getField|Durability}} |
|||
}} |
}} |
||
Line 26: | Line 27: | ||
''"Plays audio of length up to 5 seconds, unless it is powered in which case it can play a full audio. When clicked or triggered, it will toggle playing music and will play the song id you give it.'' |
''"Plays audio of length up to 5 seconds, unless it is powered in which case it can play a full audio. When clicked or triggered, it will toggle playing music and will play the song id you give it.'' |
||
{{#invoke:GetPartInfo|getField|Description}} |
|||
''Speaker:LoadSound(Soundid) will return a Sound object. A Sound object can be modified using properties Soundid, Looped, PlaybackSpeed, Pitch, TimePosition and the methods Play, Pause, Stop, Destroy."'' |
|||
==Misc== |
==Misc== |
Revision as of 13:27, 14 March 2022
Speakers can play audio much like Boomboxes. Speakers will still play 5 seconds of the audio even when unpowered. Pitch can be changed. Also has a Chat function which shows a bubble chat above the speaker.
Programming
- Speaker:PlaySound(soundId)
- Speaker:LoadSound(soundId)
- Speaker:ClearSounds()
- Speaker:Chat(string message)
Example:
local Speaker = GetPartFromPort(1, "Speaker")
Speaker:Chat("hello!") --Bubble chat above speaker
In-game description
"Plays audio of length up to 5 seconds, unless it is powered in which case it can play a full audio. When clicked or triggered, it will toggle playing music and will play the song id you give it.
"Plays audio of length up to 5 seconds, unless it is powered in which case it can play a full audio. When clicked or triggered, it will toggle playing music and will play the song id you give it. Speaker:LoadSound(SoundId) will return a Sound object A Sound object can be modified using properties SoundId, Looped, PlaybackSpeed, Pitch, TimePositionand the methods Play, Pause, Stop, Destroy"
Misc
Default size is 2x2x2, but you can resize it. The bigger it is the louder it will sound.
Configurable
- Audio
- Pitch