@quenty/sounds 3.8.0 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [4.0.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/sounds@3.8.0...@quenty/sounds@4.0.0) (2022-03-06)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * Support sound playback for non-local situations. On the server this will require the sound to be parented. ([1884237](https://github.com/Quenty/NevermoreEngine/commit/1884237120fbbb3c9b29032d995c132af381f16b))
12
+
13
+
14
+
15
+
16
+
6
17
  # [3.8.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/sounds@3.7.1...@quenty/sounds@3.8.0) (2022-01-17)
7
18
 
8
19
  **Note:** Version bump only for package @quenty/sounds
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quenty/sounds",
3
- "version": "3.8.0",
3
+ "version": "4.0.0",
4
4
  "description": "Utility functions involving sounds and their state",
5
5
  "keywords": [
6
6
  "Roblox",
@@ -26,11 +26,11 @@
26
26
  "Quenty"
27
27
  ],
28
28
  "dependencies": {
29
- "@quenty/loader": "^3.4.0",
30
- "@quenty/promise": "^3.6.0"
29
+ "@quenty/loader": "^4.0.0",
30
+ "@quenty/promise": "^4.0.0"
31
31
  },
32
32
  "publishConfig": {
33
33
  "access": "public"
34
34
  },
35
- "gitHead": "c094ba8f4e128cdff08919d89de226d3d65247ce"
35
+ "gitHead": "dd428cab58282c975a4c082957dc8f58e3186905"
36
36
  }
@@ -9,6 +9,7 @@
9
9
  ]=]
10
10
 
11
11
  local SoundService = game:GetService("SoundService")
12
+ local RunService = game:GetService("RunService")
12
13
 
13
14
  local SoundUtils = {}
14
15
 
@@ -36,7 +37,11 @@ function SoundUtils.playFromId(id)
36
37
  sound.Volume = 0.25
37
38
  sound.Archivable = false
38
39
 
39
- SoundService:PlayLocalSound(sound)
40
+ if RunService:IsClient() then
41
+ SoundService:PlayLocalSound(sound)
42
+ else
43
+ sound:Play()
44
+ end
40
45
 
41
46
  task.delay(sound.TimeLength + 0.05, function()
42
47
  sound:Destroy()