diff --git a/README.md b/README.md index fc5e3235..162d2aef 100644 --- a/README.md +++ b/README.md @@ -26,3 +26,15 @@ start esx_voice ## Credits [aabbfive](https://github.com/aabbfive/voicecontroller) - Original author + +# Legal +### License +esx_voice + +Copyright (C) 2015-2020 Jérémie N'gadi + +This program Is free software: you can redistribute it And/Or modify it under the terms Of the GNU General Public License As published by the Free Software Foundation, either version 3 Of the License, Or (at your option) any later version. + +This program Is distributed In the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty Of MERCHANTABILITY Or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License For more details. + +You should have received a copy Of the GNU General Public License along with this program. If Not, see http://www.gnu.org/licenses/. diff --git a/__resource.lua b/__resource.lua index d314d63b..bbf4a86a 100644 --- a/__resource.lua +++ b/__resource.lua @@ -9,7 +9,7 @@ client_scripts { 'locales/br.lua', 'locales/en.lua', 'locales/fi.lua', - 'locales/fr.lua', + 'locales/fr.lua', 'locales/pl.lua', 'locales/sv.lua', 'config.lua', diff --git a/client/main.lua b/client/main.lua index 9f03719d..7b461c26 100644 --- a/client/main.lua +++ b/client/main.lua @@ -1,15 +1,3 @@ -local Keys = { - ["ESC"] = 322, ["F1"] = 288, ["F2"] = 289, ["F3"] = 170, ["F5"] = 166, ["F6"] = 167, ["F7"] = 168, ["F8"] = 169, ["F9"] = 56, ["F10"] = 57, - ["~"] = 243, ["1"] = 157, ["2"] = 158, ["3"] = 160, ["4"] = 164, ["5"] = 165, ["6"] = 159, ["7"] = 161, ["8"] = 162, ["9"] = 163, ["-"] = 84, ["="] = 83, ["BACKSPACE"] = 177, - ["TAB"] = 37, ["Q"] = 44, ["W"] = 32, ["E"] = 38, ["R"] = 45, ["T"] = 245, ["Y"] = 246, ["U"] = 303, ["P"] = 199, ["["] = 39, ["]"] = 40, ["ENTER"] = 18, - ["CAPS"] = 137, ["A"] = 34, ["S"] = 8, ["D"] = 9, ["F"] = 23, ["G"] = 47, ["H"] = 74, ["K"] = 311, ["L"] = 182, - ["LEFTSHIFT"] = 21, ["Z"] = 20, ["X"] = 73, ["C"] = 26, ["V"] = 0, ["B"] = 29, ["N"] = 249, ["M"] = 244, [","] = 82, ["."] = 81, - ["LEFTCTRL"] = 36, ["LEFTALT"] = 19, ["SPACE"] = 22, ["RIGHTCTRL"] = 70, - ["HOME"] = 213, ["PAGEUP"] = 10, ["PAGEDOWN"] = 11, ["DELETE"] = 178, - ["LEFT"] = 174, ["RIGHT"] = 175, ["TOP"] = 27, ["DOWN"] = 173, - ["NENTER"] = 201, ["N4"] = 108, ["N5"] = 60, ["N6"] = 107, ["N+"] = 96, ["N-"] = 97, ["N7"] = 117, ["N8"] = 61, ["N9"] = 118 -} - local voice = {default = 5.0, shout = 12.0, whisper = 1.0, current = 0, level = nil} function drawLevel(r, g, b, a) @@ -20,7 +8,7 @@ function drawLevel(r, g, b, a) SetTextDropShadow() SetTextOutline() - BeginTextCommandDisplayText("STRING") + BeginTextCommandDisplayText('STRING') AddTextComponentSubstringPlayerName(_U('voice', voice.level)) EndTextCommandDisplayText(0.175, 0.92) end @@ -39,7 +27,7 @@ Citizen.CreateThread(function() while true do Citizen.Wait(1) - if IsControlJustPressed(1, Keys['H']) and IsControlPressed(1, Keys['LEFTSHIFT']) then + if IsControlJustPressed(1, 74) and IsControlPressed(1, 21) then voice.current = (voice.current + 1) % 3 if voice.current == 0 then NetworkSetTalkerProximity(voice.default) diff --git a/config.lua b/config.lua index ad83260a..1875b978 100644 --- a/config.lua +++ b/config.lua @@ -1,2 +1,3 @@ -Config = {} -Config.Locale = 'en' \ No newline at end of file +Config = {} + +Config.Locale = 'fr'