added audio loop to portalrooms
This commit is contained in:
parent
c083470916
commit
cb7e6fe770
3 changed files with 11 additions and 0 deletions
BIN
src/janusweb/media/audio/bgloop.ogg
Normal file
BIN
src/janusweb/media/audio/bgloop.ogg
Normal file
Binary file not shown.
Binary file not shown.
|
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 33 KiB |
|
|
@ -12,10 +12,16 @@
|
|||
return url
|
||||
end
|
||||
|
||||
portalroom = #items > 0 and #remoteitems > 0
|
||||
audio_bgloop = URL('janusweb/media/audio/bgloop.ogg')
|
||||
|
||||
end}
|
||||
|
||||
<fireboxroom>
|
||||
<assets>
|
||||
{if portalroom then
|
||||
print(' <assetsound id="bgloop" src="${audio_bgloop}"/>')
|
||||
end}
|
||||
{if defined(items) and #items > 0 then
|
||||
for i,v in pairs(items) do
|
||||
if #v.thumbnail > 0 then
|
||||
|
|
@ -61,6 +67,11 @@ end}
|
|||
room = '' -- xrfragments 3D files dont need to be wrapped with room
|
||||
end
|
||||
print(' <room skybox="true" pos="' .. pos .. '" showavatar="false" use_local_asset="' .. room .. '">')
|
||||
|
||||
if portalroom then
|
||||
print(' <sound id="bgloop" loop="true" auto_play="true"/>')
|
||||
end
|
||||
|
||||
if room == 'empty_floor' then
|
||||
print(' <!-- helper to be able to walk/teleport -->')
|
||||
print(' <object id="plane" color_write="false" rotation="90 0 0" collision_id="plane" scale="100 100 1" collision_scale="100 100 1"/>')
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue