I have searched the internet for a while but none were helpful to me, so I would like to know if you guys knew how they are made so I could construct my own.
You would have to Invoke the client to get the loudness.
You can use RemoteFunctions to do this.
Server Script:
1 | local LoudnessRemote = Instance.new( "RemoteFunction" ) |
2 | LoudnessRemote.Name = "LoudnessRemote" |
3 | LoudnessRemote.Parent = game:GetService( "ReplicatedStorage" )` |
4 | function GetLoudness(Player,Audio) |
5 | return LoudnessRemote:InvokeClient(Player,Audio) |
6 | end |
7 | print (GetLoudness(game.Players.Player 1 ,workspace.Sound)) |
1 | Local Script: |
2 | local LoudnessRemote = game:GetService( "ReplicatedStorage" ):WaitForChild( "LoudnessRemote" ) |
3 | LoudnessRemote.OnClientEvent = function (Audio) |
4 | return Audio.PlaybackLoudness |
5 | end |