Oceanic.lua

local render_world_to_screen, rage_exploit, ui_get_binds, ui_get_alpha, entity_get_players, entity_get, entity_get_entities, entity_get_game_rules, common_set_clan_tag, common_is_button_down, common_get_username, common_get_date, ffi_cast, ffi_typeof, render_gradient, render_text, render_texture, render_rect_outline, render_rect, entity_get_local_player, ui_create, ui_get_style, math_floor, math_abs, math_max, math_ceil, math_min, math_random, utils_trace_bullet, render_screen_size, render_load_font, render_load_image_from_file, render_measure_text, render_poly, render_poly_blur, common_add_notify, common_add_event, utils_console_exec, utils_execute_after, utils_create_interface, utils_trace_line, ui_find, entity_get_threat, string_format, hooked_function, entity_get_player_resource, common_get_unixtime, table_insert = render.world_to_screen, rage.exploit, ui.get_binds, ui.get_alpha, entity.get_players, entity.get, entity.get_entities, entity.get_game_rules, common.set_clan_tag, common.is_button_down, common.get_username, common.get_date, ffi.cast, ffi.typeof, render.gradient, render.text, render.texture, render.rect_outline, render.rect, entity.get_local_player, ui.create, ui.get_style, math.floor, math.abs, math.max, math.ceil, math.min, math.random, utils.trace_bullet, render.screen_size, render.load_font, render.load_image_from_file, render.measure_text, render.poly, render.poly_blur, common.add_notify, common.add_event, utils.console_exec, utils.execute_after, utils.create_interface, utils.trace_line, ui.find, entity.get_threat, string.format, nil, entity.get_player_resource, common.get_unixtime, table.insert
local clipboard = require ‘neverlose/clipboard’
local base64 = require ‘neverlose/base64’
local drag_system = require ‘neverlose/drag_system’
local smoothy = require ‘neverlose/smoothy’
local get_defensive = require ‘neverlose/get_defensive’
local md5 = require ‘neverlose/md5’
local inspect = require ‘neverlose/inspect’
local events = require ‘neverlose/events’
local table_clear = require ‘table.clear’
_DEBUG = true

ffi.cdef[[
typedef void*(__thiscall* get_client_entity_t)(void*, int);

typedef struct {
    char  pad_0000[20];
    int m_nOrder; //0x0014
    int m_nSequence; //0x0018
    float m_flPrevCycle; //0x001C
    float m_flWeight; //0x0020
    float m_flWeightDeltaRate; //0x0024
    float m_flPlaybackRate; //0x0028
    float m_flCycle; //0x002C
    void *m_pOwner; //0x0030
    char  pad_0038[4]; //0x0034
} c_animlayers;

]]

local function this_call(call_function, parameters) return function(…) return call_function(parameters, …) end end
local function gradient_textz(r1, g1, b1, a1, r2, g2, b2, a2, text) local output = ‘’ local len = #text-1 local rinc = (r2 - r1) / len local ginc = (g2 - g1) / len local binc = (b2 - b1) / len local ainc = (a2 - a1) / len for i=1, len+1 do output = output … (‘\a%02x%02x%02x%02x%s’):format(r1, g1, b1, a1, text:sub(i, i)) r1 = r1 + rinc g1 = g1 + ginc b1 = b1 + binc a1 = a1 + ainc end return output end
local clamp = function(b,c,d)local e=b;e=e<c and c or e;e=e>d and d or e;return e end
function lerp(time,a,b) return a * (1-time) + b * time end
function contains(table, element) for i = 1, #table do if table[i] == element then return true end end end
local ifHashed = function(tbl, val) for n,v in pairs(tbl) do if val == v then return true end end return false end

