Краш

Leon_Trotsky

Участник
Автор темы
39
2
Версия MoonLoader
.026-beta
Приветствую всех. Столкнулся с крашем. Крашит без сообщений в логе


Код окна:

Lua:
if menusel.v == 9 then
            imgui.BeginChild("ChildWindow15", imgui.ImVec2(-1, -1), true)
            imgui.Text(u8'Бинд принятия:')
            imgui.SameLine()
            imadd.HotKey('##123123123', facceptform, {}, 100)
            imgui.SameLine()
            imgui.Text(fa.ICON_FA_QUESTION_CIRCLE..u8'')
            imgui.Hint('bindformi', u8'Кнопка принятия формы из админ-чата')
            if imgui.ToggleButton(u8'Оповещение в админ чат по принятию формы', imgui.ImBool(cfg.main.formaplus)) then
                cfg.main.formaplus = not cfg.main.formaplus
            end
            imgui.Separator()
            imgui.CenterText(fa.ICON_FA_BELL..u8' Звуковое оповещение '..fa.ICON_FA_BELL)
            imgui.NewLine()
            if imgui.ToggleButton(u8'Звуковое оповещение при получении форм', imgui.ImBool(cfg.main.formbell)) then
                cfg.main.formbell = not cfg.main.formbell
            end
            imgui.Text(u8'Название звукового файла:')
            imgui.SameLine()
            imgui.PushItemWidth(100)
            imgui.InputText(u8"##1", nameaudio)
            cfg.main.nameaudioforform = string.format('%s', tostring(nameaudio.v))
            imgui.PopItemWidth()
            imgui.Text(u8'Громкость оповещения:')
            imgui.SameLine()
            imgui.PushItemWidth(100)
            imgui.SliderInt("##sadjsad", volume, 0, 100)
            imgui.PopItemWidth()
            cfg.main.volume = volume.v
            kotofeevformi()
            imgui.EndChild()   
        end

"kotofeevformi"

