I’m currently trying to make a spatial voice only game on Roblox; a game where only players with spatial voice enabled can join. Currently, when trying to use VoiceChatService, coupled with the IsVoiceEnabledForUserIdAsync(), I get an error.
“VoiceChatService:IsVoiceEnabledForUserIdAsync() is not yet implemented on the server”
I tried looking for the documentation for VoiceChatService on developer.roblox.com but couldn’t find the page for it, I also haven’t found anyone else with this issue.
Here’s my code:
local VoiceChatService = game:GetService("VoiceChatService")
local Players = game:GetService("Players")
Players.PlayerAdded:Connect(function(player)
local UserId = player.UserId
local voice_enabled = VoiceChatService:IsVoiceEnabledForUserIdAsync(UserId)
if not voice_enabled then
player:Kick("You need to have voice enabled to play this game.")
end
end)
Since this feature is in Beta, it could probably mean that only CoreScripts can access it at the moment, meaning you will need to wait for the full release.
Or, it could be that you haven’t enabled it yet, make sure it’s enabled!
You can go here to see how to do this.
Lol I’m actually looking for the same thing, I’ve contacted another developer whos successfully done it.
When a user joins this with spatial they will be redirected to another world/server full of users with spatial voice enabled, Ill let you know if I figure anything out
If you wish to see for yourself heres the link https://www.roblox.com/games/6985028626/Roblox-Community-Space
There’s probably some features that are accessible to only certain games, VoiceChatService in Community Space for example, since it was the first game with Spatial Voice. I think eventually we’ll have access to the feature, it’s just a matter of time.
Yeah, I talked to the ROBLOX admin in Community Space Alligator said the feature is there, but is not yet available for normal players.
Note I found this too
(I also talked to another Administrator and he says Spatial Hangout has the feature enabled because the group is owned by a ROBLOX Administrator)
Just to answer your question, Looking at your output I can see that you were trying to use the method on the server which is not supported yet. You’re able to use VoiceChatService:IsVoiceEnabledForUserIdAsync(UserId) on the client not the server.
Also note that the request may fail so it’s best if you wrap it in a pcall function.
PS: Use the method on a localscript in the client.