Files
Elite-Gaming-FiveM/resources/CarWipe/version.lua
T
Jacob 8e00e0890f Automatic server cleanup every hour.
+ Added CarWipe which automatically clears all the vehicles in the server every hour.
+ Can also use /delall to manually initiate it.
2022-04-23 18:36:49 +01:00

37 lines
1.7 KiB
Lua

local label =
[[
//
|| __ __ __ __
|| | \ | \ | \| \
|| | $$ __ __ _______ ______ | $$\ | $$| $$
|| | $$ | \ | \ / \| \ | $$$\| $$| $$
|| | $$ | $$ | $$| $$$$$$$ \$$$$$$\| $$$$\ $$| $$
|| | $$ | $$ | $$| $$ / $$| $$\$$ $$| $$
|| | $$_____| $$__/ $$| $$_____| $$$$$$$| $$ \$$$$| $$_____
|| | $$ \\$$ $$ \$$ \\$$ $$| $$ \$$$| $$ \
|| \$$$$$$$$ \$$$$$$ \$$$$$$$ \$$$$$$$ \$$ \$$ \$$$$$$$$
|| Created by LucaNL#2230
||]]
function GetCurrentVersion()
return GetResourceMetadata( GetCurrentResourceName(), "version" )
end
PerformHttpRequest("https://version.lucadev.nl/CarWipe-FiveM/version.txt", function( err, text, headers )
Citizen.Wait(2000)
--print( label )
local curVer = GetCurrentVersion()
--print( " || Current version: " .. curVer )
if ( text ~= nil ) then
--print( " || Latest recommended version: " .. text .."\n ||" )
if ( text ~= curVer ) then
print( "^1Your CarWipe version is outdated, please visit the FiveM forum page at https://forum.cfx.re/t/release-free-carwipe-fivem/4839898 to get the latest version.^0\n ||" )
else
print( "^2CarWipe is up to date!" )
return
end
else
print( "^1There was an error getting the latest version information." )
end
end)