Skip to content
This repository has been archived by the owner on Dec 12, 2024. It is now read-only.

Commit

Permalink
fix nil error
Browse files Browse the repository at this point in the history
  • Loading branch information
FrazzIe committed Sep 2, 2020
1 parent 3ba10ca commit d71b6fb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions client.lua
Original file line number Diff line number Diff line change
Expand Up @@ -712,11 +712,11 @@ Citizen.CreateThread(function()
if mumbleConfig.radioEnabled then
if not mumbleConfig.controls.radio.pressed then
if IsControlJustPressed(0, mumbleConfig.controls.radio.key) then
if playerRadio > 0 then
if playerData.radio > 0 then
SetVoiceData("radioActive", true)
playerData.radioActive = true
SetPlayerTargets(callTargets, speakerTargets, radioTargets) -- Send voice to everyone in the radio and call
PlayMicClick(playerRadio, true)
PlayMicClick(playerData.radio, true)
mumbleConfig.controls.radio.pressed = true

Citizen.CreateThread(function()
Expand All @@ -726,7 +726,7 @@ Citizen.CreateThread(function()

SetVoiceData("radioActive", false)
SetPlayerTargets(callTargets, speakerTargets) -- Stop sending voice to everyone in the radio
PlayMicClick(playerRadio, false)
PlayMicClick(playerData.radio, false)
playerData.radioActive = false
mumbleConfig.controls.radio.pressed = false
end)
Expand Down

0 comments on commit d71b6fb

Please sign in to comment.