I’m trying to make it so that if someone has vc enabled it shows it above the players head and also if they don’t, but I keep getting an error.
Code: (ServerScript)
local vcs = game:GetService("VoiceChatService")
game.Players.PlayerAdded:Connect(function(plr)
plr.CharacterAdded:Connect(function(char)
local tag = game.ServerStorage.VoiceTag:Clone()
tag.Parent = char:WaitForChild("Head")
tag.Adornee = char:WaitForChild("Head")
if vcs:IsVoiceEnabledForUserIdAsync(plr.UserId) then
tag.Frame.ImageLabel.Image = "rbxassetid://7951705172"
else
tag.Frame.ImageLabel.Image = "rbxassetid://7951704608"
end
end)
end)
Error:
VoiceChatService:IsVoiceEnabledForUserIdAsync() is not yet implemented on the server (line 8)
local vcs = game:GetService("VoiceChatService")
local player = game.Players.LocalPlayer
if vcs:IsVoiceEnabledForUserIdAsync(player.UserId) then
print("Voice chat enabled.")
else
print("Voice chat disabled.")
end