configRealisticArmor.lua

--[[
    Update Video: https://youtu.be/q4L8zVDOIus
    To ensure the system works, add the default item list to the items.lua file or configure the settings below. Make sure the item is unique and usable.

    t_armor_heavy = { name = 't_armor_heavy', label = 'Heavy Armor', weight = 100, type = 'item', image = 't_armor_heavy.png', unique = true, useable = true, shouldClose = true, description = '' },
    t_armor_light = { name = 't_armor_light', label = 'Light Armor', weight = 100, type = 'item', image = 't_armor_light.png', unique = true, useable = true, shouldClose = true, description = '' },
]]
config.realisticArmor = {
    active = true,                      -- If set to `true`, this system will be activated.
    checkClothe = true,                 -- If true, if the player has no armor value and is wearing armor as an outfit, it will remove this outfit
    items = {
        t_armor_heavy = {               -- Item name
            armor = 100,                -- The armor value that will be added when the player equips armor.
            progressbar = {
                active = true,          -- If set to `true`, a progress bar will be displayed when the player equips armor.
                label = "wearingArmor", -- u can change from language file
                time = 1500,            -- Progress bar time
                anims = {
                    animDict = "missmic4",
                    anim = "michael_tux_fidget",
                    flags = 49,
                },
                disables = {
                    disableMovement = false,
                    disableCarMovement = true,
                    disableMouse = false,
                    disableCombat = true,
                }
            },
            clothe = {
                active = true, -- If set to `true`, the player will wear the clothe armor.
                data = {
                    jobs = {
                        -- job with grade
                        ['police'] = {
                            [1] = {
                                [`mp_m_freemode_01`] = { drawable = 15, texture = 2 }, -- Male
                                [`mp_f_freemode_01`] = { drawable = 9, texture = 0 }   -- Female
                            },
                            [2] = {
                                [`mp_m_freemode_01`] = { drawable = 57, texture = 2 }, -- Male
                                [`mp_f_freemode_01`] = { drawable = 9, texture = 0 }   -- Female
                            },
                            other = {
                                [`mp_m_freemode_01`] = { drawable = 15, texture = 0 }, -- Male
                                [`mp_f_freemode_01`] = { drawable = 9, texture = 0 }   -- Female
                            }
                        },
                        -- Job without grade
                        ['ambulance'] = {
                            other = {
                                [`mp_m_freemode_01`] = { drawable = 58, texture = 0 },
                                [`mp_f_freemode_01`] = { drawable = 9, texture = 0 }
                            }
                        },
                    },
                    -- If the player does not meet any of the values in the jobs config section, the clothing data will change according to these values.
                    other = {
                        [`mp_m_freemode_01`] = { drawable = 1, texture = 1 }, -- Male
                        [`mp_f_freemode_01`] = { drawable = 9, texture = 0 }  -- Female
                    },
                }
            }
        },
        t_armor_light = {
            armor = 50,
            progressbar = {
                active = true,
                label = "wearingArmor", -- u can change from language file
                time = 1500,
                anims = {
                    animDict = "missmic4",
                    anim = "michael_tux_fidget",
                    flags = 49,
                },
                disables = {
                    disableMovement = false,
                    disableCarMovement = true,
                    disableMouse = false,
                    disableCombat = true,
                }
            }
        }
    }
}

Last updated