Bypass for loading QBCore in FxDK (#792)

FxDK does not include license identifiers by default and thus breaks scripts that utilize those. Without this you will get the "No valid Rockstar license" error when connecting. This fix was not my own I found it in the post linked below and tested myself.

https://forum.cfx.re/t/connection-rejected-by-server-fxdk/2504365/5

Co-authored-by: Kakarot <57848836+GhzGarage@users.noreply.github.com>
Co-authored-by: Stan <96954031+tom-osborne@users.noreply.github.com>
Co-authored-by: Zerio <54480523+Z3rio@users.noreply.github.com>
This commit is contained in:
Chris Sinclair
2022-12-11 13:43:10 +01:00
committed by GitHub
co-authored by Kakarot Stan Zerio
parent 40b56c724f
commit 312f24d245
+4
View File
@@ -41,6 +41,10 @@ local function onPlayerConnecting(name, _, deferrals)
end end
end end
if GetConvarInt("sv_fxdkMode", false) then
license = 'license:AAAAAAAAAAAAAAAA' -- Dummy License
end
if not license then if not license then
deferrals.done(Lang:t('error.no_valid_license')) deferrals.done(Lang:t('error.no_valid_license'))
elseif QBCore.Config.Server.CheckDuplicateLicense and QBCore.Functions.IsLicenseInUse(license) then elseif QBCore.Config.Server.CheckDuplicateLicense and QBCore.Functions.IsLicenseInUse(license) then