[FIX] Fix call gcphone (no WebRTC)

Thanks bro… <3
Works

2 Likes

so does this fix the issue where when you are on the phone, whoever next to you cant hear you talk??

no, this solves that you could not talk to calls on OneSync servers.

1 Like

Hello, I have the gcphone running on a 64 slot OneSync server. I can accept the calls but hear no. I tried everything that is here. Can anybody help me further? Thanks

I do not know if you have the same problem as me with the oneSync is that when I change the lines of codes by those proposed, the phone number in the settings and contact are missing!

No, I do not have that. I can call, lose weight. Everything is in the contacts, but I can not hear anyone on the phone. Sorry, google translator.

help me that does not work, please.

Not works, i need help. :frowning:

1 Like

I try this, but not works.

RegisterServerEvent('gcPhone:acceptCall')
AddEventHandler('gcPhone:acceptCall', function(infoCall, rtcAnswer)
    local id = infoCall.id
    if AppelsEnCours[id] ~= nil then
        if PhoneFixeInfo[id] ~= nil then
            onAcceptFixePhone(source, infoCall, rtcAnswer)
            return
        end
        AppelsEnCours[id].receiver_src = infoCall.receiver_src or AppelsEnCours[id].receiver_src
        if AppelsEnCours[id].transmitter_src ~= nil and AppelsEnCours[id].receiver_src~= nil then
            AppelsEnCours[id].is_accepts = true
            AppelsEnCours[id].rtcAnswer = rtcAnswer
            TriggerClientEvent('gcPhone:acceptCall', AppelsEnCours[id].transmitter_src, AppelsEnCours[id], true)
	    SetTimeout(1000, function() -- change to +1000, if necessary.
       		TriggerClientEvent('gcPhone:acceptCall', AppelsEnCours[id].receiver_src, AppelsEnCours[id], false)
	    end)
            saveAppels(AppelsEnCours[id])
        end
    end
end)
function onAcceptFixePhone(source, infoCall, rtcAnswer)
    local id = infoCall.id
    
    AppelsEnCours[id].receiver_src = source
    if AppelsEnCours[id].transmitter_src ~= nil and AppelsEnCours[id].receiver_src~= nil then
        AppelsEnCours[id].is_accepts = true
        AppelsEnCours[id].forceSaveAfter = true
        AppelsEnCours[id].rtcAnswer = rtcAnswer
        PhoneFixeInfo[id] = nil
        TriggerClientEvent('gcPhone:notifyFixePhoneChange', -1, PhoneFixeInfo)
        TriggerClientEvent('gcPhone:acceptCall', AppelsEnCours[id].transmitter_src, AppelsEnCours[id], true)
	SetTimeout(1000, function() -- change to +1000, if necessary.
       		TriggerClientEvent('gcPhone:acceptCall', AppelsEnCours[id].receiver_src, AppelsEnCours[id], false)
	end)
        saveAppels(AppelsEnCours[id])
    end
end

Not works.

1 Like

– change to +1000, if necessary.

This is for calls 1 to 1, you accept the call and then if you have PUSH TO TALK activated, you must press the button to speak. That it does not work for you because you do not follow the indications, it does not mean that it does not work, many people worked (while doing things well), do not expect that when you enter the call automatically change to Voice Activity.

Also as mentioned several times, WebRTC must be disabled.

1 Like

me personally it does not work while I have the latest version

did you figured it out?

You have any Solution?

Hi,

I have problems with this on my 64 slots server, I have tested out everything you have mentioned. No errors, but people can’t hear each other.

How do I fix this?

Best regards,
Gyan.

Oh and, not to forget it says:

nui://gcphone/html/static/js/app.js:453, JS USE RTC

I have the same problem and the same error as you, server with one sync, 64 slots, i installed gcphone_vrp, calls do not work at all, no one can hear me and i cant hear any1.

ok here is the problem. how can i do when a player talks with phone the other nearest players are can hear him ?

This fix is not more working

Currently it still works without problems, on my server it works only with mumble and using the fix in GcPhone. As I said earlier, I do not support the GCPhone resource.

Yeah sry Its work xD