files.create_folder(“nl/scripts/”)
local entity_list_003 = ffi.cast(ffi.typeof(“uintptr_t**”), utils.create_interface(“client.dll”, “VClientEntityList003”))
local get_entity_address = this_call(ffi.cast(“get_client_entity_t”, entity_list_003[0][3]), entity_list_003)
local engine_client = ffi.cast(ffi.typeof(‘void***’), utils.create_interface(‘engine.dll’, ‘VEngineClient014’))
local console_is_visible = ffi.cast(ffi.typeof(‘bool(__thiscall*)(void*)’), engine_client[0][11])
local font, verdana = render.load_font(‘Calibri Bold’, vector(25, 22, -1), ‘a, d’), render.load_font(“Verdana”, 20, ‘a’)
ui.find(“Miscellaneous”, “Main”, “Other”, “Weapon Actions”):set(‘Quick Switch’, ‘Auto Pistols’)
local current = ui.find(“Miscellaneous”, “Main”, “Other”, “Weapon Actions”):get()
local active_color, color_link = ui_get_style(‘Link Active’):to_hex(), ui_get_style(‘Link’):to_hex()
local anim_tbl, easing_table = {}, smoothy.new(anim_tbl)
local hitlog, modify = {}, {}
local disabled_windows, windows_table = {}, {}
check_windows = function() windows_table = {} for i = 1, 4 do if (ui.find(“Miscellaneous”, “Main”, “Other”, “Windows”):get()[i] ~= nil) and not contains(disabled_windows, ui.find(“Miscellaneous”, “Main”, “Other”, “Windows”):get()[i]) then table.insert(windows_table, ui.find(“Miscellaneous”, “Main”, “Other”, “Windows”):get()[i]) end end ui.find(“Miscellaneous”, “Main”, “Other”, “Windows”):set(windows_table) end

modify.math_breathe = function(offset, multiplier) return math.abs(math.sin(globals.realtime * (multiplier or 1) % math.pi + (offset or 0))) end
modify.typing_text = function(s, callback) num, length = 0, #s:gsub(‘[\128-\191]’, ‘’) result = ‘’ for char in s:gmatch(‘.[\128-\191]*’) do num = num + 1 factor = num / length result = string_format(‘%s\a%s%s’, result, callback(num, length, char, factor):to_hex(), char) end return result end
modify.gradient_text = function(s, a, b) return modify.typing_text(s, function(num, length, char, factor) return a:lerp(b, factor) end) end
modify.gradient = function(s, a, b, t) return modify.typing_text(s, function(num, length, char, factor) interpolation = modify.math_breathe(factor, t) return a:lerp(b, interpolation) end) end
modify.static_gradient = function(s, clr1, clr2) return modify.gradient_text(s, clr1, clr2) end

local render_interpolate_string = function(name, position, font, text_color, flags, …)
local text = table.concat({…})

if anim_tbl[name] == nil then
    anim_tbl[name] = 0
    easing_table = smoothy.new(anim_tbl)
end

local text_size = easing_table(.1, { [name] = render.measure_text(font, nil, ...)})[name]

local normal_size = render.measure_text(font, nil, ...)

render.push_clip_rect(vector(position.x - normal_size.x, position.y - text_size.y/2), vector(position.x + text_size.x/2, position.y + text_size.y/2), true)
render.text(font, vector(position.x - text_size.x/2, position.y - text_size.y/2), text_color, flags, ...)
render.pop_clip_rect()

end

local function get_type(value)
if type(getmetatable(value)) == ‘table’ and value.__type then
return value.__type.name:lower()
end

if type(value) == 'boolean' then
    value = value and 1 or 0
end

return type(value)

end

local ctx = new_class()
:struct ‘cheat’ {
screen_size = render_screen_size(),
version = ‘Nightly’,
username = common_get_username(),
}

:struct 'impt' {
    play_sound = function(name , volume)
        local IEngineSoundClient = ffi_cast("void***" , utils_create_interface("engine.dll", "IEngineSoundClient003")) or error("Failed to find IEngineSoundClient003!")
        local play_sound_fn = ffi_cast("void(__thiscall*)(void*, const char*, float, int, int, float)",IEngineSoundClient[0][12])

        return play_sound_fn( IEngineSoundClient, name , volume , 100 ,0,0)
    end