Added New Mods and Profiles Folders

This is a complete rebuild of the modpack, with all new mods and updates for 1.5.3 of Anomaly.
This commit is contained in:
2025-01-14 05:07:53 -05:00
parent 85c665b107
commit 376b4b9689
21217 changed files with 546254 additions and 0 deletions
@@ -0,0 +1,226 @@
<?xml version="1.0" encoding="utf-8"?>
<string_table>
<string id="ui_mcm_menu_liz_inex">
<text>Inertia Expanded</text>
</string>
<string id="ui_mcm_menu_lean">
<text>Leaning</text>
</string>
<string id="ui_mcm_menu_jumpland">
<text>Jump & Land</text>
</string>
<string id="ui_mcm_menu_crouch_jitter">
<text>Crouch sway</text>
</string>
<string id="ui_mcm_menu_noise">
<text>Noise</text>
</string>
<string id="ui_mcm_menu_breathing">
<text>Breathing</text>
</string>
<string id="ui_mcm_menu_look_up">
<text>Look up shift</text>
</string>
<string id="ui_mcm_menu_other">
<text>Other</text>
</string>
<string id="ui_mcm_title_liz_inex_lean">
<text>Leaning animations</text>
</string>
<string id="ui_mcm_title_liz_inex_jumpland">
<text>Jump and Land animations</text>
</string>
<string id="ui_mcm_title_liz_inex_crouch_jitter">
<text>Weapon sway on crouch</text>
</string>
<string id="ui_mcm_title_liz_inex_noise">
<text>Random noise sway</text>
</string>
<string id="ui_mcm_title_liz_inex_breathing">
<text>Breathing animation</text>
</string>
<string id="ui_mcm_title_liz_inex_look_up">
<text>Weapon position shift on look up</text>
</string>
<string id="ui_mcm_title_liz_inex_other">
<text>Other options</text>
</string>
<string id="ui_mcm_liz_inex_lean_l_power">
<text>Lean left intensity</text>
</string>
<string id="ui_mcm_liz_inex_lean_r_power">
<text>Lean right intensity</text>
</string>
<string id="ui_mcm_liz_inex_lean_crouch_power">
<text>Crouch intensity</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_speed">
<text>Jump speed</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_speed_desc">
<text>Jump animation speed.\nThe higher the value, the faster the animation.</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_power">
<text>Jump amplitude</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_power_desc">
<text>Determines how strongly the jump animation will be expressed.\nThe higher the value, the higher the amplitude of the animation.\nA value of 0 turns off the jump animation.</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_speed">
<text>Landing speed</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_speed_desc">
<text>The speed of the landing animation after falling.\nThe higher the value, the faster the animation.</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_power">
<text>Landing amplitude</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_power_desc">
<text>Determines how pronounced the landing animation will be.\nThe higher the value, the higher the amplitude of the animation.\nA value of 0 turns off the landing animation.</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_blocket_by_aim">
<text>Disable crouch jitter while aiming</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_blocket_by_aim_desc">
<text>During crouching, the weapon will sway slightly, which can interfere with aiming.\nThis option allows you to not play the crouch jitter animation while you aim.</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_speed">
<text>Crouch jitter speed</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_speed_desc">
<text>Determines how fast the weapon will jitter when crouching.\nThe higher the value, the faster the animation.</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_power">
<text>Crouch jitter amplitude</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_power_desc">
<text>Determines how pronounced the crouch jitter animation will be when crouching.\nThe higher the value, the higher the amplitude of the animation.\nA value of 0 turns off the crouch jitter animation when crouching.</text>
</string>
<string id="ui_mcm_liz_inex_noise_only_for_weapon">
<text>Play random sway animation for weapons only</text>
</string>
<string id="ui_mcm_liz_inex_noise_only_for_weapon_desc">
<text>The random hands sway animation can be annoying when using a PDA.\nThis option allows you to play this animation only for weapons, so as not to interfere when using a PDA or other devices.</text>
</string>
<string id="ui_mcm_liz_inex_noise_speed">
<text>Random sway speed</text>
</string>
<string id="ui_mcm_liz_inex_noise_speed_desc">
<text>A person cannot stand absolutely still, and this animation adds slight swaying of the character's arms.\nThis option determines the speed of the swaying animation.\nThe higher the value, the faster the animation.</text>
</string>
<string id="ui_mcm_liz_inex_noise_power">
<text>Random sway amplitude</text>
</string>
<string id="ui_mcm_liz_inex_noise_power_desc">
<text>A person cannot stand absolutely still, and this animation adds slight swaying of the character's arms.\nThis option determines how strongly the swaying animation will be expressed.\nThe higher the value, the higher the amplitude of the animation.\nA value of 0 turns off the landing animation.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_only_for_weapon">
<text>Play breathing animation for weapons only</text>
</string>
<string id="ui_mcm_liz_inex_breathing_only_for_weapon_desc">
<text>The animation of the arms swaying when breathing can be annoying when using a PDA.\nThis option allows you to play this animation only for weapons, so as not to interfere when using a PDA or other devices.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_min">
<text>Resting breathing rate</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_min_desc">
<text>The speed of the breathing animation in a calm state.\nThe higher the value, the faster the animation.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_max">
<text>Breathing rate at low stamina</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_max_desc">
<text>The speed of the breathing animation when stamina is low.\nThe higher the value, the faster the animation.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_min">
<text>Resting breathing amplitude</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_min_desc">
<text>Determines how strongly the breathing animation will be expressed in a calm state.\nThe higher the value, the higher the amplitude of the animation.\nA value of 0 turns off the breathing animation when the character has full stamina.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_max">
<text>Breathing amplitude at low stamina</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_max_desc">
<text>Determines how pronounced the breathing animation will be when the stamina is low.\nThe higher the value, the higher the amplitude of the animation.\nA value of 0 turns off the breathing animation when the character has low stamina.</text>
</string>
<string id="ui_mcm_liz_inex_look_up_enabled">
<text>Move weapon down when looking up</text>
</string>
<string id="ui_mcm_liz_inex_look_up_trigger_at">
<text>Angle to trigger looking up animation</text>
</string>
<string id="ui_mcm_liz_inex_look_up_trigger_at_desc">
<text>This option determines how high up you need to raise your head for the weapon model to start moving down.\nThe higher the value, the higher you need to look up to start the animation.</text>
</string>
<string id="ui_mcm_liz_inex_look_up_power">
<text>Look up animation intensity</text>
</string>
<string id="ui_mcm_liz_inex_other_device_lean_enable">
<text>Detectors move with weapon when leaning</text>
</string>
<string id="ui_mcm_liz_inex_other_hit_anm_enable">
<text>React to damage animation</text>
</string>
</string_table>
@@ -0,0 +1,226 @@
<?xml version="1.0" encoding="windows-1251"?>
<string_table>
<string id="ui_mcm_menu_liz_inex">
<text>Inertia Expanded</text>
</string>
<string id="ui_mcm_menu_lean">
<text>Наклоны</text>
</string>
<string id="ui_mcm_menu_jumpland">
<text>Прыжок</text>
</string>
<string id="ui_mcm_menu_crouch_jitter">
<text>Покачивание (приседания)</text>
</string>
<string id="ui_mcm_menu_noise">
<text>Покачивания (случайные)</text>
</string>
<string id="ui_mcm_menu_breathing">
<text>Дыхание</text>
</string>
<string id="ui_mcm_menu_look_up">
<text>Взгляд вверх</text>
</string>
<string id="ui_mcm_menu_other">
<text>Прочее</text>
</string>
<string id="ui_mcm_title_liz_inex_lean">
<text>Анимации наклона</text>
</string>
<string id="ui_mcm_title_liz_inex_jumpland">
<text>Анимация прыжка</text>
</string>
<string id="ui_mcm_title_liz_inex_crouch_jitter">
<text>Покачивание при присяде</text>
</string>
<string id="ui_mcm_title_liz_inex_noise">
<text>Случайные покачивания</text>
</string>
<string id="ui_mcm_title_liz_inex_breathing">
<text>Анимация дыхания</text>
</string>
<string id="ui_mcm_title_liz_inex_look_up">
<text>Смещение при взгляде вверх</text>
</string>
<string id="ui_mcm_title_liz_inex_other">
<text>Прочее</text>
</string>
<string id="ui_mcm_liz_inex_lean_l_power">
<text>Интенсивность наклона влево</text>
</string>
<string id="ui_mcm_liz_inex_lean_r_power">
<text>Интенсивность наклона вправо</text>
</string>
<string id="ui_mcm_liz_inex_lean_crouch_power">
<text>Интенсивность приседа</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_speed">
<text>Скорость прыжка</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_speed_desc">
<text>Скорость анимации прыжка.\nЧем выше значение, тем быстрее анимация.</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_power">
<text>Амплитуда прыжка</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_jump_power_desc">
<text>Определяет насколько сильно будет выраженна анимация прыжка.\nЧем больше значение, тем выше амплитуда анимации.\nЗначение равное 0 выключает анимацию прыжка.</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_speed">
<text>Скорость приземления</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_speed_desc">
<text>Скорость анимации приземления после падения.\nЧем выше значение, тем быстрее анимация.</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_power">
<text>Амплитуда приземления</text>
</string>
<string id="ui_mcm_liz_inex_jumpland_land_power_desc">
<text>Определяет насколько сильно будет выраженна анимация приземления.\nЧем больше значение, тем выше амплитуда анимации.\nЗначение равное 0 выключает анимацию приземления.</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_blocket_by_aim">
<text>Выключить тряску при присяде во время прицеливания</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_blocket_by_aim_desc">
<text>Во время приседания оружие будет слегда покачиваться, что может мешать во время прицеливания.\nДанная опция дает возможность не проигрывать анимацию покачивания оружия, в момент когда вы целитесь.</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_speed">
<text>Скорость тряски при присяде</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_speed_desc">
<text>Определяет насколько быстро будет покачиваться оружие при присяде.\nЧем выше значение, тем быстрее анимация.</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_power">
<text>Амплитуда тряски при присяде</text>
</string>
<string id="ui_mcm_liz_inex_crouch_jitter_power_desc">
<text>Определяет насколько сильно будет выраженна анимация покачивания оружия в момент приседания.\nЧем больше значение, тем выше амплитуда анимации.\nЗначение равное 0 выключает анимацию покачивания оружия в момент приседания.</text>
</string>
<string id="ui_mcm_liz_inex_noise_only_for_weapon">
<text>Проигрывать анимацию раскачивания только для оружия</text>
</string>
<string id="ui_mcm_liz_inex_noise_only_for_weapon_desc">
<text>Анимация случайных покачиваний рук может мешать при использовании PDA.\nДанная опция позволяет проигрывать эту анимацию только для оружия, чтобы не мешать при использвании PDA или других устройств.</text>
</string>
<string id="ui_mcm_liz_inex_noise_speed">
<text>Скорость раскачивания</text>
</string>
<string id="ui_mcm_liz_inex_noise_speed_desc">
<text>Человек не может стоять абсолютно неподвижно, и данная анимация добавляет легкие покачивания рук персонажа.\nДанная опция определяет скорость анимации раскачивания.\nЧем выше значение, тем быстрее анимация.</text>
</string>
<string id="ui_mcm_liz_inex_noise_power">
<text>Амплитуда раскачивания</text>
</string>
<string id="ui_mcm_liz_inex_noise_power_desc">
<text>Человек не может стоять абсолютно неподвижно, и данная анимация добавляет легкие покачивания рук персонажа.\nДанная опция определяет насколько сильно будет выраженна анимация раскачивания.\nЧем больше значение, тем выше амплитуда анимации.\nЗначение равное 0 выключает анимацию приземления.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_only_for_weapon">
<text>Проигрывать анимацию дыхания только для оружия</text>
</string>
<string id="ui_mcm_liz_inex_breathing_only_for_weapon_desc">
<text>Анимация раскачивание рук при дыхании может мешать при использовании PDA.\nДанная опция позволяет проигрывать эту анимацию только для оружия, чтобы не мешать при использвании PDA или других устройств.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_min">
<text>Скорость дыхания в покое</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_min_desc">
<text>Скорость анимации дыхания в спокойном состоянии.\nЧем выше значение, тем быстрее анимация.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_max">
<text>Скорость дыхания при низкой выносливости</text>
</string>
<string id="ui_mcm_liz_inex_breathing_speed_max_desc">
<text>Скорость анимации дыхания при низкой выносливости.\nЧем выше значение, тем быстрее анимация.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_min">
<text>Амплитуда дыхания в покое</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_min_desc">
<text>Определяет насколько сильно будет выраженна анимация дыхания в спокойном состоянии.\nЧем больше значение, тем выше амплитуда анимации.\nЗначение равное 0 выключает анимацию дыхания когда у персонажа полная выносливость.</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_max">
<text>Амплитуда дыхания при низкой выносливости</text>
</string>
<string id="ui_mcm_liz_inex_breathing_power_max_desc">
<text>Определяет насколько сильно будет выраженна анимация дыхания при низкой выносливости.\nЧем больше значение, тем выше амплитуда анимации.\nЗначение равное 0 выключает анимацию дыхания когда у персонажа низкая выносливость.</text>
</string>
<string id="ui_mcm_liz_inex_look_up_enabled">
<text>Сместить оружие ниже при взгляде вверх</text>
</string>
<string id="ui_mcm_liz_inex_look_up_trigger_at">
<text>Угол начала смещения</text>
</string>
<string id="ui_mcm_liz_inex_look_up_trigger_at_desc">
<text>Данная опция определяет насколько высоко вверх нужно поднять голову, чтобы модель оружия начала смещаться вниз.\nЧем выше значение, тем выше нужно поднять взгляд для запуска анимации.</text>
</string>
<string id="ui_mcm_liz_inex_look_up_power">
<text>Интенсивность смещения</text>
</string>
<string id="ui_mcm_liz_inex_other_device_lean_enable">
<text>При наклоне детекторы смещаются вместе с оружием</text>
</string>
<string id="ui_mcm_liz_inex_other_hit_anm_enable">
<text>Анимация реакции на урон</text>
</string>
</string_table>
@@ -0,0 +1,292 @@
-- TODO:
-- - limp on low helath animation? Kinda don't wanna overdo this mod. It should be nice, simple and lightweight
-- - option to toggle detector leaning
-- - option to toggle hit anim
-- - better hit animations
animate_hand = 2
wpn_all_configs = {}
mask_layers = {
none = 0,
wpn_aim = 1,
wpn_reload = 2,
wpn_lower = 4,
not_weapon = 8,
anm_plays = 16
}
local lerps = {}
local block_mask = 0
local hit_anims = {
"liz\\liz_hands_hit1_additive.anm",
"liz\\liz_hands_hit2_additive.anm",
"liz\\liz_hands_hit3_additive.anm",
}
local last_wpn_section
local wpn_config = { l = 1, r = 1, c = 1, u = 1 }
local is_valid_hit_type
local look_up_factor = 0
local look_up_max = 1.5
local mcm_lean_l_power
local mcm_lean_r_power
local mcm_crouch_power
local mcm_jump_speed
local mcm_jump_power
local mcm_land_speed
local mcm_land_power
local mcm_crouch_jitter_blocket_by_aim
local mcm_crouch_jitter_speed
local mcm_crouch_jitter_power
local mcm_noise_only_for_weapon
local mcm_noise_speed
local mcm_noise_power
local mcm_breathing_only_for_weapon
local mcm_breathing_speed_min
local mcm_breathing_speed_max
local mcm_breathing_power_min
local mcm_breathing_power_max
local mcm_lower_weapon_on_look_up
local mcm_look_up_trigger_at
local mcm_look_up_power
local mcm_device_lean_enable
local mcm_hit_anm_enable
function lerp(from, to, power)
return (from * (1 - power)) + (to * power)
end
function new_lerp(name, from, to, power, mask)
lerps[name] = {
from = from,
to = to,
power = power,
mask = mask,
}
end
function set_lerp(name, to, power)
local lp = lerps[name]
if lp then
lp.to = to
if power then lp.power = power end
end
end
function set_mask_flag(flag, value)
-- printf("mask flag %s was set to %s", flag, value)
if value then
block_mask = bit_or(block_mask, flag)
else
block_mask = bit_and(block_mask, bit_not(flag))
end
end
function new_mask(...)
local a = { ... }
local mask = 0
for i = 1, #a do
mask = bit_or(mask, a[i])
end
return mask
end
function initialize()
mcm_lean_l_power = liz_inertia_expanded_mcm.get_config("lean/l_power")
mcm_lean_r_power = liz_inertia_expanded_mcm.get_config("lean/r_power")
mcm_crouch_power = liz_inertia_expanded_mcm.get_config("lean/crouch_power")
mcm_jump_speed = liz_inertia_expanded_mcm.get_config("jumpland/jump_speed")
mcm_jump_power = liz_inertia_expanded_mcm.get_config("jumpland/jump_power")
mcm_land_speed = liz_inertia_expanded_mcm.get_config("jumpland/land_speed")
mcm_land_power = liz_inertia_expanded_mcm.get_config("jumpland/land_power")
mcm_crouch_jitter_blocket_by_aim = liz_inertia_expanded_mcm.get_config("crouch_jitter/blocket_by_aim")
mcm_crouch_jitter_speed = liz_inertia_expanded_mcm.get_config("crouch_jitter/speed")
mcm_crouch_jitter_power = liz_inertia_expanded_mcm.get_config("crouch_jitter/power")
mcm_noise_only_for_weapon = liz_inertia_expanded_mcm.get_config("noise/only_for_weapon")
mcm_noise_power = liz_inertia_expanded_mcm.get_config("noise/power")
mcm_noise_speed = liz_inertia_expanded_mcm.get_config("noise/speed")
mcm_breathing_only_for_weapon = liz_inertia_expanded_mcm.get_config("breathing/only_for_weapon")
mcm_breathing_speed_min = liz_inertia_expanded_mcm.get_config("breathing/speed_min")
mcm_breathing_speed_max = liz_inertia_expanded_mcm.get_config("breathing/speed_max")
mcm_breathing_power_min = liz_inertia_expanded_mcm.get_config("breathing/power_min")
mcm_breathing_power_max = liz_inertia_expanded_mcm.get_config("breathing/power_max")
mcm_lower_weapon_on_look_up = liz_inertia_expanded_mcm.get_config("look_up/enabled")
mcm_look_up_trigger_at = liz_inertia_expanded_mcm.get_config("look_up/trigger_at")
mcm_look_up_power = liz_inertia_expanded_mcm.get_config("look_up/power")
mcm_device_lean_enable = liz_inertia_expanded_mcm.get_config("other/device_lean_enable")
mcm_hit_anm_enable = liz_inertia_expanded_mcm.get_config("other/hit_anm_enable")
local breathing_mask = mcm_breathing_only_for_weapon and new_mask(mask_layers.wpn_aim, mask_layers.not_weapon) or mask_layers.wpn_aim
local noise_mask = mcm_noise_only_for_weapon and new_mask(mask_layers.wpn_aim, mask_layers.not_weapon) or mask_layers.wpn_aim
new_lerp("lean_l", 0, 0, .5, new_mask(mask_layers.wpn_aim, mask_layers.wpn_lower, mask_layers.not_weapon, mask_layers.anm_plays))
new_lerp("lean_r", 0, 0, .5, new_mask(mask_layers.wpn_aim, mask_layers.wpn_lower, mask_layers.not_weapon, mask_layers.anm_plays))
new_lerp("crouch", 0, 0, .5, new_mask(mask_layers.wpn_aim, mask_layers.wpn_lower, mask_layers.not_weapon, mask_layers.anm_plays))
new_lerp("breathing_power", 0, 0, .8, breathing_mask)
new_lerp("breathing_speed", 0, 0, .8, breathing_mask)
new_lerp("noise", mcm_noise_power, mcm_noise_power, 1, noise_mask)
end
function actor_on_update(_, delta)
local dt = delta / 100
for key, val in pairs(lerps) do
local target_val = is_overriden(val.mask) and 0 or val.to
local target_pow = is_overriden(val.mask) and 0.9 or val.power
val.from = lerp(val.from, target_val, target_pow * dt)
end
--update lerps targets
local actor = db.actor
update_weapon_info(actor)
update_device_info(actor)
update_stamina_info(actor)
update_move_state_info()
update_look_up_factor()
--update animations
game.play_hud_anm("liz\\liz_hands_breathing_additive.anm", 2, lerps["breathing_speed"].from, lerps["breathing_power"].from, true, true)
game.play_hud_anm("liz\\liz_hands_noise_additive.anm", 2, mcm_noise_speed, lerps["noise"].from, true, true)
game.play_hud_anm("liz\\liz_hands_crouch_additive.anm", animate_hand, 1, lerps["crouch"].from, true, true)
game.play_hud_anm("liz\\liz_hands_lean_l_additive.anm", animate_hand, 1, lerps["lean_l"].from, true, true)
game.play_hud_anm("liz\\liz_hands_lean_r_additive.anm", animate_hand, 1, lerps["lean_r"].from, true, true)
end
function update_move_state_info()
local block_crouch = false
if IsMoveState('mcLLookout') then set_lerp("lean_l", mcm_lean_l_power * wpn_config.l); block_crouch = true else set_lerp("lean_l", 0) end
if IsMoveState('mcRLookout') then set_lerp("lean_r", mcm_lean_r_power * wpn_config.r); block_crouch = true else set_lerp("lean_r", 0) end
if not block_crouch then
if IsMoveState('mcCrouch') then set_lerp("crouch", mcm_crouch_power * wpn_config.c) else set_lerp("crouch", mcm_lower_weapon_on_look_up and look_up_factor * wpn_config.u or 0) end
else
set_lerp("crouch", 0)
end
end
function update_stamina_info(actor)
if actor then
set_lerp("breathing_speed", mcm_breathing_speed_min + (mcm_breathing_speed_max - mcm_breathing_speed_min) * (1 - actor.power))
set_lerp("breathing_power", mcm_breathing_power_min + (mcm_breathing_power_max - mcm_breathing_power_min) * (1 - actor.power))
end
end
function update_look_up_factor()
local angle = device().cam_dir:getP() -- -1.5 is down, 0 is forward, 1.5 is up
look_up_factor = clamp((angle - mcm_look_up_trigger_at) / (look_up_max - mcm_look_up_trigger_at), 0, 1) * mcm_look_up_power
end
function is_overriden(mask)
if bit_and(block_mask, mask) == 0 then return false else return true end
end
function update_weapon_info(actor)
local wpn = actor and actor:active_item()
local sec = wpn and wpn:section()
if sec ~= last_wpn_section then
if IsWeapon(wpn) and not IsMelee(wpn) then
last_wpn_section = sec
set_mask_flag(mask_layers.not_weapon, false)
wpn_config = { l = 1, r = 1, c = 1, u = 1 }
if wpn_all_configs[sec] then
for key, val in pairs(wpn_all_configs[sec]) do
wpn_config[key] = val
end
end
else
last_wpn_section = nil
set_mask_flag(mask_layers.not_weapon, true)
wpn_config = { l = 1, r = 1, c = 1, u = 1 }
end
end
end
function update_device_info(actor)
if not mcm_device_lean_enable and actor and actor:active_detector() then
animate_hand = 0
else
animate_hand = 2
end
end
-- use weapon state instead. get state every frame with wpn:get_state(). State 7 is realod (or state 2 idk)
-- function actor_on_weapon_reload()
-- -- this one will do for temporary test
-- set_mask_flag(mask_layers.wpn_reload, true)
-- CreateTimeEvent("liz_inertia_expanded", "actor_on_weapon_reload", 2, function ()
-- set_mask_flag(mask_layers.wpn_reload, false)
-- return true
-- end)
-- end
function on_key_press(key)
if key == bind_to_dik(key_bindings.kCROUCH) then
if mcm_crouch_jitter_blocket_by_aim and is_overriden(mask_layers.wpn_aim) then return end
if IsMoveState('mcCrouch') then
game.play_hud_anm("liz\\liz_hands_crouch_end_additive.anm", 2, mcm_crouch_jitter_speed, mcm_crouch_jitter_power, false, false)
else
game.play_hud_anm("liz\\liz_hands_crouch_start_additive.anm", 2, mcm_crouch_jitter_speed, mcm_crouch_jitter_power, false, false)
end
end
end
-- fix for those who use press to crouch instead of toggle crouch
function on_key_release(key)
if key == bind_to_dik(key_bindings.kCROUCH) then
if mcm_crouch_jitter_blocket_by_aim and is_overriden(mask_layers.wpn_aim) then return end
local crouch_type_toggle = get_console_cmd(1, "g_crouch_toggle")
if not crouch_type_toggle then
game.play_hud_anm("liz\\liz_hands_crouch_end_additive.anm", 2, mcm_crouch_jitter_speed, mcm_crouch_jitter_power, false, false)
end
end
end
local valid_hit_types = {
-- [0] = true, -- burn
-- [1] = true, -- shock
-- [2] = true, -- chemical burn
-- [3] = true, -- radiation
-- [4] = true, -- telepathic
[5] = true, -- wound
[6] = true, -- fire wound
[7] = true, -- strike
[8] = true, -- explosion
[9] = true, -- wound2
-- [10] = true, -- light burn
}
function actor_on_hit_callback()
if not mcm_hit_anm_enable then return end
if not is_valid_hit_type then return end
if is_overriden(mask_layers.wpn_aim) then return end
local hit_anim = hit_anims[math.random(1, #hit_anims)]
game.play_hud_anm(hit_anim, 2, 1, 1, false, true)
end
function on_game_start()
RegisterScriptCallback("on_option_change", initialize)
RegisterScriptCallback("actor_on_first_update", initialize)
RegisterScriptCallback("actor_on_update", actor_on_update)
RegisterScriptCallback("on_key_press", on_key_press)
RegisterScriptCallback("on_key_release", on_key_release)
RegisterScriptCallback("actor_on_before_hit", function (hit) is_valid_hit_type = valid_hit_types[hit.type] end)
RegisterScriptCallback("actor_on_hit_callback", actor_on_hit_callback)
RegisterScriptCallback("actor_on_jump", function () game.play_hud_anm("liz\\liz_hands_jump_additive.anm", 2, mcm_jump_speed, mcm_jump_power, false, false) end)
RegisterScriptCallback("actor_on_land", function () game.play_hud_anm("liz\\liz_hands_landing_additive.anm", 2, mcm_land_speed, mcm_land_power, false, false) end)
RegisterScriptCallback("actor_on_weapon_lower", function () set_mask_flag(mask_layers.wpn_lower, true) end)
RegisterScriptCallback("actor_on_weapon_raise", function () set_mask_flag(mask_layers.wpn_lower, false) end)
RegisterScriptCallback("actor_on_weapon_zoom_in", function () set_mask_flag(mask_layers.wpn_aim, true) end)
RegisterScriptCallback("actor_on_weapon_zoom_out", function () set_mask_flag(mask_layers.wpn_aim, false) end)
-- RegisterScriptCallback("actor_on_weapon_reload", actor_on_weapon_reload)
end
@@ -0,0 +1,34 @@
-- In this file you can enter the name of the section of a specific weapon for which you want to set special values for
-- the animation strength when leaning or crouching or looking up.
-- Just copy this file, rename it any way you want, then uncomment or copy/paste example template to add custom values for
-- leaning and crouching animations.
--
-- Currently you can set 4 variables:
-- • l - animation power when leaning Left
-- • r - animation power when leaning Right
-- • c - animation power when Crouching
-- • u - animation power when looking Up
--
-- Those variables take float values and will multiply power of the said animation.
-- For example "r = 0" will disable leaning right animation for specific weapon,
-- "c = 2" will make crouch animation 2 times more pronounced. See some examples below
if liz_inertia_expanded then
if not liz_inertia_expanded.wpn_all_configs then
liz_inertia_expanded.wpn_all_configs = {}
end
local c = liz_inertia_expanded.wpn_all_configs
-- -- example 1: disable leaning left and right animations for wpn_ak74_alt
-- c["wpn_ak74_alt"] = {
-- l = 0,
-- r = 0,
-- }
-- -- example 2: make crouch animation less pronounced by half for wpn_ak74
-- c["wpn_ak74"] = {
-- c = 0.5,
-- }
end
@@ -0,0 +1,113 @@
local defaults = {
["lean/l_power"] = 1,
["lean/r_power"] = 1,
["lean/crouch_power"] = 1,
["jumpland/jump_speed"] = 0.65,
["jumpland/jump_power"] = 2,
["jumpland/land_speed"] = 0.65,
["jumpland/land_power"] = 4,
["crouch_jitter/blocket_by_aim"] = false,
["crouch_jitter/speed"] = 0.6,
["crouch_jitter/power"] = 1.5,
["noise/only_for_weapon"] = true,
["noise/speed"] = 0.6,
["noise/power"] = 1,
["breathing/only_for_weapon"] = true,
["breathing/speed_min"] = 0.35,
["breathing/speed_max"] = 1,
["breathing/power_min"] = 0.7,
["breathing/power_max"] = 2,
["look_up/enabled"] = true,
["look_up/trigger_at"] = 0.65,
["look_up/power"] = 1,
["other/device_lean_enable"] = false,
["other/hit_anm_enable"] = true,
}
function get_config(key)
if ui_mcm then return ui_mcm.get("liz_inex/"..key) else return defaults[key] end
end
function on_mcm_load()
op = {
id = "liz_inex",
gr = {
{
id = "lean",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_lean", size = { 512, 50 }, spacing = 20 },
{ id = "l_power", type = "track", val = 2, def = 1, min = 0.0, max = 2, step = 0.05 },
{ id = "r_power", type = "track", val = 2, def = 1, min = 0.0, max = 2, step = 0.05 },
{ id = "crouch_power", type = "track", val = 2, def = 1, min = 0.0, max = 2, step = 0.05 },
}
},
{
id = "jumpland",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_jumpland", size = { 512, 50 }, spacing = 20 },
{ id = "jump_speed", type = "track", val = 2, def = 0.65, min = 0.0, max = 1.3, step = 0.05 },
{ id = "jump_power", type = "track", val = 2, def = 2, min = 0.0, max = 4, step = 0.05 },
{ id = "line", type = "line" },
{ id = "land_speed", type = "track", val = 2, def = 0.65, min = 0.0, max = 1.3, step = 0.05 },
{ id = "land_power", type = "track", val = 2, def = 4, min = 0.0, max = 8, step = 0.05 },
}
},
{
id = "crouch_jitter",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_crouch_jitter", size = { 512, 50 }, spacing = 20 },
{ id = "blocket_by_aim", type = "check", val = 1, def = false },
{ id = "speed", type = "track", val = 2, def = 0.6, min = 0.0, max = 1.2, step = 0.05 },
{ id = "power", type = "track", val = 2, def = 1.5, min = 0.0, max = 3, step = 0.05 },
}
},
{
id = "noise",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_noise", size = { 512, 50 }, spacing = 20 },
{ id = "only_for_weapon", type = "check", val = 1, def = true },
{ id = "speed", type = "track", val = 2, def = 0.6, min = 0.0, max = 1.2, step = 0.05 },
{ id = "power", type = "track", val = 2, def = 1, min = 0.0, max = 2, step = 0.05 },
}
},
{
id = "breathing",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_breathing", size = { 512, 50 }, spacing = 20 },
{ id = "only_for_weapon", type = "check", val = 1, def = true },
{ id = "speed_min", type = "track", val = 2, def = 0.35, min = 0.0, max = 0.7, step = 0.05 },
{ id = "power_min", type = "track", val = 2, def = 0.7, min = 0.0, max = 1.4, step = 0.05 },
{ id = "speed_max", type = "track", val = 2, def = 1, min = 0.0, max = 2, step = 0.05 },
{ id = "power_max", type = "track", val = 2, def = 2, min = 0.0, max = 4, step = 0.05 },
}
},
{
id = "look_up",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_look_up", size = { 512, 50 }, spacing = 20 },
{ id = "enabled", type = "check", val = 1, def = true },
{ id = "trigger_at", type = "track", val = 2, def = 0.65, min = 0.0, max = 1.45, step = 0.05 },
{ id = "power", type = "track", val = 2, def = 1, min = 0.0, max = 2, step = 0.05 },
}
},
{
id = "other",
sh = true,
gr = {
{ id = "slide", type = "slide", link = "ui_options_slider_player", text = "ui_mcm_title_liz_inex_other", size = { 512, 50 }, spacing = 20 },
{ id = "device_lean_enable", type = "check", val = 1, def = false },
{ id = "hit_anm_enable", type = "check", val = 1, def = true },
}
}
}
}
return op
end
@@ -0,0 +1,73 @@
local mc_anm_time_1 = 0
local mc_anm_time_2 = 0
local torch_anm_time = 0
local anm_additional_length = 0
function desable_left_hand_for_seconds(start, duration)
CreateTimeEvent("liz_inertia_expanded_patches", "on_key_release_start", start, function ()
liz_inertia_expanded.set_mask_flag(liz_inertia_expanded.mask_layers.anm_plays, true)
CreateTimeEvent("liz_inertia_expanded_patches", "on_key_release_end", duration, function ()
liz_inertia_expanded.set_mask_flag(liz_inertia_expanded.mask_layers.anm_plays, false)
return true
end)
return true
end)
end
function handle_whipe_anm()
local det_active = db.actor:active_detector() or nil
if (not db.actor:active_item() and not det_active) then
desable_left_hand_for_seconds(0, mc_anm_time_1 + mc_anm_time_2)
else
desable_left_hand_for_seconds(0, mc_anm_time_1 + mc_anm_time_2 + anm_additional_length)
end
end
function handle_torch_anm()
local det_active = db.actor:active_detector() or nil
if (not db.actor:active_item() and not det_active) then
desable_left_hand_for_seconds(0, mc_anm_time_1 + torch_anm_time)
else
desable_left_hand_for_seconds(0, mc_anm_time_1 + torch_anm_time + anm_additional_length)
end
end
local originalHMC = actor_effects.Hit_MaskCleaning
actor_effects.Hit_MaskCleaning = function ()
if (not actor_effects.allow_animation()) or (not actor_effects.is_mask_on()) then
return
end
handle_whipe_anm()
originalHMC()
end
local originalHTT = actor_effects.Hit_TorchToggle
actor_effects.Hit_TorchToggle = function ()
if (not actor_effects.allow_animation()) or (not item_device.can_toggle_torch()) then
return
end
handle_torch_anm()
originalHTT()
end
function actor_on_first_update()
mc_anm_time_1 = game.get_motion_length("anim_mask_clean", "anm_hide_hand", 1.5) / 1000
mc_anm_time_2 = game.get_motion_length("anim_mask_clean", "anm_wipe", 1) / 1000
torch_anm_time = game.get_motion_length("anim_headlamp", "anm_switch", 1) / 1000
anm_additional_length = 0.5 --0.45 --0.8
end
function on_game_start()
RegisterScriptCallback("actor_on_first_update", actor_on_first_update)
end
+28
View File
@@ -0,0 +1,28 @@
[General]
gameName=stalkeranomaly
modid=0
version=d2024.11.23.0
newestVersion=
category="-1,"
nexusFileStatus=1
installationFile=weapon_inertia_expanded_v1.4.1.zip
repository=Nexus
ignoredVersion=
comments=
notes=
nexusDescription=
url=
hasCustomURL=false
lastNexusQuery=
lastNexusUpdate=
nexusLastModified=2024-11-23T10:08:18Z
nexusCategory=0
converted=false
validated=false
color=@Variant(\0\0\0\x43\0\xff\xff\0\0\0\0\0\0\0\0)
tracked=0
[installedFiles]
1\modid=0
1\fileid=0
size=1