Skip to content

From StreamCore To WebAudio

Vurv edited this page May 6, 2021 · 8 revisions

Because WebAudio is object oriented (We don't use indexes to run code) and much more advanced, this guide is here to help you convert your Streamcore contraptions to WebAudio

Playing a stream parented to a prop

# StreamCore
E:streamStart(1, "<URL>")
# WebAudio
local Stream = webAudio("<URL>")
Stream:setParent(E) # or use parentTo
Stream:play()

Modifying an existing stream (Setting Volume to 50%)

# StreamCore
streamVolume(1, 0.5)
# WebAudio
Stream:setVolume(50)
Stream:update() # If we are not calling :play() or :pause(), the data is not immediately updated. Call :update() to manually send this new volume information to the client.
Clone this wiki locally