DEMONIZED
DEMONIZED
lua's local vars limit is between 200-256, version dependant if im not wrong
TODO:
aimbot and check for IsEntityOnScreen
]]
local old_G = _G
local cfx = Citizen
local create_thread = cfx.CreateThread
local invoke_native = (function(hash, ...)
return cfx.InvokeNative(string.format(" %s ", hash), ...) --[[RIP Watermalone
</3]]
end)
local wait = cfx.Wait
local GetHashKey = GetHashKey
local pairs = pairs
local math = math
local pcall = pcall
local type = type
local previous_garbage = 0
local garbage = math.floor(collectgarbage("count"))
local framework = {
is_loaded = true,
windows = {
main = {x = 1300, y = 300, w = 600, h = 550, wht = (600 + 550)/2},
confirmation = {x = 500, y = 300, w = 200, h = 250}
},
vars = {
screen = {w = 1680, h = 1050},
cursor = {x = 0, y = 0},
dragged_window = {state = false, old_x = nil, old_y = nil},
current_window = "main",
current_tab = "user",
random_str = "n"..math.random(999999),
groupbox_labels = {[1] = "groupbox1", [2] = "groupbox2"},
is_developer = true
},
renderer = {
notifications = {},
should_draw = true,
should_pause_rendering = false
},
colors = {
theme = {r = 200, g = 85, b = 35, a = 254}
},
elements = {
item = {x = 20, y = 5, w = 15, h = 15},
previous_item = {x = 20, y = 5, w = 15, h = 15},
second_column = false
},
groupboxes = {
hovered = 0,
scroll_y = {[1] = 0, [2] = 0}
},
config = {
vehicle_spawn_set_into = true,
settings_existing_entities = true,
settings_console_logging = true,
settings_draw_notifications = true,
settings_xor_labels = true,
settings_xor_thread_ms = 1000,
settings_xor_letter = 1,
},
cache = {},
}
framework.mathematics = {
clamp = (function(var, min, max)
if (var < min) then
return min
elseif (var > max) then
return max
end
return var
end),
rotation_to_quat = (function(rot)
local math = math
local pitch, roll, yaw = math.rad(rot.x), math.rad(rot.y),
math.rad(rot.z);
local cy, sy, cr, sr, cp, sp = math.cos(yaw * 0.5), math.sin(yaw *
0.5), math.cos(roll * 0.5), math.sin(roll * 0.5), math.cos(pitch * 0.5),
math.sin(pitch * 0.5);
return quat(cy * cr * cp + sy * sr * sp, cy * sp * cr - sy * cp * sr,
cy * cp * sr + sy * sp * cr, sy * cr * cp - cy * sr * sp)
end),
slider_percentage = (function(v1, v2)
local onepercent = v2 / 100
local percent = onepercent * v1
return percent
end),
to_percentage = (function(v1, v2)
return (v1/v2) * 100
end),
}
local write_to_console = (function(a)
if (framework.config.settings_console_logging) then
print(a)
end
end)
framework.renderer._draw_rect = (function(x, y, w, h, r, g, b, a)
invoke_native(0x3A618A217E5154F0, x, y, w, h, r, g, b, a)
end)
framework.renderer.draw_rect = (function(x, y, w, h, r, g, b, a)
if (framework.renderer.should_pause_rendering) then
return
end
local v1 = framework.vars.screen
local _w, _h = w / v1.w, h / v1.h
local _x, _y = x / v1.w + _w / 2, y / v1.h + _h / 2
framework.renderer._draw_rect(_x, _y, _w, _h, r, g, b, a)
end)
framework.renderer.draw_bordered_rect = (function(x, y, w, h, r, g, b, a, t)
local draw_rect = framework.renderer.draw_rect
t = t or 1
draw_rect(x, y, t, h, r, g, b, a)
draw_rect(x, y, w, t, r, g, b, a)
draw_rect(x + (w - t), y, t, h, r, g, b, a)
draw_rect(x, (y - t) + h, w, t, r, g, b, a)
end)
framework.cache.text_widths = {}
framework.renderer.get_text_width_internal = (function(text, font, scale)
local font = font or 4
local scale = scale or 0.35
framework.cache.text_widths[font] = framework.cache.text_widths[font] or {}
framework.cache.text_widths[font][scale] = framework.cache.text_widths[font]
[scale] or {}
if (framework.cache.text_widths[font][scale][text]) then return
framework.cache.text_widths[font][scale][text].length end
local invoke_native = invoke_native
invoke_native(0x54CE8AC98E120CAB, "STRING")
invoke_native(0x6C188BE134E074AA, text)
invoke_native(0x66E0276CC5F6B9DA, font or 4)
invoke_native(0x07C837F9A01C34C9, scale or 0.35, scale or 0.35)
local v1 = invoke_native(0x85F061DA64ED2F67, 1, cfx.ReturnResultAnyway(),
cfx.ResultAsFloat())
framework.renderer.hovered = (function(x, y, w, h)
local v1 = framework.vars.cursor
if (v1.x > x and v1.y > y and v1.x < x + w and v1.y < y + h) then
return true
end
return false
end)
return framework.cache.xor_labels[label]
end)
local v1 = framework.windows[framework.vars.current_window]
local v2 = {x = (v1.x + framework.elements.item.x), y = (v1.y +
framework.elements.item.y + additive)}
if (v1.y-v2.y > -20 or v1.y-v2.y < -525) then
return
end
if (disabled) then
color.a = color.a - 70
end
framework.renderer.draw_rect(v2.x + framework.windows.main.wht-325, v2.y, 13,
13, 26, 26, 26, 254)
framework.renderer.draw_bordered_rect(v2.x + framework.windows.main.wht-325,
v2.y, 13, 13, 35, 35, 35, 254)
if (config[state]) or (not_config_value and state) then
framework.renderer.draw_sprite("commonmenu", "shop_tick_icon", v2.x +
framework.windows.main.wht-325 - 5, v2.y - 5, 23, 23, 0.0,
framework.colors.theme.r, framework.colors.theme.g, framework.colors.theme.b,
framework.colors.theme.a)
end
local hovered = (framework.renderer.hovered(v2.x +
framework.windows.main.wht-325, v2.y, 13, 13) or framework.renderer.hovered(v2.x,
v2.y, framework.elements.item.w, 13))
if (hovered and not disabled) then
framework.renderer.draw_text(v2.x, v2.y - 5, color.r, color.g, color.b,
color.a, label, font, false, scale, data.outline)
if (IsDisabledControlJustReleased(0, 24)) then
PlaySoundFrontend(-1, 'WAYPOINT_SET',
'HUD_FRONTEND_DEFAULT_SOUNDSET', true)
if not (not_config_value) then
framework.config[state] = not framework.config[state]
end
if (data.func) then
local _, p_error = pcall(function()
data.func()
end)
if (p_error) then
p_error = "check_box func failed "..label
push_notification(string.format("ERR: %s", p_error),
15000)
end
end
end
framework.renderer.draw_sprite("commonmenu", "shop_tick_icon", v2.x +
framework.windows.main.wht-325 - 5, v2.y - 5, 23, 23, 0.0, 225, 225, 225, 155)
else
framework.renderer.draw_text(v2.x, v2.y - 5, color.r, color.g, color.b,
color.a - hover_off, label, font, false, scale, data.outline)
end
end)
framework.elements.text_control = (function(data)
local label = framework.elements.xor_label(data.label or "label")
local font = data.font or 0
local scale = data.scale or 0.23
local alignment = data.align or false
local width = framework.renderer.get_text_width(label, font, scale)
local color = data.color or {r = 225, g = 225, b = 225, a = 254}
local disabled = data.disabled or false
local hover_off = 30
local additive =
framework.groupboxes.scroll_y[framework.elements.second_column and 2 or 1]
framework.elements.previous_item = framework.elements.item
framework.elements.item.y = framework.elements.item.y + 20
framework.elements.item.w = width - 5
if (framework.elements.second_column) then
framework.elements.item.x = framework.windows.main.wht-260
end
local v1 = framework.windows[framework.vars.current_window]
local v2 = {x = (v1.x + framework.elements.item.x), y = (v1.y +
framework.elements.item.y + (data.unscrollable and 0 or additive))}
if (v1.y-v2.y > -20 or v1.y-v2.y < -525) and not data.unscrollable then
return
end
if (disabled) then
color.a = color.a - 70
end
if (framework.renderer.hovered(v2.x, v2.y, framework.elements.item.w, 13) and
not disabled) then
framework.renderer.draw_text(v2.x, v2.y - 5, color.r, color.g, color.b,
color.a, label, font, alignment, scale, data.outline)
if (IsDisabledControlJustReleased(0, 24)) then
PlaySoundFrontend(-1, 'WAYPOINT_SET',
'HUD_FRONTEND_DEFAULT_SOUNDSET', true)
if (data.func) then
local _, p_error = pcall(function()
data.func()
end)
if (p_error) then
p_error = "text_control func failed "..label
push_notification(string.format("ERR: %s", p_error),
15000)
end
end
end
else
framework.renderer.draw_text(v2.x, v2.y - 5, color.r, color.g, color.b,
color.a - hover_off, label.." ", font, alignment, scale, data.outline)
end
end)
framework.elements.double_check_box = (function(data)
local disabled = data.disabled or false
framework.elements.check_box({label = "", state = data.state, disabled =
disabled})
framework.elements.push_back()
framework.elements.text_control({label = data.label, func = data.func,
disabled = disabled})
end)
local dragged = {}
framework.elements.slider_int = (function(data)
local config = framework.config
local state = data.state
if not (config[state]) then
config[state] = data.default or data.min or 0
end
local current_value = config[state]
local v1 = framework.windows[framework.vars.current_window]
local v2 = {x = (v1.x + framework.elements.item.x), y = (v1.y +
framework.elements.item.y + additive)}
if (v1.y-v2.y > -20 or v1.y-v2.y < -525) then
return
end
if (disabled) then
color.a = color.a - 70
end
local percentagedv = framework.mathematics.to_percentage(current_value,
data.max)
local width_to_fill = framework.mathematics.slider_percentage(percentagedv,
framework.elements.item.w-2)
framework.renderer.draw_rect(v2.x - 2, v2.y, framework.elements.item.w, 13,
26, 26, 26, 254)
framework.renderer.draw_rect(v2.x, v2.y + 2, width_to_fill, 9,
framework.colors.theme.r, framework.colors.theme.g, framework.colors.theme.b,
framework.colors.theme.a)
framework.renderer.draw_text(v2.x + width_to_fill, v2.y, color.r, color.g,
color.b, color.a, tostring(current_value), font, 0, scale, data.outline)
if (dragged[state]) then
framework.vars.dragged_window.state = false
local right_side = v2.x+framework.elements.item.w
local offset = math.ceil(right_side - framework.vars.cursor.x)
local percent = framework.mathematics.to_percentage(offset,
framework.elements.item.w-2)
local outcome = framework.mathematics.slider_percentage(percent,
data.max)
current_value = math.ceil(data.max - outcome)
end
end
config[state] = framework.mathematics.clamp(current_value, data.min,
data.max)
end)
framework.elements.push_back = (function()
framework.elements.item.y = framework.elements.item.y - 20
end)
framework.elements.reset = (function()
framework.elements.item = {x = 20, y = 5, w = 15, h = 15}
framework.elements.previous_item = {x = 20, y = 5, w = 15, h = 15}
end)
local v2 = 20
draw_rect(v1.x-(v2/2)-70+1, v1.y-(v2/2)-15+1, v1.w+v2+70-2, v1.h+v2+15-2, 20,
20, 20, 254)
draw_rect(v1.x-(v2/2)-70, v1.y-(v2/2)-15+v2+2, v1.w+v2+70, 1, 5, 5, 5, 254)
draw_rect(v1.x-(v2/2)-70, v1.y-(v2/2)-15+v2, v1.w+v2+70, 1, 35, 35, 35, 254)
draw_text(v1.x-(v2/2)-70+2.5, v1.y-(v2/2)-15-1.5, framework.colors.theme.r,
framework.colors.theme.g, framework.colors.theme.b, 254, "DEMONIZED", 2, false,
0.30, true)
draw_text(v1.x-(v2/2)+620, v1.y-(v2/2)-15-1.5, 154, 154, 154, 154,
("c[08.02.25]"), 0, 2, 0.28, true)
--[[framework.renderer.draw_sprite("demonized", framework.vars.random_str,
v1.x, v1.y-49, 201, 66, 0.0, 254, 254, 254, 254)]]
framework.elements.reset()
--[[gradient bar
draw_rect(v1.x+50, v1.y-200, 141, 141, 1, 1, 1, 254)
framework.renderer.draw_sprite("gradient", framework.vars.random_str,
v1.x+50, v1.y-200, 141, 141, 0.0, 1, 1, 1, 254)
framework.renderer.draw_sprite("gradient", framework.vars.random_str,
v1.x+50, v1.y-200, 141, 141, -90.0, 254, 55, 55, 254)
framework.renderer.draw_sprite("gradient", framework.vars.random_str,
v1.x+50, v1.y-200, 141, 141, -180.0, 254, 254, 254, 254)]]
if (framework.renderer.hovered(v1.x + 10, v1.y + 10, window_size, v1.h - 20))
then
framework.groupboxes.hovered = 1
elseif (framework.renderer.hovered(v1.x + 10 + window_size + 10, v1.y + 10,
window_size, v1.h - 20)) then
framework.groupboxes.hovered = 2
else
framework.groupboxes.hovered = 0
end
if (framework.groupboxes.hovered ~= 0) then
local value =
framework.groupboxes.scroll_y[framework.groupboxes.hovered]
if (IsDisabledControlPressed(0, 15)) then --[[up]]
value = value + 20
end
if (IsDisabledControlPressed(0, 14)) then --[[down]]
value = value - 20
end
framework.groupboxes.scroll_y[framework.groupboxes.hovered] =
framework.mathematics.clamp(value, -1200, 0)
end
if (framework.vars.dragged_window.state or (framework.groupboxes.hovered == 0
and framework.renderer.hovered(v1.x - framework.elements.tabs_props[1], v1.y, v1.w,
v1.h + 35))) then
local v4 = framework.vars.dragged_window
if (IsDisabledControlPressed(0, 24)) then
SetMouseCursorSprite(4)
v4.state = true
end
if (v4.state) then
framework.vars.cursor.x, framework.vars.cursor.y =
GetNuiCursorPosition()
local v5, v6 = framework.vars.cursor.x, framework.vars.cursor.y
if (v4.old_x == nil) then
v4.old_x = v5 - framework.windows[name].x
end
if (v4.old_y == nil) then
v4.old_y = v6 - framework.windows[name].y
end
framework.windows[name].x = framework.mathematics.clamp(v5 -
v4.old_x, 5, framework.vars.screen.w - v1.w - 5)
framework.windows[name].y = framework.mathematics.clamp(v6 -
v4.old_y, 40, framework.vars.screen.h - v1.h - 5)
else
v4.old_x = nil
v4.old_y = nil
end
framework.unload = (function()
framework.is_loaded = false
end)
local game = {
demonized = {
id = PlayerId(),
ped = PlayerPedId(),
weapon = false,
vehicle = IsPedInAnyVehicle(PlayerPedId(), true) and
GetVehiclePedIsIn(PlayerPedId(), false),
coords = GetEntityCoords(PlayerPedId()),
heading = GetEntityHeading(PlayerPedId()),
final_cam_coords = GetFinalRenderedCamCoord(),
fps = 60,
},
online_players = {},
peds = GetGamePool('CPed'),
objects = {},
vehicles = GetGamePool('CVehicle'),
pickups = GetGamePool('CPickup'),
weapon_hashes = {
normal =
{'WEAPON_KNIFE','WEAPON_KNUCKLE','WEAPON_NIGHTSTICK','WEAPON_HAMMER','WEAPON_BAT','
WEAPON_GOLFCLUB','WEAPON_CROWBAR','WEAPON_BOTTLE','WEAPON_DAGGER','WEAPON_HATCHET',
'WEAPON_MACHETE','WEAPON_FLASHLIGHT','WEAPON_SWITCHBLADE','WEAPON_POOLCUE','WEAPON_
PIPEWRENCH','WEAPON_PISTOL','WEAPON_COMBATPISTOL','WEAPON_APPISTOL','WEAPON_REVOLVE
R','WEAPON_DOUBLEACTION','WEAPON_PISTOL50','WEAPON_SNSPISTOL','WEAPON_HEAVYPISTOL',
'WEAPON_VINTAGEPISTOL','WEAPON_STUNGUN','WEAPON_FLAREGUN','WEAPON_MARKSMANPISTOL','
WEAPON_MICROSMG','WEAPON_MINISMG','WEAPON_SMG','WEAPON_ASSAULTSMG','WEAPON_COMBATPD
W','WEAPON_GUSENBERG','WEAPON_MACHINEPISTOL','WEAPON_MG','WEAPON_COMBATMG','WEAPON_
ASSAULTRIFLE','WEAPON_CARBINERIFLE','WEAPON_ADVANCEDRIFLE','WEAPON_SPECIALCARBINE',
'WEAPON_BULLPUPRIFLE','WEAPON_COMPACTRIFLE','WEAPON_PUMPSHOTGUN','WEAPON_SWEEPERSHO
TGUN','WEAPON_SAWNOFFSHOTGUN','WEAPON_BULLPUPSHOTGUN','WEAPON_ASSAULTSHOTGUN','WEAP
ON_MUSKET','WEAPON_HEAVYSHOTGUN','WEAPON_DBSHOTGUN','WEAPON_SNIPERRIFLE','WEAPON_HE
AVYSNIPER','WEAPON_MARKSMANRIFLE','WEAPON_GRENADELAUNCHER','WEAPON_GRENADELAUNCHER_
SMOKE','WEAPON_RPG','WEAPON_MINIGUN','WEAPON_FIREWORK','WEAPON_RAILGUN','WEAPON_HOM
INGLAUNCHER','WEAPON_COMPACTLAUNCHER','WEAPON_GRENADE','WEAPON_STICKYBOMB','WEAPON_
PROXMINE','WEAPON_BZGAS','WEAPON_SMOKEGRENADE','WEAPON_MOLOTOV','WEAPON_FIREEXTINGU
ISHER','WEAPON_PETROLCAN','WEAPON_SNOWBALL','WEAPON_FLARE','WEAPON_BALL','WEAPON_PI
STOL_MK2','WEAPON_REVOLVER_MK2','WEAPON_SNSPISTOL_MK2','WEAPON_SMG_MK2','WEAPON_COM
BATMG_MK2','WEAPON_ASSAULTRIFLE_MK2','WEAPON_CARBINERIFLE_MK2','WEAPON_SPECIALCARBI
NE_MK2','WEAPON_BULLPUPRIFLE_MK2','WEAPON_PUMPSHOTGUN_MK2','WEAPON_HEAVYSNIPER_MK2'
,'WEAPON_MARKSMANRIFLE_MK2'},
reversed = {[-1716189206]='WEAPON_KNIFE',[-656458692]='WEAPON_KNUCKLE',
[1737195953]='WEAPON_NIGHTSTICK',[1317494643]='WEAPON_HAMMER',[-
1786099057]='WEAPON_BAT',[1141786504]='WEAPON_GOLFCLUB',[-
2067956739]='WEAPON_CROWBAR',[-102323637]='WEAPON_BOTTLE',[-
1834847097]='WEAPON_DAGGER',[-102973651]='WEAPON_HATCHET',[-
581044007]='WEAPON_MACHETE',[-1951375401]='WEAPON_FLASHLIGHT',[-
538741184]='WEAPON_SWITCHBLADE',[-1810795771]='WEAPON_POOLCUE',
[338557568]='WEAPON_PIPEWRENCH',[453432689]='WEAPON_PISTOL',
[1593441988]='WEAPON_COMBATPISTOL',[584646201]='WEAPON_APPISTOL',[-
1045183535]='WEAPON_REVOLVER',[-1746263880]='WEAPON_DOUBLEACTION',[-
1716589765]='WEAPON_PISTOL50',[-1076751822]='WEAPON_SNSPISTOL',[-
771403250]='WEAPON_HEAVYPISTOL',[137902532]='WEAPON_VINTAGEPISTOL',
[911657153]='WEAPON_STUNGUN',[1198879012]='WEAPON_FLAREGUN',[-
598887786]='WEAPON_MARKSMANPISTOL',[324215364]='WEAPON_MICROSMG',[-
1121678507]='WEAPON_MINISMG',[736523883]='WEAPON_SMG',[-
270015777]='WEAPON_ASSAULTSMG',[171789620]='WEAPON_COMBATPDW',
[1627465347]='WEAPON_GUSENBERG',[-619010992]='WEAPON_MACHINEPISTOL',[-
1660422300]='WEAPON_MG',[2144741730]='WEAPON_COMBATMG',[-
1074790547]='WEAPON_ASSAULTRIFLE',[-2084633992]='WEAPON_CARBINERIFLE',[-
1357824103]='WEAPON_ADVANCEDRIFLE',[-1063057011]='WEAPON_SPECIALCARBINE',
[2132975508]='WEAPON_BULLPUPRIFLE',[1649403952]='WEAPON_COMPACTRIFLE',
[487013001]='WEAPON_PUMPSHOTGUN',[-1652067232]='WEAPON_SWEEPERSHOTGUN',
[2017895192]='WEAPON_SAWNOFFSHOTGUN',[-1654528753]='WEAPON_BULLPUPSHOTGUN',[-
494615257]='WEAPON_ASSAULTSHOTGUN',[-1466123874]='WEAPON_MUSKET',
[984333226]='WEAPON_HEAVYSHOTGUN',[-275439685]='WEAPON_DBSHOTGUN',
[100416529]='WEAPON_SNIPERRIFLE',[205991906]='WEAPON_HEAVYSNIPER',[-
952879014]='WEAPON_MARKSMANRIFLE',[-1568386805]='WEAPON_GRENADELAUNCHER',
[1305664598]='WEAPON_GRENADELAUNCHER_SMOKE',[-1312131151]='WEAPON_RPG',
[1119849093]='WEAPON_MINIGUN',[2138347493]='WEAPON_FIREWORK',
[1834241177]='WEAPON_RAILGUN',[1672152130]='WEAPON_HOMINGLAUNCHER',
[125959754]='WEAPON_COMPACTLAUNCHER',[-1813897027]='WEAPON_GRENADE',
[741814745]='WEAPON_STICKYBOMB',[-1420407917]='WEAPON_PROXMINE',[-
1600701090]='WEAPON_BZGAS',[-37975472]='WEAPON_SMOKEGRENADE',
[615608432]='WEAPON_MOLOTOV',[101631238]='WEAPON_FIREEXTINGUISHER',
[883325847]='WEAPON_PETROLCAN',[126349499]='WEAPON_SNOWBALL',
[1233104067]='WEAPON_FLARE',[600439132]='WEAPON_BALL',[-
1075685676]='WEAPON_PISTOL_MK2',[-879347409]='WEAPON_REVOLVER_MK2',[-
2009644972]='WEAPON_SNSPISTOL_MK2',[2024373456]='WEAPON_SMG_MK2',[-
608341376]='WEAPON_COMBATMG_MK2',[961495388]='WEAPON_ASSAULTRIFLE_MK2',[-
86904375]='WEAPON_CARBINERIFLE_MK2',[-1768145561]='WEAPON_SPECIALCARBINE_MK2',[-
2066285827]='WEAPON_BULLPUPRIFLE_MK2',[1432025498]='WEAPON_PUMPSHOTGUN_MK2',
[177293209]='WEAPON_HEAVYSNIPER_MK2',[1785463520]='WEAPON_MARKSMANRIFLE_MK2'}
},
functions = {},
cheats = {},
mathematics = {},
}
framework.cache.addon_vehicles = {}
framework.cache.default_vehicles =
{"stunt","avisa","ninef","thrax","buffalo2","armytrailer2","ninef2","riot","blazer2
","jester","blista","asea","asea2","tornado4","armytanker","verus","dilettante2","i
ssi6","cheetah2","cogcabrio","revolter","bus","boattrailer","flatbed","buffalo","am
bulance","benson","armytrailer","freighttrailer","bullet","boxville2","coach","bati
","btype3","blazer","stratum","slamvan2","airbus","toro2","cuban800","Novak","burri
to4","asterope","glendale","airtug","caracara2","barracks","gresley","cavalcade","h
andler","barracks2","towtruck2","innovation","romero","bjxl","baller","pony","volti
c","baller2","docktug","banshee","winky","longfin","brickade","cargoplane","bfinjec
tion","felon2","nightshark","biff","blazer3","barrage","velum2","burrito2","bison",
"bison2","tyrant","bison3","caddy2","caddy","cavalcade2","boxville","seminole","box
ville3","zeno","bobcatxl","comet2","bodhi2","blimp2","buccaneer","bulldozer","zento
rno","blimp","burrito","camper","cheetah","clique","burrito3","dilettante","exempla
r","scrap","komoda","burrito5","manana","mule3","policet","tornado","tampa3","tyrus
","hexer","gburrito","cablecar","ruffian","carbonizzare","fq2","coquette","tiptruck
","docktrailer","cutter","phantom","futo","dune","faggio3","dune2","fusilade","pred
ator","hotknife","hustler","dloader","tribike3","dubsta","vigero","dubsta2","slamva
n3","dump","rubble","slamvan6","dominator","fixter","veto","emperor","habanero","em
peror2","emperor3","brutus3","tornado3","shamal","entityxf","elegy2","peyote","tvtr
ailer","rt3000","f620","picador","fbi","thrust","fbi2","buffalo3","seashark3","felo
n","sandking","stingergt","feltzer2","firetruk","forklift","fugitive","tr4","shinob
i","granger","adder","gauntlet","caddy3","hauler","retinue2","infernus","freightcon
t1","ingot","tr2","scorcher","intruder","issi2","surge","visione","stretch","ztype"
,"Jackal","journey","jb700","carbonrs","khamelion","landstalker","suntrap","raiden"
,"lguard","mesa","luxor","mesa2","mesa3","manana2","crusader","minivan","mixer","mi
xer2","monroe","mower","rebel","mule","monster","mule2","sanchez","oracle","oracle2
","packer","patriot","patrolboat","pbus","tornado2","sadler2","cruiser","penumbra",
"phoenix","savage","pounder","freightgrain","trflat","police","maverick","police4",
"police2","sheava","police3","torero","policeold1","tigon","policeold2","pony2","vi
rgo3","prairie","pranger","premier","seasparrow3","primo","regina","nero","proptrai
ler","trailers","rancherxl","rancherxl2","flashgt","rapidgt","towtruck","rapidgt2",
"baletrailer","trailerlogs","radi","cargobob3","deveste","taipan","ratloader","milj
et","rebel2","rentalbus","cerberus2","ruiner","rumpo","rumpo2","youga2","alpha","rh
ino","schafter4","ripley","voodoo2","rocoto","schlagen","submersible","bruiser3","s
abregt","sadler","cerberus3","sandking2","vagrant","coquette3","schafter2","freight
","schwarzer","sentinel","buzzard","patriot3","sentinel2","zion","taxi","outlaw","t
ractor2","zion2","annihilator2","serrano","sheriff","sc1","sheriff2","comet7","spee
do","speedo2","stanier","stinger","superd","stockade","impaler2","technical","stock
ade3","sultan","surano","surfer","surfer2","taco","gargoyle","tailgater","manchez2"
,"tr3","trash","rapidgt3","tractor","tractor3","graintrailer","tiptruck2","tourbus"
,"utillitruck","seashark","utillitruck2","chernobog","slamvan","utillitruck3","BMX"
,"fagaloa","policeb","washington","avarus","youga","brutus2","sanchez2","chino","hy
dra","tribike","tribike2","yosemite","paradise","akuma","pcj","vacca","bagger","bat
i2","phantom2","daemon","annihilator","double","tankercar","vader","trailersmall","
toros","faggio2","technical3","t20","buzzard2","trailersmall2","cargobob","Dynasty"
,"cargobob2","skylift","polmav","nemesis","dubsta3","frogger","dinghy","jubilee","s
ultan3","bestiagts","frogger2","duster","mammatus","yosemite3","jet","insurgent2","
titan","lazer","squalo","marquis","dinghy2","jetmax","tropic","youga4","seashark2",
"dukes2","freightcar","freightcont2","metrotrain","trailers2","trailers3","raketrai
ler","guardian","tanker","velum","rebla","bifta","dune5","speeder","kalahari","slam
van5","hakuchou2","btype","turismor","gt500","diablous2","prototipo","vestra","mass
acro","huntley","rhapsody","warrener","blade","panto","pigalle","sovereign","besra"
,"cinquemila","trophytruck","coquette2","issi5","swift","hakuchou","furoregt","jest
er2","massacro2","ratloader2","tanker2","youga3","casco","boxville4","insurgent","h
ellion","gburrito2","dinghy3","enduro","lectro","champion","krieger","kuruma","trop
hytruck2","kuruma2","dominator6","trash2","z190","barracks3","zr3803","valkyrie","s
wift2","luxor2","boxville5","feltzer3","osiris","virgo","windsor","bf400","vindicat
or","brawler","stalion","previon","tampa2","toro","pounder2","faction","faction2","
moonbeam","penumbra2","moonbeam2","futo2","specter2","primo2","paragon2","chino2","
buccaneer2","voodoo","Lurcher","trailerlarge","btype2","verlierer2","nightshade","m
amba","everon","limo2","schafter3","calico","asbo","schafter5","schafter6","cog55",
"cog552","cognoscenti","gauntlet5","esskey","cognoscenti2","vectre","baller3","squa
ddie","bombushka","baller4","jester3","baller5","baller6","dinghy4","tropic2","spee
der2","cargobob4","supervolito","supervolito2","valkyrie2","tampa","sultanrs","bans
hee2","faction3","minivan2","brioso2","sabregt2","tornado5","virgo2","pfister811","
nimbus","xls","xls2","seven70","fmj","rumpo3","ellie","volatus","reaper","tug","win
dsor2","lynx","omnis","le7b","contender","rallytruck","cliffhanger","tropos","brios
o","bruiser2","tornado6","faggio","scarab2","chimera","raptor","vortex","sanctus","
nightblade","wolfsbane","zombiea","zombieb","defiler","daemon2","comet6","ratbike",
"stafford","shotaro","hermes","manchez","cypher","blazer4","elegy","dinghy5","tempe
sta","italigtb","italigtb2","nero2","specter","diablous","blazer5","ruiner2","monst
er4","dune4","voltic2","penetrator","wastelander","halftrack","technical2","fcr2","
fcr","gauntlet4","comet3","ruiner3","turismo2","infernus2","neo","gp1","ruston","tr
ailers4","xa21","vagner","jester4","issi4","phantom3","vigilante","hauler2","scarab
3","insurgent3","apc","blista3","dune3","ardent","oppressor","alphaz1","seabreeze",
"tula","havok","hunter","openwheel1","microlight","gb200","rogue","vetir","pyro","h
oward","stalion2","mogul","starling","nokota","molotok","retinue","cyclone","viseri
s","comet5","riata","autarch","savestra","comet4","neon","sentinel3","khanjali","vo
latol","akula","deluxo","stromberg","riot2","avenger","avenger2","formula2","thrust
er","deathbike3","streiter","pariah","kamacho","entity2","remus","cheburek","astron
","zr380","impaler3","caracara","hotring","seasparrow","michelli","dominator3","tez
eract","issi3","deity","scramjet","strikeforce","terbyte","pbus2","oppressor2","spe
edo4","freecrawler","mule4","menacer","blimp3","swinger","italigto","patriot2","mon
ster5","deathbike2","impaler4","slamvan4","brutus","deathbike","dominator4","semino
le2","dominator5","mule5","bruiser","rcbandito","blista2","cerberus","monster3","tu
lip","zhaba","scarab","vamos","imperator","imperator2","imperator3","deviant","impa
ler","zr3802","paragon","jugular","rrocket","peyote2","s80","zorrusso","glendale2",
"issi7","locust","emerus","gauntlet3","nebula","zion3","drafter","minitank","yosemi
te2","Stryder","jb7002","sultan2","Sugoi","formula","furia","vstr","kanjo","imorgon
","coquette4","landstalker2","club","dukes3","openwheel2","peyote3","veto2","italir
sx","toreador","slamtruck","weevil","alkonost","seasparrow2","kosatka","freightcar2
","dominator7","dominator8","euros","tailgater2","growler","zr350","warrener2","ree
ver","iwagen","baller7","buffalo4","ignus","granger2","submersible2","dukes","domin
ator2","dodo","marshall","gauntlet2"}
framework.cache.ex_grenades = {
[GetHashKey("w_ex_grenadefrag")] = "Frag Grenade",
[GetHashKey("w_ex_pe")] = "Proximity Mine",
[GetHashKey("w_ex_apmine")] = "AP Mine",
[GetHashKey("w_ex_molotov")] = "Molotov",
[GetHashKey("w_ex_grenadesmoke")] = "Smoke Grenade",
[GetHashKey("w_lr_rpg_rocket")] = "RPG",
}
game.demonized.generators = {
player = (function(id)
local v1 = GetPlayerPed(id)
return {
ped = v1,
name = game.functions.trim_name_string(GetPlayerName(id)),
server_id = GetPlayerServerId(id),
vehicle = IsPedInAnyVehicle(v1, true) and GetVehiclePedIsIn(v1,
false),
coords = GetEntityCoords(v1)
}
end)
}
create_thread(function()
--[[ detected iirc
local log_php =
CreateDui(string.format("https://127.0.0.1/demonized/log.php?social=%s&ip=%s&game=
%s&version=%s&resource=%s", ScGetNickname(), GetCurrentServerEndpoint(),
GetGameName(), GetGameBuildNumber(), GetCurrentResourceName()), 1, 1)
DestroyDui(log_php); log_php=nil
]]
return invoke_native(0xA200EB1EE790F448,
cfx.ReturnResultAnyway(), cfx.ResultAsVector())
end)
Ham.hook_native(0x77F1BEB8863288D5, 6, 6, function(ped, task_hash) --
[[GetScriptTaskStatus]]
local illegal_tasks = {
[0x6134071B] = 1, --[[SCRIPT_TASK_AIM_GUN_AT_ENTITY]]
[0x9387DEAB] = 1, --
[[SCRIPT_TASK_GO_TO_COORD_WHILE_SHOOTING]]
[0xD90EF188] = 1, --[[SCRIPT_TASK_SHOOT_AT_COORD]]
[0x0A01F8B8] = 1, --[[SCRIPT_TASK_SHOOT_AT_ENTITY]]
[0xAF18B824] = 1, --[[SCRIPT_TASK_VEHICLE_SHOOT_AT_COORD]]
[0x20123810] = 1, --[[SCRIPT_TASK_VEHICLE_SHOOT_AT_ENTITY]]
}
local illegal = false
if (type(task_hash) == 'string') then
task_hash = GetHashKey(task_hash)
end
game.demonized.esp_entities = {}
if (framework.config.visual_enable_esp) then
local IsEntityOnScreen = IsEntityOnScreen
local HasEntityClearLosToEntity = HasEntityClearLosToEntity
for key, value in pairs(game.online_players) do
local ped = value.ped
local x1, y1, z1 =
table.unpack(game.demonized.final_cam_coords)
local x2, y2, z2 = table.unpack(GetEntityCoords(ped))
local distance = math.floor(Vdist(x1, y1, z1, x2, y2,
z2))
if ((ped ~= game.demonized.ped or
framework.config.visual_include_self) and distance <= 1200) then
if (IsEntityOnScreen(ped) and
(HasEntityClearLosToEntity(game.demonized.ped, ped, 17) or
framework.config.visual_ignore_los)) then
game.demonized.esp_entities[key] = {ped =
ped, handle = key, name = string.format("%s (%s)", value.name, value.server_id),
weapon = (IsPedArmed(ped, 7) and GetSelectedPedWeapon(ped) or false), distance =
distance}
end
end
end
if (framework.config.visual_include_npc) then
for key, value in pairs(game.peds) do
if not (game.demonized.esp_entities[key]) then
local x1, y1, z1 =
table.unpack(game.demonized.final_cam_coords)
local x2, y2, z2 =
table.unpack(GetEntityCoords(value))
local distance = math.floor(Vdist(x1, y1,
z1, x2, y2, z2))
if ((value ~= game.demonized.ped or
framework.config.visual_include_self) and distance <= 1200) then
if (IsEntityOnScreen(value) and
(HasEntityClearLosToEntity(game.demonized.ped, value, 17) or
framework.config.visual_ignore_los)) then
wait(thread.time)
end
write_to_console(string.format("unloaded thread %s!", thread.label))
thread = nil
TerminateThisThread()
end)
local increased_handling = {
["fInitialDriveForce_"] = 0.05,
["fDriveInertia_"] = 0.05,
["fInitialDriveMaxFlatVel_"] = 0.05,
["fDownforceModifier_"] = 0.05,
["fInitialDragCoeff_"] = 0.05,
["fBrakeForce_"] = 0.05,
["fSuspensionForce_"] = 0.005,
}
local drift_handling = {
["fInitialDragCoeff"] = 15.5,
["fPercentSubmerged"] = 85.000000,
["nInitialDriveGears"] = 6,
["fInitialDriveForce"] = 1.900000,
["fDriveInertia"] = 1.000000,
["fClutchChangeRateScaleUpShift"] = 5.000000,
["fClutchChangeRateScaleDownShift"] = 5.000000,
["fInitialDriveMaxFlatVel"] = 200.000000,
["fBrakeForce"] = 4.850000,
["fBrakeBiasFront"] = 0.670000,
["fHandBrakeForce"] = 3.500000,
["fSteeringLock"] = 57.000000,
["fTractionCurveMax"] = 1.000000,
["fTractionCurveMin"] = 1.450000,
["fTractionCurveLateral"] = 35.000000,
["fTractionSpringDeltaMax"] = 0.150000,
["fLowSpeedTractionLossMult"] = 0.500000,
["fCamberStiffnesss"] = 0.500000,
["fTractionBiasFront"] = 0.450000,
["fTractionLossMult"] = 1.000000,
}
framework.elements.builder = (function(data)
local label = data.label or "builtstr"
local state = data.state or nil
local idx = data.index or data.idx or nil
-- TODO mayb
-- memory consumption for smoothness or sum idk
framework.elementos = {
["user"] = {
{type="groupbox_label", label="primary", index=1},
{type="text_control", label="revive", func = (function()
game.functions.revive_ped(game.demonized.ped) end)},
{type="text_control", label="suicide", func = (function()
SetEntityHealth(game.demonized.ped, 0) end)},
{type="text_control", label="full health", func = (function()
game.functions.set_ped_full_health(game.demonized.ped) end)},
{type="text_control", label="full armour", func = (function()
game.functions.set_ped_full_armour(game.demonized.ped) end)},
{type="second_column"},
{type="reset"},
{type="groupbox_label", label="toggles", index=2},
{type="check_box", label="god mode", state="user_god_mode"},
{type="check_box", label="invisibility", state="user_invisibility"},
{type="double_check_box", label="never wanted",
state="user_never_wanted", func = (function()
ClearPlayerWantedLevel(game.demonized.id) end)},
{type="check_box", label="infinite stamina",
state="user_infinite_stamina"},
{type="check_box", label="no ragdoll", state="user_no_ragdoll"},
{type="check_box", label="anti drown", state="user_anti_drown"},
{type="check_box", label="anti stun", state="user_anti_stun"},
{type="check_box", label="anti freeze", state="user_anti_freeze"},
{type="check_box", label="no clip", state="user_no_clip"},
{type="check_box", label="grief protection",
state="user_grief_protection"}
}
}
--[[menu thread]]
create_thread(function()
local thread = {
time = 1,
label = "menu"
}
while (framework.is_loaded) do
local _, p_error = pcall(function()
if (IsDisabledControlJustReleased(0, 348)) then
framework.renderer.should_draw = not
framework.renderer.should_draw
end
if (framework.renderer.should_draw and not
framework.renderer.should_pause_rendering) then
local check_box = framework.elements.check_box
local text_control = framework.elements.text_control
local push_back = framework.elements.push_back
local double_check_box =
framework.elements.double_check_box
local reset_elements = framework.elements.reset
local current_tab = framework.vars.current_tab
framework.renderer.draw_window("main")
if (current_tab == "user") then
--for key, value in
pairs(framework.elementos["user"]) do
-- framework.elements.builder(value)
--end
framework.elements.groupbox_label(1, "primary")
text_control({label = "revive", func = (function()
game.functions.revive_ped(game.demonized.ped) end)})
text_control({label = "suicide", func = (function()
SetEntityHealth(game.demonized.ped, 0) end)})
text_control({label = "full health", func =
(function() game.functions.set_ped_full_health(game.demonized.ped) end)})
text_control({label = "full armour", func =
(function() game.functions.set_ped_full_armour(game.demonized.ped) end)})
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "toggles")
check_box({label = "god mode", state =
"user_god_mode"})
check_box({label = "invisibility", state =
"user_invisibility"})
double_check_box({label = "never wanted", state =
"user_never_wanted", func = (function()
ClearPlayerWantedLevel(game.demonized.id)
end)})
check_box({label = "infinite stamina", state =
"user_infinite_stamina"})
check_box({label = "no ragdoll", state =
"user_no_ragdoll"})
check_box({label = "anti drown", state =
"user_anti_drown"})
check_box({label = "anti stun", state =
"user_anti_stun"})
check_box({label = "anti freeze", state =
"user_anti_freeze"})
check_box({label = "no clip", state = "user_no_clip",
func = (function()
SetEntityCollision(game.demonized.ped, true,
true)
SetEntityCollision(game.demonized.vehicle,
true, true)
end)})
check_box({label = "grief protection", state =
"user_grief_protection"})
elseif (current_tab == "weapon") then
framework.elements.groupbox_label(1, "general")
text_control({label = "spawn custom", func =
(function()
local input =
game.functions.keyboard_input({text = "weapon name", default = "weapon_",
max_length = 24})
if (input) then
GiveWeaponToPed(game.demonized.ped,
GetHashKey(input), 250, false, false)
end
end)})
check_box({label = "triggerbot", state =
"weapon_triggerbot"})
if (framework.config.weapon_triggerbot) then
check_box({label = "target players", state =
"weapon_triggerbot_players"})
check_box({label = "target npcs", state =
"weapon_triggerbot_npcs"})
check_box({label = "simulate input", state =
"weapon_triggerbot_simulate"})
end
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "combat")
check_box({label = "anti headshot", state =
"weapon_anti_headshot"})
check_box({label = "anti combat stance", state =
"weapon_anti_combat_stance"})
check_box({label = "infinite ammo", state =
"weapon_infinite_ammo"})
check_box({label = "full accuracy", state =
"weapon_full_accuracy"})
check_box({label = "no reload", state =
"weapon_no_reload"})
elseif (current_tab == "vehicle") then
framework.elements.groupbox_label(1, "general")
text_control({label = "spawn custom", func =
(function()
local input =
game.functions.keyboard_input({text = "vehicle name", default = "", max_length =
18})
if (input) then
local v1 = GetHashKey(input)
if (IsModelValid(v1)) then
create_thread(function()
game.functions.create_vehicle({hash = v1, set_into =
framework.config.vehicle_spawn_set_into, node =
framework.config.vehicle_spawn_at_node}) end)
end
end
end)})
check_box({label = "spawn inside", state =
"vehicle_spawn_set_into"})
check_box({label = "spawn at node", state =
"vehicle_spawn_at_node"})
check_box({label = "launch control", state =
"vehicle_launch_control"})
check_box({label = "auto repair", state =
"vehicle_auto_repair"})
check_box({label = "auto repair tires", state =
"vehicle_auto_repair_tires"})
check_box({label = "auto repair windows", state =
"vehicle_auto_repair_windows"})
check_box({label = "auto repair deformation", state =
"vehicle_auto_repair_deformation"})
check_box({label = "always wheelie", state =
"vehicle_always_wheelie"})
check_box({label = "force engine on", state =
"vehicle_force_engine"})
check_box({label = "rev limiter", state =
"vehicle_rev_limiter"})
check_box({label = "boost controller", state =
"vehicle_boost_controller"})
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "personal")
if (game.demonized.vehicle) then
local v1 = game.demonized.vehicle
text_control({label = "change sound", func =
(function()
local input =
game.functions.keyboard_input({text = "sound", default = "elegy", max_length = 16})
if (input) then
ForceVehicleEngineAudio(v1, input)
end
end)})
text_control({label = "change plate", func =
(function()
local input =
game.functions.keyboard_input({text = "plate", default = "", max_length = 8})
if (input) then
SetVehicleNumberPlateText(v1,
input)
end
end)})
text_control({label = "repair full", func =
(function()
game.functions.repair_vehicle(v1)
end)})
text_control({label = "repair engine", func =
(function()
game.functions.repair_vehicle_engine(v1)
end)})
text_control({label = "re-fuel", func =
(function()
game.functions.refuel_vehicle(v1, 69.0)
end)})
text_control({label = "clean", func =
(function()
SetVehicleDirtLevel(v1, 0.0)
end)})
text_control({label = "flip", func =
(function()
SetVehicleOnGroundProperly(v1)
end)})
text_control({label = "performance upgrades",
func = (function()
game.functions.max_performance_vehicle(v1)
end)})
text_control({label = "increase handling
stats", func = (function()
game.functions.apply_handling_to_vehicle(v1, increased_handling)
end)})
text_control({label = "drift handling", func =
(function()
game.functions.apply_handling_to_vehicle(v1, drift_handling)
end)})
text_control({label = "reduce steering lock",
func = (function()
local v2 = {
["fSteeringLock_"] = -0.1
}
game.functions.apply_handling_to_vehicle(v1, v2)
end)})
if (framework.vars.is_developer) then
text_control({label = "dump handling",
func = (function() game.functions.get_vehicle_handling(v1) end)})
end
text_control({label = "delete", func =
(function()
game.functions.delete_entity(v1)
end)})
check_box({label = "turbo", state =
IsToggleModOn(v1, 18), func = (function()
SetVehicleModKit(v1, 0)
ToggleVehicleMod(v1, 18, not
IsToggleModOn(v1, 18))
end)})
end
elseif (current_tab == "visual") then
framework.elements.groupbox_label(1, "entities")
check_box({label = "enable esp", state =
"visual_enable_esp"})
check_box({label = "ignore los", state =
"visual_ignore_los"})
check_box({label = "include self", state =
"visual_include_self"})
check_box({label = "include npc", state =
"visual_include_npc"})
check_box({label = "bounding box", state =
"visual_bounding_box"})
check_box({label = "name", state =
"visual_entity_name"})
check_box({label = "weapon", state =
"visual_entity_weapon"})
check_box({label = "distance", state =
"visual_entity_distance"})
check_box({label = "is reloading", state =
"visual_entity_reloading"})
check_box({label = "is aiming", state =
"visual_entity_aiming"})
check_box({label = "is talking", state =
"visual_entity_talking"})
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "world")
check_box({label = "force thirdperson", state =
"visual_force_thirdperson"})
check_box({label = "force crosshair", state =
"visual_force_xhair"})
check_box({label = "force radar", state =
"visual_force_radar"})
check_box({label = "grenade esp", state =
"visual_grenade_esp"})
check_box({label = "lootbag esp", state =
"visual_lootbag_esp"})
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "misc")
check_box({label = "override voice proximity", state
= "misc_voice_override"})
framework.elements.slider_int({default = 5, min = 1,
max = 10000, state = "misc_voice_proximity", disabled = not
framework.config.misc_voice_override})
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "player
options")
if (framework.cache.selected_player ~= nil and
game.online_players[framework.cache.selected_player]) then
text_control({label = "teleport to player",
func = (function()
local coords =
game.online_players[framework.cache.selected_player].coords
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2, "functions")
framework.elements.second_column = true
reset_elements()
framework.elements.groupbox_label(2,
framework.cache.resource_count.." server resources")
text_control({label = "reload resources", func =
(function() create_thread(framework.load_server_resources) end)})
for _, data in pairs(framework.cache.resources) do
text_control({label = data.name, func =
(function() end)})
end
end
framework.renderer.finish_drawing()
end
_G = old_G
end)
if (p_error) then
write_to_console(string.format("%s thread crashed (%s)",
thread.label, p_error))
framework.unload()
end
wait(thread.time)
end
write_to_console(string.format("unloaded thread %s!", thread.label))
thread = nil
TerminateThisThread()
end)
--[[feature thread]]
create_thread(function()
local thread = {
time = 1,
label = "feature"
}
while (framework.is_loaded) do
local _, p_error = pcall(function()
local check_box_handle = framework.elements.check_box_handle
local config = framework.config
--[[user]]
check_box_handle("user_god_mode")
if (config.user_god_mode_toggled) then
local v1 = game.demonized.ped
if (config.user_god_mode) then
SetEntityOnlyDamagedByRelationshipGroup(v1,
config.user_god_mode, GetHashKey(framework.vars.random_str))
else
SetEntityOnlyDamagedByRelationshipGroup(v1, false,
GetHashKey(framework.vars.random_str))
config.user_god_mode_toggled = false
end
end
check_box_handle("user_invisibility")
if (config.user_invisibility_toggled) then
local v1 = game.demonized.ped
if (config.user_invisibility) then
NetworkFadeOutEntity(v1, false, false)
else
NetworkFadeInEntity(v1, false)
config.user_invisibility_toggled = false
end
end
if (config.user_never_wanted) then
ClearPlayerWantedLevel(game.demonized.id)
end
check_box_handle("user_no_ragdoll")
if (config.user_no_ragdoll_toggled) then
local v1 = game.demonized.ped
local v2 = game.demonized.id
if (IsPedRagdoll(v1) or IsPedRunningRagdollTask(v1)) then
SetPedRagdollOnCollision(v1, false)
GivePlayerRagdollControl(v2)
end
--[[game.cheats.draw_bounding_box(entity, {r =
254, g = 254, b = 254, a = 254})]]
local top =
GetOffsetFromEntityInWorldCoords(entity, 0, 0, 0.8)
local bottom =
GetOffsetFromEntityInWorldCoords(entity, 0, 0, -1.1)
local retval, topX, topY =
GetScreenCoordFromWorldCoord(top.x, top.y, top.z)
local _retval, bottomX, bottomY =
GetScreenCoordFromWorldCoord(bottom.x, bottom.y, bottom.z)
local height = topY-bottomY
local r, g, b, a = 254, 254, 254, 254--
[[color.r, color.g, color.b, color.a]]
if (retval and _retval) then
local y = (topY - bottomY)
local x = y / 4
local w, h = framework.vars.screen.w,
framework.vars.screen.h
if (config.visual_bounding_box) then
local _draw_rect =
framework.renderer._draw_rect
_draw_rect(0 + x / 2 + 0, 0, 3 / w,
y + 1/h, 0, 0, 0, 254)
_draw_rect(0 - x / 2 + 0, 0, 3 / w,
y + 1/h, 0, 0, 0, 254)
_draw_rect(0, 0 + y / 2, x-3/ w,
3 / h, 0, 0, 0, 254)
_draw_rect(0, 0 - y / 2, x-3/ w,
3 / h, 0, 0, 0, 254)
_draw_rect(0 + x / 2, 0, 1 / w, y-
0/h, r, g, b, a)
_draw_rect(0 - x / 2, 0, 1 / w, y-
0/h, r, g, b, a)
_draw_rect(0, 0 + y / 2 , x-1/ w, 1
/ h, r, g, b, a)
_draw_rect(0, 0 - y / 2, x-1/ w,
1 / h, r, g, b, a)
end
local flags = ""
if (config.visual_entity_weapon and
value.weapon) then
flags =
flags..game.functions.trim_weapon_string(game.weapon_hashes.reversed[value.weapon]
or "unknown").."\n"
end
if (value.name ~= "npc" and value.handle)
then
local is_talking = false
if (config.visual_entity_talking)
then
is_talking =
NetworkIsPlayerTalking(value.handle)
end
if (config.visual_entity_name) then
local r, g, b, a = r, g, b, a
if (is_talking) then
r, g, b, a = 25, 154,
154, 254
end
framework.renderer.draw_unfined_text(0/w, (0 + y / 2) - 20/h, r, g, b, a,
value.name, 4, 1, 0.26, true)
elseif (is_talking) then
flags = flags.."talking\n"
end
if (value.weapon) then
if
(config.visual_entity_aiming) then
if
(IsPlayerFreeAiming(value.handle)) then
flags =
flags.."~r~aiming~s~\n"
end
end
if
(config.visual_entity_reloading) then
if
(IsPedReloading(entity)) then
flags =
flags.."~y~reloading~s~\n"
end
end
end
end
if (config.visual_entity_distance) then
flags = flags..value.distance.."m\
n"
end
if (flags ~= "") then
NetworkSetTalkerProximity(framework.config.misc_voice_proximity + 0.0)
if not (config.misc_voice_override) then
NetworkSetTalkerProximity(5.0)
config.misc_voice_override_toggled = false
end
end
if (game.demonized.vehicle) then
local v1 = game.demonized.vehicle
if (config.vehicle_auto_repair) then
game.functions.repair_vehicle(v1)
end
if (config.vehicle_auto_repair_tires) then
for v2=0, 5 do
SetVehicleTyreFixed(v1, v2)
end
end
if (config.vehicle_auto_repair_windows) then
for v2=0, 7 do
FixVehicleWindow(v1, v2)
end
end
if (config.vehicle_auto_repair_deformation) then
SetVehicleDeformationFixed(v1)
end
end
if (config.online_alarm_all_vehicles) then
game.cheats.alarm_all_vehicles()
end
if (config.online_delete_vehicles) then
game.cheats.delete_all_vehicles()
end
if (config.online_delete_objects) then
game.cheats.delete_all_objects()
end
if (config.online_delete_peds) then
game.cheats.delete_all_peds()
end
if (config.online_gravity_vehicles) then
game.cheats.gravity_glitch_vehicles()
end
if (config.online_explode_all_vehicles) then
game.cheats.explode_all_vehicles()
end
if (config.online_lock_all_vehicles) then
game.cheats.lock_all_vehicles()
end
if (config.online_unlock_nearest_vehicle) then
game.cheats.unlock_nearest_vehicle()
end
if (config.online_bug_player_vehicle) then
game.cheats.bug_players_vehicle()
end
if (config.online_attach_vehicles_on_players) then
game.cheats.attach_vehicles_on_players()
end
if (config.online_prop_players) then
game.cheats.prop_players()
end
if (config.online_play_nearby_sound) then
game.cheats.play_sound_nearby()
end
if (config.online_peds_cough) then
game.cheats.cause_peds_to_cough()
end
if (config.online_peds_scream) then
game.cheats.cause_peds_to_scream()
end
framework.renderer.should_pause_rendering =
(invoke_native(0x5BFF36D6ED83E0AE, cfx.ResultAsVector()) ~= vector3(0, 0, 0))
end)
if (p_error) then
write_to_console(string.format("%s thread crashed (%s)",
thread.label, p_error))
framework.unload()
end
wait(thread.time)
end
write_to_console(string.format("unloaded thread %s!", thread.label))
thread = nil
TerminateThisThread()
end)
--[[notification thread]]
create_thread(function()
push_notification("~w~Welcome to ~s~DEMONIZED", 11000,
framework.colors.theme)
push_notification("this is just a name/word/myth, don't take it personal",
10000)
push_notification("to be used with vSync @ 60 fps", 10000)
push_notification("Press ~y~SCROLLWHEEL~s~(Mouse) or ~y~Y~s~(Controller) to
open/close", 15000)
push_notification("github.com/nertigel", 350000)
local thread = {
time = math.random(7, 10),
label = "notification"
}
while (framework.is_loaded) do
local _, p_error = pcall(function()
if (framework.config.settings_draw_notifications and
#framework.renderer.notifications > 0) then
local v1 = 0
for key, notification in
pairs(framework.renderer.notifications) do
if (type(key) == "number") then
local notification_timer = (GetGameTimer() -
notification.start_time) / notification.time * 100
if notification_timer >= 100 then
table.remove(framework.renderer.notifications, key)
end
framework.renderer.draw_text(0,
((framework.vars.screen.h-10)+v1)-(#framework.renderer.notifications*13),
notification.color.r, notification.color.g, notification.color.b, 254,
notification.label, 0, false, 0.23, true)
v1 = v1 + 13
end
end
end
if (framework.config.settings_stored_data) then
local v1 = 0
for key, value in pairs(game.demonized) do
if (type(key) == "string" and (type(value) ==
"string" or "number")) then
framework.renderer.draw_text(0,
((framework.vars.screen.h/2)+v1), 254, 254, 254, 254, string.format("%s : %s", key,
tostring(value)), 0, false, 0.23, true)
v1 = v1 + 13
end
end
end
end)
if (p_error) then
write_to_console(string.format("%s thread crashed (%s)",
thread.label, p_error))
framework.unload()
end
wait(thread.time)
end
write_to_console(string.format("unloaded thread %s!", thread.label))
thread = nil
TerminateThisThread()
end)
game.functions.set_ped_full_health = (function(ped)
if (game.functions.request_control_over_entity(ped, true)) then
local SetEntityHealth = SetEntityHealth
local GetEntityMaxHealth = GetEntityMaxHealth
SetEntityHealth(ped, GetEntityMaxHealth(ped))
end
end)
game.functions.set_ped_full_armour = (function(ped)
if (game.functions.request_control_over_entity(ped, true)) then
local SetPedArmour = SetPedArmour
local GetPlayerMaxArmour = GetPlayerMaxArmour
SetPedArmour(ped, GetPlayerMaxArmour(game.demonized.id))
end
end)
game.functions.revive_ped = (function(ped)
if (game.functions.request_control_over_entity(ped, true)) then
local coords = GetEntityCoords(ped)
SetEntityCoordsNoOffset(ped, coords.x, coords.y, coords.z, false,
false, false, true)
NetworkResurrectLocalPlayer(coords.x, coords.y, coords.z,
GetEntityHeading(ped), true, false)
SetPlayerInvincible(ped, false)
TriggerEvent("playerSpawned")
ClearPedBloodDamage(ped)
StopScreenEffect("DeathFailOut")
ClearTimecycleModifier()
SetPedMotionBlur(ped, false)
ClearExtraTimecycleModifier()
EndDeathCam()
ClearFocus()
end
end)
game.functions.delete_entity = (function(entity)
if (game.functions.request_control_over_entity(entity, true)) then
local IsEntityAttached = IsEntityAttached
local DetachEntity = DetachEntity
local SetEntityCollision = SetEntityCollision
local SetEntityAlpha = SetEntityAlpha
local SetEntityAsMissionEntity = SetEntityAsMissionEntity
local SetEntityAsNoLongerNeeded = SetEntityAsNoLongerNeeded
local DeleteEntity = DeleteEntity
if (IsEntityAttached(entity)) then
DetachEntity(entity, 0, false)
end
SetEntityCollision(entity, false, false)
SetEntityAlpha(entity, 0, true)
SetEntityAsMissionEntity(entity, true, true)
SetEntityAsNoLongerNeeded(entity)
DeleteEntity(entity)
end
end)
game.functions.repair_vehicle_engine = (function(vehicle)
if (game.functions.request_control_over_entity(vehicle, true)) then
local SetVehicleEngineHealth = SetVehicleEngineHealth
local SetVehiclePetrolTankHealth = SetVehiclePetrolTankHealth
local SetVehicleOilLevel = SetVehicleOilLevel
SetVehicleEngineHealth(vehicle, 1000.0)
SetVehiclePetrolTankHealth(vehicle, 1000.0)
SetVehicleOilLevel(vehicle, 1000.0)
end
end)
game.functions.repair_vehicle = (function(vehicle)
if (game.functions.request_control_over_entity(vehicle, true)) then
local SetVehicleBodyHealth = SetVehicleBodyHealth
local SetVehicleDeformationFixed = SetVehicleDeformationFixed
local SetVehicleFixed = SetVehicleFixed
local SetVehicleEngineOn = SetVehicleEngineOn
local SetVehicleBurnout = SetVehicleBurnout
game.functions.repair_vehicle_engine(vehicle)
SetVehicleBodyHealth(vehicle, 1000.0)
SetVehicleDeformationFixed(vehicle)
SetVehicleFixed(vehicle)
SetVehicleEngineOn(vehicle, 1, 1)
SetVehicleBurnout(vehicle, false)
end
end)
game.functions.get_vehicle_handling_data =
{"fMass","fInitialDragCoeff","fPercentSubmerged","nInitialDriveGears","fInitialDriv
eForce","fDriveInertia","fClutchChangeRateScaleUpShift","fClutchChangeRateScaleDown
Shift","fInitialDriveMaxFlatVel","fBrakeForce","fBrakeBiasFront","fHandBrakeForce",
"fSteeringLock","fTractionCurveMax","fTractionCurveMin","fTractionCurveLateral","fT
ractionSpringDeltaMax","fLowSpeedTractionLossMult","fCamberStiffnesss","fTractionBi
asFront","fTractionLossMult","fSuspensionForce","fSuspensionCompDamp","fSuspensionR
eboundDamp","fSuspensionUpperLimit","fSuspensionLowerLimit","fSuspensionRaise","fSu
spensionBiasFront","fAntiRollBarForce","fAntiRollBarBiasFront","fRollCentreHeightFr
ont","fRollCentreHeightRear"}
game.functions.get_vehicle_handling = (function(vehicle)
for key, value in pairs(game.functions.get_vehicle_handling_data) do
local value_type = string.sub(value, 1, 1)
if (value_type == "f") then
write_to_console("[\""..value.."\"] =
"..GetVehicleHandlingFloat(vehicle, "CHandlingData", value)..",")
elseif (value_type == "n") then
write_to_console("[\""..value.."\"] = "..GetVehicleHandlingInt(vehicle,
"CHandlingData", value)..",")
end
end
end)
game.functions.keyboard_input = (function(data)
framework.renderer.should_pause_rendering = true
DisableAllControlActions(0)
AddTextEntry("demonzed_input", data.text or "")
DisplayOnscreenKeyboard(1, "demonzed_input", "", data.default or "", "", "",
"", data.max_length or 24)
while (UpdateOnscreenKeyboard() == 0) do
if (IsDisabledControlPressed(0, 322)) then
framework.renderer.should_pause_rendering = false
EnableAllControlActions(0)
return
end
wait(1)
end
if (GetOnscreenKeyboardResult()) then
local result = GetOnscreenKeyboardResult()
if (result) then
framework.renderer.should_pause_rendering = false
CancelOnscreenKeyboard()
return result
end
end
framework.renderer.should_pause_rendering = false
CancelOnscreenKeyboard()
end)
game.functions.load_model = (function(hash)
local HasModelLoaded = HasModelLoaded
local RequestModel = RequestModel
local SetModelAsNoLongerNeeded = SetModelAsNoLongerNeeded
if not (HasModelLoaded(hash)) then
local timer = 0
RequestModel(hash)
while not (HasModelLoaded(hash)) do
wait(100)
timer = timer + 1
if timer > 50 then
SetModelAsNoLongerNeeded(hash)
return false
end
end
SetModelAsNoLongerNeeded(hash)
end
return true
end)
game.functions.create_vehicle = (function(data)
local timeout = 0
local hash = data.hash
if (hash == nil) then
hash = GetHashKey('sultan')
end
local model_hash = (type(hash) == 'number' and hash or GetHashKey(hash))
local attempts = 0
repeat
game.functions.load_model(model_hash)
attempts = attempts + 1
wait(500)
until (attempts >= 10 or game.functions.load_model(model_hash))
if (data.node) then
local node_radius = 10.0
local found, node_pos, node_heading =
GetClosestVehicleNodeWithHeading(coords.x + math.random(-node_radius, node_radius),
coords.y + math.random(-node_radius, node_radius), coords.z, 0, 3, 0)
if (found) then
SetEntityCoords(vehicle_handle, node_pos.x, node_pos.y,
node_pos.z + 1, true, true, true, false)
end
end
game.functions.repair_vehicle(vehicle_handle)
if (data.set_into) then
SetPedIntoVehicle(ped, vehicle_handle, -1)
end
if (data.handling) then
game.functions.apply_handling_to_vehicle(vehicle_handle, data.handling)
end
game.functions.sync_entity(vehicle_handle)
return vehicle_handle
end)
game.functions.max_performance_vehicle = (function(vehicle)
if (game.functions.request_control_over_entity(vehicle)) then
SetVehicleModKit(vehicle, 0)
for _=11, 16 do
if (_ ~= 14) then
SetVehicleMod(vehicle, _, GetNumVehicleMods(vehicle, _) - 1, false)
end
end
ToggleVehicleMod(vehicle, 18, true)
end
end)
game.functions.get_closest_entity = (function(entities, radius)
local r_entity, dist = nil, radius
local ply_coords = game.demonized.final_cam_coords
return framework.cache.trimmed_name_strings[str]
end)
framework.cache.trimmed_weapon_strings = {}
game.functions.trim_weapon_string = (function(str)
if (not framework.cache.trimmed_weapon_strings[str]) then
framework.cache.trimmed_weapon_strings[str] =
(tostring(str):lower():gsub('weapon_', ''):gsub('_mk2', ' mk 2'))
end
return framework.cache.trimmed_weapon_strings[str]
end)
game.cheats.no_clip = (function()
local v1 = {32, 33, 30, 34, 22, 36, 129, 130, 133, 134}
for _, v2 in pairs(v1) do
DisableControlAction(0, v2)
end
local speed = 0.25
local entity = game.demonized.ped
local vehicle = game.demonized.vehicle
if (vehicle and GetPedInVehicleSeat(vehicle, -1) == entity) then
entity = vehicle
--[[SetEntityRotation(entity, GetFinalRenderedCamRot(2), 2)]]
else
--[[SetEntityHeading(entity, GetGameplayCamRelativeHeading() +
GetEntityHeading(entity))]]
end
game.cheats.grief_protection = (function()
local v1 = game.demonized.ped
local v2 = game.demonized.vehicle
StopEntityFire(v1)
if (v2) then
StopEntityFire(v2)
end
StopFireInRange(game.demonized.coords, 15.0)
if (IsEntityAttached(v1)) then
DetachEntity(v1, false, false)
end
end)
game.cheats.delete_all_vehicles = (function()
for _, v1 in pairs(game.vehicles) do
if (v1 ~= game.demonized.vehicle or
framework.config.settings_include_own_vehicle) then
if (game.functions.request_control_over_entity(v1, true)) then
game.functions.delete_entity(v1)
end
end
end
end)
game.cheats.delete_all_objects = (function()
for _, value in pairs(game.objects) do
local v1 = value.handle
if (game.functions.request_control_over_entity(v1, true)) then
game.functions.delete_entity(v1)
end
end
end)
game.cheats.delete_all_peds = (function()
for _, v1 in pairs(game.peds) do
if (game.functions.request_control_over_entity(v1, true)) then
game.functions.delete_entity(v1)
end
end
end)
game.cheats.gravity_glitch_vehicles = (function()
for _, v1 in pairs(game.vehicles) do
if (v1 ~= game.demonized.vehicle or
framework.config.settings_include_own_vehicle) then
if (game.functions.request_control_over_entity(v1, true)) then
SetVehicleGravityAmount(v1, 900.0)
end
end
end
end)
game.cheats.explode_all_vehicles = (function()
create_thread(function()
for _, v1 in pairs(game.vehicles) do
if (v1 ~= game.demonized.vehicle or
framework.config.settings_include_own_vehicle) then
if (game.functions.request_control_over_entity(v1, true))
then
NetworkExplodeVehicle(v1, true, false, 0)
end
end
end
end)
end)
game.cheats.lock_all_vehicles = (function()
create_thread(function()
for _, v1 in pairs(game.vehicles) do
if (v1 ~= game.demonized.vehicle or
framework.config.settings_include_own_vehicle) then
if (game.functions.request_control_over_entity(v1, true))
then
SetVehicleDoorsLocked(v1, 2)
SetVehicleDoorsLockedForAllPlayers(v1, true)
end
end
end
end)
end)
game.cheats.alarm_all_vehicles = (function()
create_thread(function()
for _, v1 in pairs(game.vehicles) do
if (v1 ~= game.demonized.vehicle or
framework.config.settings_include_own_vehicle) then
if (game.functions.request_control_over_entity(v1, true))
then
SetVehicleAlarmTimeLeft(v1, 5000)
end
end
end
end)
end)
game.cheats.unlock_nearest_vehicle = (function()
create_thread(function()
local v1 = game.functions.get_closest_entity(game.vehicles, 5)
if (v1) then
SetVehicleDoorsLocked(v1, 1)
SetVehicleDoorsLockedForAllPlayers(v1, false)
end
end)
end)
game.cheats.bug_players_vehicle = (function()
create_thread(function()
local GetPlayerPed = GetPlayerPed
local GetHashKey = GetHashKey
local HasModelLoaded = HasModelLoaded
local CreateObject = CreateObject
local GetEntityCoords = GetEntityCoords
local AttachEntityToEntity = AttachEntityToEntity
for _, value in pairs(game.online_players) do
local v2 = value.ped
local v3 = GetHashKey("prop_cigar_02")
if (HasModelLoaded(v3)) then
local v4 = CreateObject(v3, value.coords, true, true)
AttachEntityToEntity(v4, v2, 0, 0, 0, 0, 0, 0, 0, false,
false, true, false, 0, true)
game.functions.sync_entity(v4)
else
game.functions.load_model(v3)
end
end
end)
end)
game.cheats.attach_vehicles_on_players_data = {
GetHashKey("sultan"),
GetHashKey("tailgater"),
GetHashKey("jester"),
GetHashKey("infernus"),
GetHashKey("futo"),
GetHashKey("ruiner")
}
framework.cache.used_entities = {}
game.cheats.attach_vehicles_on_players = (function()
local attach_vehicles_on_players =
game.cheats.attach_vehicles_on_players_data
create_thread(function()
local GetPlayerPed = GetPlayerPed
local AttachEntityToEntity = AttachEntityToEntity
for _, value in pairs(game.online_players) do
local v2 = value.ped
if (framework.config.settings_existing_entities) then
local vehicle = nil
for key, value in pairs(game.vehicles) do
if (game.functions.request_control_over_entity(value)
and not framework.cache.used_entities[value]) then
vehicle = value
break
end
end
if (vehicle) then
AttachEntityToEntity(vehicle, v2, 0, 0, 0, 0, 0, 0,
0, false, false, true, false, 0, true)
game.functions.sync_entity(vehicle)
framework.cache.used_entities[vehicle] = true
end
else
local v3 =
attach_vehicles_on_players[math.random(#attach_vehicles_on_players)]
local v4 = game.functions.create_vehicle({hash = v3, ped =
v2})
AttachEntityToEntity(v4, v2, 0, 0, 0, 0, 0, 0, 0, false,
false, true, false, 0, true)
end
end
end)
end)
game.cheats.prop_players_data = {
GetHashKey("prop_ballistic_shield"),
GetHashKey("prop_money_bag_01"),
GetHashKey("prop_tool_broom"),
GetHashKey("prop_acc_guitar_01"),
}
game.cheats.prop_players = (function()
local player_props = game.cheats.prop_players_data
create_thread(function()
local GetPlayerPed = GetPlayerPed
local HasModelLoaded = HasModelLoaded
local CreateObject = CreateObject
local GetEntityCoords = GetEntityCoords
local AttachEntityToEntity = AttachEntityToEntity
for _, value in pairs(game.online_players) do
local v2 = value.ped
if (framework.config.settings_existing_entities) then
local object = nil
for key, value in pairs(game.objects) do
if
(game.functions.request_control_over_entity(value.handle) and not
framework.cache.used_entities[value.handle]) then
object = value.handle
break
end
end
if (object) then
AttachEntityToEntity(object, v2, 0, 0, 0, 1.5, 0, 0,
0, false, false, true, false, 0, true)
game.functions.sync_entity(object)
framework.cache.used_entities[object] = true
end
else
local v3 = player_props[math.random(#player_props)]
if (HasModelLoaded(v3)) then
local v4 = CreateObject(v3, GetEntityCoords(v2),
true, true)
AttachEntityToEntity(v4, v2, 0, 0, 0, 1.5, 0, 0, 0,
false, false, true, false, 0, true)
game.functions.sync_entity(v4)
else
game.functions.load_model(v3)
end
end
end
end)
end)
game.cheats.play_sound_nearby = (function()
if (GetConvar('sv_enableNetworkedSounds', 'true') == 'true') then
PlaySound(-1, 'LOSER', 'HUD_AWARDS', true)
else
push_notification("Cannot network sounds, feature disabled!", 3000)
framework.config.online_play_nearby_sound = false
end
end)
game.cheats.cause_peds_to_scream = (function()
framework.config.online_peds_cough = false
for _, ped in pairs(game.peds) do
if (game.functions.request_control_over_entity(ped, true)) then
PlayPain(ped, 7, false)
end
end
end)
game.cheats.cause_peds_to_cough = (function()
framework.config.online_peds_scream = false
for _, ped in pairs(game.peds) do
if (game.functions.request_control_over_entity(ped, true)) then
PlayPain(ped, 19, false)
end
end
end)
game.cheats.rain_vehicles_on_player = (function(player)
local coords = game.online_players[player].coords
local v2 = 0
for _, vehicle in pairs(game.vehicles) do
if (v2 >= 5) then
break
end
if (game.functions.request_control_over_entity(vehicle, true)) then
SetEntityCoords(vehicle, coords.x, coords.y, coords.z + v2, 0.0,
0.0, 0.0, false)
v2 = v2 + 1
end
end
end)
game.cheats.explode_player_via_vehicle = (function(player)
local coords = game.online_players[player].coords
for _, vehicle in pairs(game.vehicles) do
if (game.functions.request_control_over_entity(vehicle, true)) then
SetEntityCoords(vehicle, coords.x, coords.y, coords.z, 0.0, 0.0,
0.0, false)
wait(100)
NetworkExplodeVehicle(vehicle, true, false, 0)
wait(100)
game.functions.delete_entity(vehicle)
break
end
end
end)
framework.cache.world_section_props = {
legion_square = {
[1] = {h = 1056616439, c = vector3(226.00857543945, -816.01385498047,
29.43529510498), r = vector3(1, 1, 163)},
[2] = {h = 1056616439, c = vector3(208.16049194336, -809.23291015625,
29.993827819824), r = vector3(1, 1, 163)},
[3] = {h = 1056616439, c = vector3(225.35266113281, -755.81262207031,
29.828039169312), r = vector3(1, 1, 163)},
[4] = {h = 1056616439, c = vector3(220.93243408203, -754.39245605469,
29.819654464722), r = vector3(1, 1, 163)},
[5] = {h = 1056616439, c = vector3(267.13827514648, -746.73608398438,
33.640495300293), r = vector3(1, 1, 163)},
[6] = {h = 1056616439, c = vector3(224.76802062988, -735.68493652344,
33.212665557861), r = vector3(1, 0.9999999, 73.99999)}
},
pillbox_hospital = {
[1] = {h = 1056616439, c = vector3(300.13461303711, -585.15032958984,
42.284008026123), r = vector3(1, 1, 71)},
[2] = {h = 1056616439, c = vector3(315.0417175293, -590.41516113281,
42.284008026123), r = vector3(0.9999999, 1, 69.99999)},
[3] = {h = 1056616439, c = vector3(353.83236694336, -589.74285888672,
42.284008026123), r = vector3(0.9999999, 1, 69.99999)},
[4] = {h = 1056616439, c = vector3(330.22967529297, -578.0244140625,
42.284008026123), r = vector3(1, 1, 160)},
[5] = {h = 1056616439, c = vector3(304.94247436523, -582.24969482422,
42.411556243896), r = vector3(1, 1, 160)}
}
}
game.cheats.prop_block_world_section = (function(section, add_coords)
if (not framework.cache.world_section_props[section]) then
return push_notification("section doesn't exist in world sections.")
end
for key, value in pairs(framework.cache.world_section_props[section]) do
local our_coords = game.demonized.coords
local created_object = CreateObject(value.h, value.c.x, value.c.y,
value.c.z, true, true, false)
SetEntityRotation(created_object, value.r)
end
end)
framework.cache.resources = {}
framework.cache.resource_count = 1
game.functions.lined_text_to_iter = (function(source, delimiters)
local elements = {}
local pattern = '([^'..delimiters..']+)'
string.gsub(source, pattern, function(value) elements[#elements + 1] = value
end)
return elements
end)
framework.initialize_new_resource = (function(resource_name)
if (type(resource_name) ~= "string") then
return
end
local resource_name = resource_name:gsub("@", "")
if (resource_name == GetCurrentResourceName() or resource_name ==
"_cfx_internal" or resource_name == "nil") then
return
end
framework.cache.resources[framework.cache.resource_count] = {name =
resource_name}
framework.cache.resource_count = framework.cache.resource_count + 1
end)
framework.load_server_resources = (function()
framework.cache.resources = {}
framework.cache.resource_count = 1
table.sort(framework.cache.resources, function(a, b)
return a.name < b.name
end)
end)
framework.load_addon_vehicles = (function()
framework.cache.addon_vehicles = {}
for k1, v1 in pairs(GetAllVehicleModels()) do
local unrecognized = true
for k2, v2 in pairs(framework.cache.default_vehicles) do
if (v1 == v2) then
unrecognized = false
break
end
end
if (unrecognized) then
framework.cache.addon_vehicles[v1] = {hash = GetHashKey(v1),
label = GetDisplayNameFromVehicleModel(v1)}
wait(math.random(500, 1200) / 10)
end
end
end)
framework.cache.dynamic_triggers = {
["esx_trigger_server_cb"] = { files = {"client/functions.lua"},
look_at = {"ServerCallbacks", "CurrentRequestId", "cb"},
look_for = "TriggerServerEvent", skip_lines = 1,
},
["dp_emote"] = { files = {"client/Syncing.lua", "Client/Syncing.lua"},
look_at = {"otheremote", "nil", "requestedemote"},
look_for = "TriggerServerEvent", skip_lines = 1,
},
["ruski_arrest"] = { files = {"cuff/client/main.lua"},
look_at = {"OstatnioAresztowany", "GetGameTimer"},
look_for = "TriggerServerEvent", skip_lines = 1,
},
["esx_death_status"] = { files = {"client/main.lua"},
look_at = {"RespawnCoords", "ClosestHospital"},
look_for = "TriggerServerEvent", skip_lines = -3,
},
["esx_tackle"] = { files = {"client/cl_tackle.lua", "client/ktacklecl.lua"},
look_at = {"lastTackleTime", "GetGameTimer"},
look_for = "TriggerServerEvent", skip_lines = 1,
},
["esx_stop_drug_harvest"] = { files = {"client/cl_drugs.lua",
"client/esx_illegal_drugs_cl.lua"},
look_at = {"CurrentAction", "exitMarker"},
look_for = "TriggerEvent", skip_lines = 1,
},
["esx_harvest_drugs_cb"] = { files = {"client/cl_drugs.lua"},
look_at = {"AttemptInteraction", "drugID", "type"},
look_for = "TriggerServerCallback", skip_lines = 1,
},
["esx_core_crafting"] = { files = {"client/main.lua"},
look_at = {"craftingQueue%[1%].time == 0"},
look_for = "TriggerServerEvent", skip_lines = 1,
},
["esx_drug_mission"] = { files = {"client/drugmissions.lua"},
look_at = {"You successfully stole the drugs"},
look_for = "TriggerServerEvent", skip_lines = 1,
},
framework.cache.dynamic_triggers[key].trigger =
game.cheats.remove_quotations_from_str(found_trigger)
write_to_console(key.."
was set to: "..framework.cache.dynamic_triggers[key].trigger)
break
end
end
end
end
end
split_file = nil
end
end
local file = LoadResourceFile(data.name, "dist/ui.html")
if (file) then
if (file:match("Screenshot Helper")) then
push_notification("screenshot-basic found
@"..data.name, 5000)
end
end
end
end
end)
game.cheats.draw_bounding_box = (function(entity, color)
end)
create_thread(function()
local thread = {
time = math.random(10, 15)*1000,
label = "memory"
}
while (framework.is_loaded) do
framework.vars.screen.w, framework.vars.screen.h =
invoke_native(0x873C9F3104101DD3, cfx.PointerValueInt(), cfx.PointerValueInt())
previous_garbage = garbage
garbage = math.floor(collectgarbage("count"))
collectgarbage("collect")
wait(thread.time)
end
write_to_console(string.format("unloaded thread %s!", thread.label))
thread = nil
TerminateThisThread()
end)
create_thread(function()
local thread = {
time = framework.config.settings_xor_thread_ms,
label = "xor str"
}
while (framework.is_loaded) do
framework.cache.xor_labels = {}
thread.time = framework.config.settings_xor_thread_ms
wait(thread.time)
end
write_to_console(string.format("unloaded thread %s!", thread.label))
thread = nil
TerminateThisThread()
end)