Vrp detect coma

help

#1

so i am trying to make a script that plays a .ogg file when u die and enter coma
i have tryed to learn the vRP code but i cant really get it to work
ps sorry for my typing i am really sleapy the kl is 3 midnight

this is what i got


client.lua


local Proxy = module(“vrp”, “lib/Proxy”)
vRP = Proxy.getInterface(“vRP”)

local Tunnel = module(“vrp”, “lib/Tunnel”)
clientaccess = Tunnel.getInterface(“myrsc”)

– CONFIG –

– Sound volume (0.0 - 1.0)
local volume = 0.4

– CODE –

Citizen.CreateThread(function()
while true do
Wait(1)

	if  vRPclient.isInComa() then
	
			SendNUIMessage({
				playdeathsound = true,
				deathvolume = volume
				})
				
		end
	end
end

end)



#2

Try this:)

Citizen.CreateThread(function()
  while true do
    Wait(1)
    if in_coma then
        SendNUIMessage({
	   playdeathsound = true,	   
           deathvolume = volume
	  })
        end
    end
end)

#3

sorry but it dosent work :confused:


#4

i just added a download so if u want u can download it and play with it too i wud be happy for the help