1
0
mirror of https://github.com/kepler155c/opus synced 2024-09-28 23:10:41 +00:00
opus/sys/apis/sound.lua
kepler155c@gmail.com eb799004f8 sounds
2018-11-26 20:53:28 -05:00

13 lines
226 B
Lua

local peripheral = _G.peripheral
local speaker = peripheral.find('speaker')
local Sound = { }
function Sound.play(sound, vol)
if speaker then
speaker.playSound('minecraft:' .. sound, vol or 1)
end
end
return Sound