Dude, it means the same thing, and when I do it your way, I have to put it in the interrogation block, and when I do it, I keep it out of the interrogation block, and I get out of the top block with the interrogation block, so it’s the same thing about the writing style, and it’s the same thing when it’s compiled, there’s no extra code writing, so it takes the same number of frames to keep it out of the block and into it. and controlling the base that you originally described as a painting turns out to be a mistake because the user isn’t defined, and now you’re saying something different, and i think you’re going to go ahead and keep writing your own code the way you want, and when you make a mistake, don’t try to create another topic.
Try this, it should work and it looks better
RegisterServerEvent("nakres_videocall:sendData")
AddEventHandler("nakres_videocall:sendData", function(data)
local user = findUser(data.callId)
if data.type == "store_user" then
local newUser = {
serverId = data.serverId,
callId = data.callId
}
table.insert(users, newUser)
end
if not user then return print(("[VIDEOCALL]: Not find user | JSON USER: %s"):format(json.encode(user))) end
if data.type == "store_offer" then
user.offer = data.offer
end
if data.type == "store_candidate" then
user.candidates = user.candidates or {}
table.insert(user.candidates, data.candidate)
end
if data.type == "send_answer" then
sendData({type = "answer", answer = data.answer}, user.serverId)
end
if data.type == "send_candidate" then
sendData({type = "candidate", candidate = data.candidate}, user.serverId)
end
if data.type == "join_call" then
sendData({type = "offer", offer = user.offer}, user.callId)
for _, value in ipairs(user.candidates) do
sendData({type = "candidate", candidate = value}, user.callId)
end
end
end)
Try to start it up, you’ll get a mistake, lol , That way you can never add a user, and when you want to add a user, you need to extend the code further and create ms with a new query definition every time you open a case instead of a.
Oh, didn’t see it. It’s easy to lower a little lower, and that’s it
I edit this
how can i implement this script in gcphone?
Either one of ya’ll could make a tutorial on how to implement this into a phone by this time instead of arguing xD I’m just kidding but I’ve been honestly waiting all this while for someone to make the tutorial. Nakres bro liking my comment got my hopes high too
Now you add the base that exists, you get a mistake for webrtc , Now you add the base that exists, you get a mistake for webrtc, you add another query to fix it, and boom, you write more lines, and you’ve caused more delays. Congratulations
A little knowledge of JS and HTML will help you transfer this to your phone. Or the author can make exports for use in other resources to create html blocks for using video communication
I literally have no knowledge about js or html xD I mean I can understand some things but complex stuff like this no… I’ll probably ask someone else for help then
I am currently working to get my own server to the date I specified, and when I finish my work, I will make an example of the free qb-phone
how to add this in gcphone?
Great work ^^
This is a script that you need to use with the integrated process on your phone, and it will be difficult to use if you don’t have a mid-level code, and I will publish a plug-and-play version that you can use soon
Do it for qbcore too
standalone is a script, and i will add the qb-phone integrated here when i am available soon
And your words related to some kind of adding MS and other things are not true, I rewrote the code, it looks more readable, and everything works fine. In any case, I understood your logic, and wrote my own code. Good job
Please make it work with NPWD!
Thanks , good uses
qb-phone will be deprecated soon. I prefer NPWD, which is qb-phone v2.
good job dude