Lua:
function kotofeevformi()
    imgui.NewLine()
    imgui.Separator()
    imgui.TextColoredRGB('{E78284}*Р {84A6E7}- принимать вручную\n{E78284}*А{84A6E7} - принимать автоматически\n{E78284}*З{84A6E7} - звуковое оповещение')
    imgui.BeginChild("ChildWin1231233dow", imgui.ImVec2(140, 1065), true)
    imgui.CenterText(u8'Команда')
    imgui.Separator()
    imgui.Button(u8'/kick', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/mute', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/jail', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/jailoff', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/sethp', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/sban', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/banoff', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/muteoff', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/sbanoff', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/spplayer', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/slap', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/unmute', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/unjail', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/spcar', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/ban', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/warn', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/skick', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/ao', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/unban', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/unwarn', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/banip', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/offban', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/offwarn', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/ptp', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/o', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/aad', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/givegun', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/avig', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/aunvig', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/setadmin', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/spawncars', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/givedonate', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/mpwin', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/prefix', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/asellhouse', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/delacc', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/asellbiz', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/money', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/test', imgui.ImVec2(-1, 20))
    imgui.Button(u8'/ans', imgui.ImVec2(-1, 20))
    imgui.EndChild()
    imgui.SameLine()
    imgui.BeginChild("ChildWin123123s3dow", imgui.ImVec2(40, 1065), true)
    imgui.CenterText(u8'P')
    imgui.Separator()
    
    if imgui.Checkbox('##kick', forma_kick) then cfg.formssettings.forma_kick = forma_kick.v end
    if imgui.Checkbox('##mute', forma_mute) then cfg.formssettings.forma_mute = forma_mute.v end
    if imgui.Checkbox('##jail', forma_jail) then cfg.formssettings.forma_jail = forma_jail.v end
    if imgui.Checkbox('##jailoff', forma_jailoff) then cfg.formssettings.forma_jailoff = forma_jailoff.v end
    if imgui.Checkbox('##sethp', forma_sethp) then cfg.formssettings.forma_sethp = forma_sethp.v end
    if imgui.Checkbox('##sban', forma_sban) then cfg.formssettings.forma_sban = forma_sban.v end
    if imgui.Checkbox('##banoff', forma_banoff) then cfg.formssettings.forma_banoff = forma_banoff.v end
    if imgui.Checkbox('##muteoff', forma_muteoff) then cfg.formssettings.forma_muteoff = forma_muteoff.v end
    if imgui.Checkbox('##sbanoff', forma_sbanoff) then cfg.formssettings.forma_sbanoff = forma_sbanoff.v end   
    if imgui.Checkbox('##spplayer', forma_spplayer) then cfg.formssettings.forma_spplayer = forma_spplayer.v end
    if imgui.Checkbox('##slap', forma_slap) then cfg.formssettings.forma_slap = forma_slap.v end   
    if imgui.Checkbox('##unmute', forma_unmute) then cfg.formssettings.forma_unmute = forma_unmute.v end
    if imgui.Checkbox('##unjail', forma_unjail) then cfg.formssettings.forma_unjail = forma_unjail.v end
    if imgui.Checkbox('##spcar', forma_spcar) then cfg.formssettings.forma_spcar = forma_spcar.v end   
    if imgui.Checkbox('##ban', forma_ban) then cfg.formssettings.forma_ban = forma_ban.v end
    if imgui.Checkbox('##warn', forma_warn) then cfg.formssettings.forma_warn = forma_warn.v end   
    if imgui.Checkbox('##skick', forma_skick) then cfg.formssettings.forma_skick = forma_skick.v end   
    if imgui.Checkbox('##ao', forma_sao) then cfg.formssettings.forma_ao = forma_ao.v end
    if imgui.Checkbox('##unban', forma_unban) then cfg.formssettings.forma_unban = forma_unban.v end   
    if imgui.Checkbox('##unwarn', forma_unwarn) then cfg.formssettings.forma_unwarn = forma_unwarn.v end
    if imgui.Checkbox('##banip', forma_banip) then cfg.formssettings.forma_banip = forma_banip.v end
    if imgui.Checkbox('##offban', forma_offban) then cfg.formssettings.forma_offban = forma_offban.v end
    if imgui.Checkbox('##offwarn', forma_offwarn) then cfg.formssettings.forma_offwarn = forma_offwarn.v end   
    if imgui.Checkbox('##ptp', forma_ptp) then cfg.formssettings.forma_ptp = forma_ptp.v end   
    if imgui.Checkbox('##o', forma_o) then cfg.formssettings.forma_o = forma_o.v end   
    if imgui.Checkbox('##aad', forma_aad) then cfg.formssettings.forma_aad = forma_aad.v end   
    if imgui.Checkbox('##givegun', forma_givegun) then cfg.formssettings.forma_givegun = forma_givegun.v end   
    if imgui.Checkbox('##avig', forma_avig) then cfg.formssettings.forma_avig = forma_avig.v end   
    if imgui.Checkbox('##aunvig', forma_aunvig) then cfg.formssettings.forma_aunvig = forma_aunvig.v end
    if imgui.Checkbox('##setadmin', forma_setadmin) then cfg.formssettings.forma_setadmin = forma_setadmin.v end   
    if imgui.Checkbox('##spawncars', forma_spawncars) then cfg.formssettings.forma_spawncars = forma_spawncars.v end
    if imgui.Checkbox('##givedonate', forma_givedonate) then cfg.formssettings.forma_givedonate = forma_givedonate.v end   
    if imgui.Checkbox('##mpwin', forma_mpwin) then cfg.formssettings.forma_mpwin = forma_mpwin.v end   
    if imgui.Checkbox('##prefix', forma_prefix) then cfg.formssettings.forma_prefix = forma_prefix.v end   
    if imgui.Checkbox('##asellhouse', forma_asellhouse) then cfg.formssettings.forma_asellhouse = forma_asellhouse.v end   
    if imgui.Checkbox('##delacc', forma_delacc) then cfg.formssettings.forma_delacc = forma_delacc.v end   
    if imgui.Checkbox('##asellbiz', forma_asellbiz) then cfg.formssettings.forma_asellbiz = forma_asellbiz.v end
    if imgui.Checkbox('##money', forma_money) then cfg.formssettings.forma_money = forma_money.v end   
    if imgui.Checkbox('##test', forma_test) then cfg.formssettings.forma_test = forma_test.v end
    if imgui.Checkbox('##ans', forma_ans) then cfg.formssettings.forma_ans = forma_ans.v end
 
    imgui.EndChild()
    imgui.SameLine()
    imgui.BeginChild("ChildWin123123s3dow2", imgui.ImVec2(40, 1065), true)
    imgui.CenterText(u8'A')
    imgui.Separator()
 
    if imgui.Checkbox('##kick', autoforma_kick) then cfg.formssettings.autoforma_kick = autoforma_kick.v end
    if imgui.Checkbox('##mute', autoforma_mute) then cfg.formssettings.autoforma_mute = autoforma_mute.v end
    if imgui.Checkbox('##jail', autoforma_jail) then cfg.formssettings.autoforma_jail = autoforma_jail.v end
    if imgui.Checkbox('##jailoff', autoforma_jailoff) then cfg.formssettings.autoforma_jailoff = autoforma_jailoff.v end
    if imgui.Checkbox('##sethp', autoforma_sethp) then cfg.formssettings.autoforma_sethp = autoforma_sethp.v end
    if imgui.Checkbox('##sban', autoforma_sban) then cfg.formssettings.autoforma_sban = autoforma_sban.v end
    if imgui.Checkbox('##banoff', autoforma_banoff) then cfg.formssettings.autoforma_banoff = autoforma_banoff.v end
    if imgui.Checkbox('##muteoff', autoforma_muteoff) then cfg.formssettings.autoforma_muteoff = autoforma_muteoff.v end
    if imgui.Checkbox('##sbanoff', autoforma_sbanoff) then cfg.formssettings.autoforma_sbanoff = autoforma_sbanoff.v end   
    if imgui.Checkbox('##spplayer', autoforma_spplayer) then cfg.formssettings.autoforma_spplayer = autoforma_spplayer.v end
    if imgui.Checkbox('##slap', autoforma_slap) then cfg.formssettings.autoforma_slap = autoforma_slap.v end   
    if imgui.Checkbox('##unmute', autoforma_unmute) then cfg.formssettings.autoforma_unmute = autoforma_unmute.v end
    if imgui.Checkbox('##unjail', autoforma_unjail) then cfg.formssettings.autoforma_unjail = autoforma_unjail.v end
    if imgui.Checkbox('##spcar', autoforma_spcar) then cfg.formssettings.autoforma_spcar = autoforma_spcar.v end   
    if imgui.Checkbox('##ban', autoforma_ban) then cfg.formssettings.autoforma_ban = autoforma_ban.v end
    if imgui.Checkbox('##warn', autoforma_warn) then cfg.formssettings.autoforma_warn = autoforma_warn.v end   
    if imgui.Checkbox('##skick', autoforma_skick) then cfg.formssettings.autoforma_skick = autoforma_skick.v end   
    if imgui.Checkbox('##ao', autoforma_sao) then cfg.formssettings.autoforma_ao = autoforma_ao.v end
    if imgui.Checkbox('##unban', autoforma_unban) then cfg.formssettings.autoforma_unban = autoforma_unban.v end   
    if imgui.Checkbox('##unwarn', autoforma_unwarn) then cfg.formssettings.autoforma_unwarn = autoforma_unwarn.v end
    if imgui.Checkbox('##banip', autoforma_banip) then cfg.formssettings.autoforma_banip = autoforma_banip.v end
    if imgui.Checkbox('##offban', autoforma_offban) then cfg.formssettings.autoforma_offban = autoforma_offban.v end
    if imgui.Checkbox('##offwarn', autoforma_offwarn) then cfg.formssettings.autoforma_offwarn = autoforma_offwarn.v end   
    if imgui.Checkbox('##ptp', autoforma_ptp) then cfg.formssettings.autoforma_ptp = autoforma_ptp.v end   
    if imgui.Checkbox('##o', autoforma_o) then cfg.formssettings.autoforma_o = autoforma_o.v end   
    if imgui.Checkbox('##aad', autoforma_aad) then cfg.formssettings.autoforma_aad = autoforma_aad.v end   
    if imgui.Checkbox('##givegun', autoforma_givegun) then cfg.formssettings.autoforma_givegun = autoforma_givegun.v end   
    if imgui.Checkbox('##avig', autoforma_avig) then cfg.formssettings.autoforma_avig = autoforma_avig.v end   
    if imgui.Checkbox('##aunvig', autoforma_aunvig) then cfg.formssettings.autoforma_aunvig = autoforma_aunvig.v end
    if imgui.Checkbox('##setadmin', autoforma_setadmin) then cfg.formssettings.autoforma_setadmin = autoforma_setadmin.v end   
    if imgui.Checkbox('##spawncars', autoforma_spawncars) then cfg.formssettings.autoforma_spawncars = autoforma_spawncars.v end
    if imgui.Checkbox('##givedonate', autoforma_givedonate) then cfg.formssettings.autoforma_givedonate = autoforma_givedonate.v end   
    if imgui.Checkbox('##mpwin', autoforma_mpwin) then cfg.formssettings.autoforma_mpwin = autoforma_mpwin.v end   
    if imgui.Checkbox('##prefix', autoforma_prefix) then cfg.formssettings.autoforma_prefix = autoforma_prefix.v end   
    if imgui.Checkbox('##asellhouse', autoforma_asellhouse) then cfg.formssettings.autoforma_asellhouse = autoforma_asellhouse.v end   
    if imgui.Checkbox('##delacc', autoforma_delacc) then cfg.formssettings.autoforma_delacc = autoforma_delacc.v end   
    if imgui.Checkbox('##asellbiz', autoforma_asellbiz) then cfg.formssettings.autoforma_asellbiz = autoforma_asellbiz.v end
    if imgui.Checkbox('##money', autoforma_money) then cfg.formssettings.autoforma_money = autoforma_money.v end   
    if imgui.Checkbox('##test', autoforma_test) then cfg.formssettings.autoforma_test = autoforma_test.v end
    if imgui.Checkbox('##ans', autoforma_ans) then cfg.formssettings.autoforma_ans = autoforma_ans.v end
 
    imgui.EndChild()
    imgui.SameLine()
    imgui.BeginChild("ChildWin123123s3dow3", imgui.ImVec2(40, 1065), true)
    imgui.CenterText(u8'З')
    imgui.Separator()
 
    if imgui.Checkbox('##kick', notf_kick) then cfg.formssettings.notf_kick = notf_kick.v end
    if imgui.Checkbox('##mute', notf_mute) then cfg.formssettings.notf_mute = notf_mute.v end
    if imgui.Checkbox('##jail', notf_jail) then cfg.formssettings.notf_jail = notf_jail.v end
    if imgui.Checkbox('##jailoff', notf_jailoff) then cfg.formssettings.notf_jailoff = notf_jailoff.v end
    if imgui.Checkbox('##sethp', notf_sethp) then cfg.formssettings.notf_sethp = notf_sethp.v end
    if imgui.Checkbox('##sban', notf_sban) then cfg.formssettings.notf_sban = notf_sban.v end
    if imgui.Checkbox('##banoff', notf_banoff) then cfg.formssettings.notf_banoff = notf_banoff.v end
    if imgui.Checkbox('##muteoff', notf_muteoff) then cfg.formssettings.notf_muteoff = notf_muteoff.v end
    if imgui.Checkbox('##sbanoff', notf_sbanoff) then cfg.formssettings.notf_sbanoff = notf_sbanoff.v end   
    if imgui.Checkbox('##spplayer', notf_spplayer) then cfg.formssettings.notf_spplayer = notf_spplayer.v end
    if imgui.Checkbox('##slap', notf_slap) then cfg.formssettings.notf_slap = notf_slap.v end   
    if imgui.Checkbox('##unmute', notf_unmute) then cfg.formssettings.notf_unmute = notf_unmute.v end
    if imgui.Checkbox('##unjail', notf_unjail) then cfg.formssettings.notf_unjail = notf_unjail.v end
    if imgui.Checkbox('##spcar', notf_spcar) then cfg.formssettings.notf_spcar = notf_spcar.v end   
    if imgui.Checkbox('##ban', notf_ban) then cfg.formssettings.notf_ban = notf_ban.v end
    if imgui.Checkbox('##warn', notf_warn) then cfg.formssettings.notf_warn = notf_warn.v end   
    if imgui.Checkbox('##skick', notf_skick) then cfg.formssettings.notf_skick = notf_skick.v end   
    if imgui.Checkbox('##ao', notf_sao) then cfg.formssettings.notf_ao = notf_ao.v end
    if imgui.Checkbox('##unban', notf_unban) then cfg.formssettings.notf_unban = notf_unban.v end   
    if imgui.Checkbox('##unwarn', notf_unwarn) then cfg.formssettings.notf_unwarn = notf_unwarn.v end
    if imgui.Checkbox('##banip', notf_banip) then cfg.formssettings.notf_banip = notf_banip.v end
    if imgui.Checkbox('##offban', notf_offban) then cfg.formssettings.notf_offban = notf_offban.v end
    if imgui.Checkbox('##offwarn', notf_offwarn) then cfg.formssettings.notf_offwarn = notf_offwarn.v end   
    if imgui.Checkbox('##ptp', notf_ptp) then cfg.formssettings.notf_ptp = notf_ptp.v end   
    if imgui.Checkbox('##o', notf_o) then cfg.formssettings.notf_o = notf_o.v end   
    if imgui.Checkbox('##aad', notf_aad) then cfg.formssettings.notf_aad = notf_aad.v end   
    if imgui.Checkbox('##givegun', notf_givegun) then cfg.formssettings.notf_givegun = notf_givegun.v end   
    if imgui.Checkbox('##avig', notf_avig) then cfg.formssettings.notf_avig = notf_avig.v end   
    if imgui.Checkbox('##aunvig', notf_aunvig) then cfg.formssettings.notf_aunvig = notf_aunvig.v end
    if imgui.Checkbox('##setadmin', notf_setadmin) then cfg.formssettings.notf_setadmin = notf_setadmin.v end   
    if imgui.Checkbox('##spawncars', notf_spawncars) then cfg.formssettings.notf_spawncars = notf_spawncars.v end
    if imgui.Checkbox('##givedonate', notf_givedonate) then cfg.formssettings.notf_givedonate = notf_givedonate.v end   
    if imgui.Checkbox('##mpwin', notf_mpwin) then cfg.formssettings.notf_mpwin = notf_mpwin.v end   
    if imgui.Checkbox('##prefix', notf_prefix) then cfg.formssettings.notf_prefix = notf_prefix.v end   
    if imgui.Checkbox('##asellhouse', notf_asellhouse) then cfg.formssettings.notf_asellhouse = notf_asellhouse.v end   
    if imgui.Checkbox('##delacc', notf_delacc) then cfg.formssettings.notf_delacc = notf_delacc.v end   
    if imgui.Checkbox('##asellbiz', notf_asellbiz) then cfg.formssettings.notf_asellbiz = notf_asellbiz.v end
    if imgui.Checkbox('##money', notf_money) then cfg.formssettings.notf_money = notf_money.v end   
    if imgui.Checkbox('##test', notf_test) then cfg.formssettings.notf_test = notf_test.v end
    if imgui.Checkbox('##ans', notf_ans) then cfg.formssettings.notf_ans = notf_ans.v end
    imgui.EndChild()
end
 
  • Эм
Реакции: chapo
Решение
1. за такой код у нас принято отрывать руки
2. скорее всего ты сделал чекбокс/инпут с переменной, а саму переменную добавить забыл. Попробуй частями комментировать код и смотреть когда перестанет крашить

chapo

🫡 В армии с 17.10.2023. В ЛС НЕ ОТВЕЧАЮ
Друг
8,778
11,221
1. за такой код у нас принято отрывать руки
2. скорее всего ты сделал чекбокс/инпут с переменной, а саму переменную добавить забыл. Попробуй частями комментировать код и смотреть когда перестанет крашить
 
  • Ха-ха
  • Bug
Реакции: YarikVL и ppelledka