LUA скрипт [nixware] Skeet dmg indicator

life is cheap, death is free!
Эксперт
Статус
Оффлайн
Регистрация
9 Дек 2019
Сообщения
1,603
Реакции[?]
517
Поинты[?]
2K
я мазохист, так что держите (я не нашёл другого нормального получения названия оружия без ебли)
Код:
function engine.get_weapon_name()
    local weapon = {
        [196650] = "Knifes", -- CT
        [196667] = "Knifes", -- T
        [197108] = "Knifes", -- Bayonet
        [197113] = "Knifes", -- Flip
        [197114] = "Knifes", -- Gut
        [197115] = "Knifes", -- Karambit
        [197116] = "Knifes", -- M9 bayonet
        [197117] = "Knifes", -- Huntsman
        [197118] = "Knifes", -- Falchion
        [197119] = "Knifes", -- Bowie
        [197120] = "Knifes", -- Butterfly
        [197121] = "Knifes", -- Shadow daggers
        [197122] = "Knifes", -- Ursus
        [197123] = "Knifes", -- Navaja
        [197124] = "Knifes", -- Stiletto
        [197125] = "Knifes", -- Talon
        [197126] = "Knifes", -- CSS
        [197127] = "Knifes", -- Paracord
        [197128] = "Knifes", -- Survival
        [197129] = "Knifes", -- Nomad
        [197133] = "Knifes", -- Skeleton

        [589828] = "Pistols",
        [4] = "Pistols",-- Glock-18
        [589827] = "Pistols",
        [3] = "Pistols",-- Five-SeveN
        [589860] = "Pistols",
        [36] = "Pistols",-- P250
        [589854] = "Pistols",
        [30] = "Pistols",-- Tec-9
        [589887] = "Pistols",
        [63] = "Pistols",-- CZ75-Auto
        [589826] = "Pistols",
        [2] = "Pistols",-- Dual Berettas
        [589856] = "Pistols",
        [32] = "Pistols",-- P2000
        [589885] = "Pistols",
        [262205] = "Pistols",
        [61] = "Pistols",-- USP-S

        [589825] = "Deagle",
        [1] = "Deagle",-- Desert Eagle
        [589888] = "Revolver",
        [262208] = "Revolver",
        [64] = "Revolver",-- Revolver

        [589841] = "Smg",
        [17] = "Smg",-- Mac-10
        [589857] = "Smg",
        [33] = "Smg",-- MP7
        [589858] = "Smg",
        [34] = "Smg",-- MP9
        [589850] = "Smg",
        [26] = "Smg",-- Bizon
        [589843] = "Smg",
        [19] = "Smg",-- P90
        [589848] = "Smg",
        [24] = "Smg",-- UMP-45
        [589847] = "Smg",
        [262167] = "Smg",
        [23] = "Smg",-- MP5-SD

        [589831] = "Rifle",
        [7] = "Rifle",-- AK-47
        [589840] = "Rifle",
        [16] = "Rifle",-- M4A4
        [589884] = "Rifle",
        [60] = "Rifle",-- M4A1-S
        [589837] = "Rifle",
        [13] = "Rifle",-- Galil
        [589834] = "Rifle",
        [10] = "Rifle",-- Famas
        [589832] = "Rifle",
        [8] = "Rifle",-- AUG
        [589863] = "Rifle",
        [39] = "Rifle",-- SG-553
        [589852] = "Rifle",
        [28] = "Rifle",-- Negev
        [589838] = "Rifle",
        [14] = "Rifle",-- M249

        [589851] = "Shotguns",
        [27] = "Shotguns",-- Mag-7
        [589859] = "Shotguns",
        [35] = "Shotguns",-- Nova
        [589853] = "Shotguns",
        [29] = "Shotguns",-- Sawed-Off
        [589849] = "Shotguns",
        [25] = "Shotguns",-- XM1014

        [589864] = "Scout",
        [40] = "Scout",-- Scout

        [589835] = "Auto",
        [11] = "Auto",-- G3SG1
        [589862] = "Auto",
        [38] = "Auto",-- Scar-20

        [589833] = "AWP",
        [9] = "AWP",-- AWP

        [31] = "Taser",
    }
    return weapon[entitylist.get_entity_from_handle(entitylist.get_local_player():get_prop_int(0x2F08)):get_prop_int(0x2FBA)]
end
function entitylist.get_enemies(is_alive, indexes)
            is_alive, indexes = is_alive or true, indexes or false
            local ents = entitylist.get_players(0)
            local enemies = {}
            for i = 1, #ents do if is_alive and ents[i]:is_alive() or true then
                table.insert(enemies, indexes and ents[i]:get_index() or ents[i]) end end
            return enemies
        end
function entitylist.for_enemies(fn, is_alive, indexes)
    local ents = entitylist.get_enemies(is_alive, indexes)
    for i = 1, #ents do fn(ents[i]) end
end
mindmg = ui.add_key_bind("Minimum damage", "mindmg_ind", 0, 1)
minval = ui.add_slider_int("Minimum damage", "mindmg_slid", 0, 100, 1)
client.register_callback("create_move", function ()
    if not mindmg:is_active() then return end
    local dmg = minval:get_value()
    entitylist.for_enemies(function(i) ragebot.override_min_damage(i, dmg) end, true, true)
end)
local screen = engine.get_screen_size()
local pixel = renderer.setup_font("C:/windows/fonts/smallest_pixel-7.ttf", 9, 0)
client.register_callback("paint", function ()
    if not entitylist.get_local_player() or not entitylist.get_local_player():is_alive() then return end
    local variable = not engine.get_weapon_name() or engine.get_weapon_name() == "Knifes"
    local text = variable and "DYNAMIC" or (mindmg:is_active() and tostring(minval:get_value()) or tostring(ui.get_slider_int("rage_".. engine.get_weapon_name():lower() .."_min_damage"):get_value()))
    renderer.text(text, pixel, vec2_t.new(screen.x / 2 + 20, screen.y / 2 - 15), 9, color_t.new(255, 255, 255, 255))
end)
 

Вложения

Последнее редактирование:
Забаненный
Статус
Оффлайн
Регистрация
20 Фев 2022
Сообщения
149
Реакции[?]
41
Поинты[?]
0
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
ХЫАХЫВХЫВАХЫВАХ
 
life is cheap, death is free!
Эксперт
Статус
Оффлайн
Регистрация
9 Дек 2019
Сообщения
1,603
Реакции[?]
517
Поинты[?]
2K
Извините за неудобство, пофиксил недостаток функции
 
Сверху Снизу