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,14 @@
[info]
name = AMCM ; be unique, should match ltx name but not required
version = 1.6.0 ; version numbers must follow https://semver.org/ (lua limitations results in a slightly less strict implementation)
;test your version numbers. badly formatted version numbers will crash with message
rev_compat_major = false ; if false the major version, (first number) comparison will be equalsto(==) if true greaterthan or equals to (=>) only set to true if you know addons looking for 1.x.x of your addon will work with 2.x.x
;about is a , seperated list of up to 3 strings that will be translated then printed one per line when MCM Versions prints a message about your addon/mod/script primary downlaod URL would be good to include.
about = https://github.com/RAX-Anomaly/Anomaly-Mod-Configuration-Menu
[hard_dependencies]
;minimum allowed version, MCM will block playing if this version is not met
[soft_dependencies]
;prefered versions, for addons that support optional features or if you have an optional feature dependant on a newer version than your hard requiernemnt you can list both.
;MCM will provide a message about the listed addon being out of date if this is not met.
;also useful for informing ppl updated version of your other addons.
@@ -0,0 +1,258 @@
;If MCM keybinds displays a key diferent than what you entered, find the key that MCM displayed and change it to what you actually pressed.
;A bunch of keys that are not part of the standard US keyboard layout have been disabled by putting ; at the beggingin of thier line, if your keyboard supports them delete the ; to renenable
[eng]
-1 = UNBOUND
11 = 0
2 = 1
3 = 2
4 = 3
5 = 4
6 = 5
7 = 6
8 = 7
9 = 8
10 = 9
30 = A
78 = ADD
40 = APOSTROPHE
;221 = APPS
;145 = AT
;150 = AX
48 = B
14 = BACK
43 = BACKSLASH
46 = C
;58 = CAPITAL
;144 = CIRCUMFLEX
146 = COLON
51 = COMMA
;121 = CONVERT
32 = D
83 = DECIMAL
211 = DELETE
181 = DIVIDE
208 = DOWN
18 = E
207 = END
13 = EQUALS
;1 = ESCAPE ; mcm kebinds cannot use this key. donot renenable.
33 = F
59 = F1
68 = F10
87 = F11
88 = F12
100 = F13
101 = F14
102 = F15
60 = F2
61 = F3
62 = F4
63 = F5
64 = F6
65 = F7
66 = F8
67 = F9
34 = G
41 = GRAVE
35 = H
199 = HOME
23 = I
210 = INSERT
36 = J
37 = K
;112 = KANA
;148 = KANJI
38 = L
26 = LBRACKET
29 = LCONTROL
203 = LEFT
56 = LALT;LMENU
42 = LSHIFT
;219 = LWIN
50 = M
12 = MINUS
55 = MULTIPLY
49 = N
;209 = NEXT
;123 = NOCONVERT
69 = NUMLOCK
82 = NUMPAD0
79 = NUMPAD1
80 = NUMPAD2
81 = NUMPAD3
75 = NUMPAD4
76 = NUMPAD5
77 = NUMPAD6
71 = NUMPAD7
72 = NUMPAD8
73 = NUMPAD9
179 = NUMPADCOMMA
156 = NUMPADENTER
141 = NUMPADEQUALS
24 = O
25 = P
197 = PAUSE
52 = PERIOD
;201 = PRIOR
16 = Q
19 = R
27 = RBRACKET
157 = RCONTROL
28 = RETURN
205 = RIGHT
184 = RALT;RMENU
54 = RSHIFT
;220 = RWIN
31 = S
70 = SCROLL
39 = SEMICOLON
53 = SLASH
57 = SPACE
;149 = STOP
74 = SUBTRACT
;183 = SYSRQ
20 = T
15 = TAB
22 = U
;147 = UNDERLINE
;151 = UNLABELED
200 = UP
47 = V
17 = W
45 = X
21 = Y
;125 = YEN
44 = Z
340 = MOUSE4
341 = MOUSE5
343 = MOUSE6
343 = MOUSE7
344 = MOUSE8
[rus]
-1 = UNBOUND
11 = 0
2 = 1
3 = 2
4 = 3
5 = 4
6 = 5
7 = 6
8 = 7
9 = 8
10 = 9
30 = A
78 = ADD
40 = APOSTROPHE
;221 = APPS
;145 = AT
;150 = AX
48 = B
14 = BACK
43 = BACKSLASH
46 = C
;58 = CAPITAL
;144 = CIRCUMFLEX
146 = COLON
51 = COMMA
;121 = CONVERT
32 = D
83 = DECIMAL
211 = DELETE
181 = DIVIDE
208 = DOWN
18 = E
207 = END
13 = EQUALS
1 = ESCAPE
33 = F
59 = F1
68 = F10
87 = F11
88 = F12
100 = F13
101 = F14
102 = F15
60 = F2
61 = F3
62 = F4
63 = F5
64 = F6
65 = F7
66 = F8
67 = F9
34 = G
41 = GRAVE
35 = H
199 = HOME
23 = I
210 = INSERT
36 = J
37 = K
;112 = KANA
;148 = KANJI
38 = L
26 = LBRACKET
29 = LCONTROL
203 = LEFT
56 = LMENU
42 = LSHIFT
;219 = LWIN
50 = M
12 = MINUS
55 = MULTIPLY
49 = N
;209 = NEXT
;123 = NOCONVERT
69 = NUMLOCK
82 = NUMPAD0
79 = NUMPAD1
80 = NUMPAD2
81 = NUMPAD3
75 = NUMPAD4
76 = NUMPAD5
77 = NUMPAD6
71 = NUMPAD7
72 = NUMPAD8
73 = NUMPAD9
179 = NUMPADCOMMA
156 = NUMPADENTER
141 = NUMPADEQUALS
24 = O
25 = P
197 = PAUSE
52 = PERIOD
;201 = PRIOR
16 = Q
19 = R
27 = RBRACKET
157 = RCONTROL
28 = RETURN
205 = RIGHT
184 = RMENU
54 = RSHIFT
;220 = RWIN
31 = S
70 = SCROLL
39 = SEMICOLON
53 = SLASH
57 = SPACE
;149 = STOP
74 = SUBTRACT
;183 = SYSRQ
20 = T
15 = TAB
22 = U
;147 = UNDERLINE
;151 = UNLABELED
200 = UP
47 = V
17 = W
45 = X
21 = Y
;125 = YEN
44 = Z
340 = MOUSE4
341 = MOUSE5
343 = MOUSE6
343 = MOUSE7
344 = MOUSE8
@@ -0,0 +1,187 @@
<!--
Anomaly Mod Configuration Menu strings
-->
<string_table>
<string id="ui_mcm_desc_mcm">
<text>Welcome to Anomaly Mod Configuration Menu. By itself MCM does nothing. MCM provides a place for other mods/addons to display a settings UI.
\nTo the left you will see a list of mods/addons that are using MCM to do so.</text>
</string>
<string id="ui_mcm_desc_mcm2">
<text>Bugs with MCM or crashes with ui_mcm.script in the log are most likely caused by one of the mods/addons using MCM and should be reported to that mod/addon's author. </text>
</string>
<string id="ui_mm_menu_mcm">
<text>Mod Configuration Menu</text>
</string>
<string id="ui_mcm_menu_mcm">
<text>MCM</text>
</string>
<string id="ui_mcm_menu_mcm_about">
<text>About</text>
</string>
<string id="ui_mcm_mcm_mcm_about_reset">
<text>Reload all menus</text>
</string>
<string id="ui_mcm_mcm_mcm_about_reset_desc">
<text>Checking this and hitting apply will cause MCM to reload all menus. This is a debugging tool and shouldn't be necessary in the normal course of things.</text>
</string>
<string id="ui_mcm_menu_mcm_log">
<text>Logging</text>
</string>
<string id="ui_mcm_mcm_desc_log">
<text>This is a utility for addon makers that lets them move their logging out of the xray log and game console.
\nBecause I respect your concerns about lag and SSD write cycles I have provided some controls for you to tweak how the logging behaves.
\nLogs will be named after the script that creates them and the MCM session id number. They be created in appdata/logs/mcm/</text>
</string>
<string id="ui_mcm_mcm_mcm_log_enable">
<text>Enable MCM logging utility.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_enable_desc">
<text>Unchecking this will prevent any new logs from being created or updated. (Note changes may not take effect until after a new save game is loaded.)</text>
</string>
<string id="ui_mcm_mcm_mcm_log_numlogs">
<text>Number of log sessions to keep.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_numlogs_desc">
<text>When the number of logs created by a script exceeds this number older logs will be deleted. (Note log deletion will not happen if the game crashes.)</text>
</string>
<string id="ui_mcm_mcm_mcm_log_continuous">
<text>Allow continuous file writes.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_continuous_desc">
<text>Logs files are normally updated in batches. This can cause some information to be lost if the game crashes. An addon maker may request you check this box to allow their log to be updated immediately.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_savefreq">
<text>Time between Log auto saves in milliseconds.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_savefreq_desc">
<text>No matter what is set here logs will still be saved when entering assorted UI screens and saving/loading games.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_timestamp">
<text>Xray log time stamp frequency.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_timestamp_desc">
<text>MCM adds a time stamp to the xray log to make it easier to coordinate events between mcm logs and the xray log. This is the minimum time between those time stamps. If nothing else is printing to the console neither will mcm.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_debug_logging2">
<text>Enable Debug logging.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_debug_logging2_desc">
<text>This enables MCM's own debug logging and should be enabled before reporting bugs with MCM. Other addons may also use this setting to enable thier own logging.</text>
</string>
<string id="ui_mcm_menu_mcm_kb">
<text>MCM Key Binds.</text>
</string>
<string id="ui_mcm_menu_mcm_kb_main">
<text>Main.</text>
</string>
<string id="ui_mcm_mcm_desc_kb">
<text>MCM Key Binds work "Minecraft Style": click on the box, then hit a key. Clicking or Escape Key will cancel.
\nIf the key you see does not match the key you pressed, or MCM seems to ignore some keys, you likely need to modify mcm_key_localization.ltx to reflect your keyboard layout.
\nKeys that are assigned to more than one MCM Key Bind or to an engine key bind will be highlighted red</text>
</string>
<string id="ui_mcm_mcm_desc_kb2">
<text>A few notes on the red conflicting key coloring.
\n1. It may not matter. If the keys are used in two different UI's or if one key bind only triggers when also holding shift then the fact that the key is used twice doesn't matter.
\n2. MCM does not know what an addon may be doing with a key. YOU need to understand how an addon is using a key to know if a conflict is relevant.
\n3. For a single pending change the color updates correctly, for multiple pending changes it may not. Apply your changes and reopen MCM to verify correct conflict status.</text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_presstime">
<text>Long press multiplier.</text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_presstime_desc">
<text>Multiplier applied to Double tap window to determine How long a key needs to be held down to count as a long press or hold. Only applies to addons that use MCM to identify long key presses.</text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_dtaptime2">
<text>Double tap window.</text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_dtaptime2_desc">
<text>How soon a second press of a key needs to follow a first to count as a double tap of the key. Only applies to addons that use MCM to identify double key presses. This time can affect the input delay of some single key press events and should thereby be set as small as possible.</text>
</string>
<string id="ui_mcm_menu_mcm_all_kb">
<text>All keybinds.</text>
</string>
<string id="ui_mcm_mcm_desc_kb_all">
<text>This panel gathers all MCM key binds into one place, in the same order that the addons that add them appear on the left.
\nHowever this list cannot include additional settings from the addons panel that may affect how this key behaves.
\nAlways review the addon panel where they Key Bind was gathered from as well as that addons documentation. </text>
</string>
<string id="ui_mcm_mcm_desc_kb_all2">
<text>Pending changes on other panels will not be reflected on this panel, nor will pending settings on this panel be reflected on others.
\nApply your changes before and after using this panel. Failure to do so may result in undesired behavior.
\n\nA few notes on the red conflicting key coloring.
\n1. It may not matter. If the keys are used in two different UI's or if one key bind only triggers when also holding shift then the fact that the key is used twice doesn't matter.
\n2. MCM does not know what an addon may be doing with a key. YOU need to understand how an addon is using a key to know if a conflict is relevant.
\n3. For a single pending change the color updates correctly, for multiple pending changes it may not. Apply your changes and reopen MCM to verify correct conflict status.</text>
</string>
<string id="ui_mcm_menu_mcm_kb_conflicts">
<text>Key Bind Conflicts.</text>
</string>
<string id="ui_mcm_mcm_desc_kb_conflicts">
<text>This panel gathers all MCM key binds marked as conflicting into one place, sorted by key.
\nIf a key only appears on this list once it likely conflicts with an engine keybind. Those are listed in the normal Anomaly options.
\nHowever this list cannot include additional settings from the addons panel that may affect how this key behaves.
\nAlways review the addon panel where they Key Bind was gathered from as well as that addons documentation. </text>
</string>
<string id="ui_mcm_mcm_kb_modifier">
<text>With modifier key.</text>
</string>
<string id="ui_mcm_mcm_kb_modifier_desc">
<text>The above keybind will only activate if this key is also held down.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_none">
<text>No modifier.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_ctrl">
<text>Control key.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_shift">
<text>Shift key.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_alt">
<text>Alt key.</text>
</string>
<string id="ui_mcm_mcm_kb_mode">
<text>Input mode.</text>
</string>
<string id="ui_mcm_mcm_kb_mode_desc">
<text>The above keybind will activate if the key input in this manner.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mode_press">
<text>Simple Press.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mode_dtap">
<text>Double tap.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mode_hold">
<text>Long Press.</text>
</string>
</string_table>
@@ -0,0 +1,187 @@
<!--
Anomaly Mod Configuration Menu strings
-->
<string_table>
<string id="ui_mcm_desc_mcm">
<text>Добро пожаловать в меню конфигурации аномального мода. Сам по себе MCM ничего не делает. MCM предоставляет место для других модов / надстроек для отображения пользовательского интерфейса настроек.
\nСлева вы увидите список модов / дополнений, которые используют MCM для этого.</text>
</string>
<string id="ui_mcm_desc_mcm2">
<text>Ошибки с MCM или сбои с ui_mcm.script в журнале, скорее всего, вызваны одним из модов / дополнений, использующих MCM, и о них следует сообщать автору этого мода / дополнения. </text>
</string>
<string id="ui_mm_menu_mcm">
<text>Меню конфигурации мода</text>
</string>
<string id="ui_mcm_menu_mcm">
<text>MCM</text>
</string>
<string id="ui_mcm_menu_mcm_about">
<text>Обо</text>
</string>
<string id="ui_mcm_mcm_mcm_about_reset">
<text>Обновить все меню</text>
</string>
<string id="ui_mcm_mcm_mcm_about_reset_desc">
<text>Проверка этого и нажатие кнопки «Применить» заставит MCM перезагрузить все меню. Это инструмент для отладки, который в обычном режиме не нужен. </text>
</string>
<string id="ui_mcm_menu_mcm_log">
<text>журнал</text>
</string>
<string id="ui_mcm_mcm_desc_log">
<text>Это утилита для разработчиков аддонов, которая позволяет им вывести логирование из журнала рентгеновских лучей и игровой консоли.
\nПоскольку я уважаю ваше беспокойство по поводу задержек и циклов записи на SSD, я предоставил вам некоторые элементы управления, чтобы вы могли настроить, как ведет себя ведение журнала.
\nLЖурналы будут названы в честь сценария, который их создает, и идентификатора сеанса MCM. Они будут созданы в appdata/logs/mcm/</text>
</string>
<string id="ui_mcm_mcm_mcm_log_enable">
<text>Включите утилиту ведения журнала MCM.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_enable_desc">
<text>Снятие этого флажка предотвратит создание или обновление любых новых журналов. (Обратите внимание, что изменения могут вступить в силу только после загрузки нового сохранения игры.) </text>
</string>
<string id="ui_mcm_mcm_mcm_log_numlogs">
<text>Количество сохраняемых сеансов журнала.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_numlogs_desc">
<text>Когда количество журналов, созданных сценарием, превышает это количество, старые журналы будут удалены. (Обратите внимание, что удаление журнала не произойдет, если игра вылетит.) </text>
</string>
<string id="ui_mcm_mcm_mcm_log_continuous">
<text>Разрешить непрерывную запись в файл.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_continuous_desc">
<text>Файлы журналов обычно обновляются партиями. Это может привести к потере некоторой информации в случае сбоя игры. Производитель дополнений может попросить вас установить этот флажок, чтобы разрешить немедленное обновление их журнала. </text>
</string>
<string id="ui_mcm_mcm_mcm_log_savefreq">
<text>Время между автоматическим сохранением журнала в миллисекундах.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_savefreq_desc">
<text>Независимо от того, что здесь установлено, журналы все равно будут сохраняться при входе в различные экраны пользовательского интерфейса и при сохранении / загрузке игр. </text>
</string>
<string id="ui_mcm_mcm_mcm_log_timestamp">
<text>Частота отметок времени в рентгеновском журнале.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_timestamp_desc">
<text>MCM добавляет метку времени к журналу рентгеновского снимка, чтобы упростить координацию событий между журналами mcm и журналом рентгеновского снимка. Это минимальное время между этими отметками времени. Если на консоль ничего не выводится, то и mcm не будет. </text>
</string>
<string id="ui_mcm_mcm_mcm_log_debug_logging2">
<text>Включите ведение журнала отладки.</text>
</string>
<string id="ui_mcm_mcm_mcm_log_debug_logging2_desc">
<text>Это включает собственное ведение журнала отладки MCM и должно быть включено перед сообщением об ошибках с MCM. Другие надстройки также могут использовать этот параметр, чтобы включить собственное ведение журнала. </text>
</string>
<string id="ui_mcm_menu_mcm_kb">
<text>Привязки клавиш MCM.</text>
</string>
<string id="ui_mcm_menu_mcm_kb_main">
<text>Главный.</text>
</string>
<string id="ui_mcm_mcm_desc_kb">
<text>Привязки клавиш MCM работают в стиле Minecraft: нажмите на поле, затем нажмите клавишу. Нажатие или клавиша Escape отменит.
\nЕсли отображаемая вами клавиша не соответствует нажатой вами клавише или MCM игнорирует некоторые клавиши, вам, вероятно, потребуется изменить mcm_key_localization.ltx, чтобы отразить вашу раскладку клавиатуры.
\nКлючи, которые назначены более чем одной привязке клавиш MCM или привязке клавиш двигателя, будут выделены красным</text>
</string>
<string id="ui_mcm_mcm_desc_kb2">
<text>Несколько замечаний по поводу красного цвета конфликтующих клавиш.
\n1. Это может не иметь значения. Если ключи используются в двух разных пользовательских интерфейсах или если привязка одной клавиши срабатывает только при одновременном удерживании сдвига, то тот факт, что клавиша используется дважды, не имеет значения.
\n2. MCM не знает, что надстройка может делать с ключом. ВАМ нужно понимать, как надстройка использует ключ, чтобы знать, актуален ли конфликт.
\n3. Для одного ожидающего изменения цвет обновляется правильно, для нескольких ожидающих изменений - нет. Примените изменения и снова откройте MCM, чтобы проверить правильность статуса конфликта. </text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_presstime">
<text>Множитель при длительном нажатии.</text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_presstime_desc">
<text>Множитель, примененный к окну двойного касания, чтобы определить, сколько времени необходимо удерживать клавишу, чтобы считаться длительным нажатием или удержанием. Применимо только к надстройкам, которые используют MCM для определения долгих нажатий клавиш. </text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_dtaptime2">
<text>Дважды коснитесь окна.</text>
</string>
<string id="ui_mcm_mcm_mcm_kb_mcm_kb_main_dtaptime2_desc">
<text>Время, через которое второе нажатие клавиши должно следовать за первым, считается двойным нажатием клавиши. Применимо только к надстройкам, которые используют MCM для идентификации двойных нажатий клавиш. Это время может повлиять на задержку ввода некоторых событий нажатия одной клавиши и поэтому должно быть установлено как можно меньшим. </text>
</string>
<string id="ui_mcm_menu_mcm_all_kb">
<text>Все привязки клавиш.</text>
</string>
<string id="ui_mcm_mcm_desc_kb_all">
<text>Эта панель собирает все привязки клавиш MCM в одном месте в том же порядке, в котором добавляющие их надстройки отображаются слева.
\nОднако этот список не может включать дополнительные настройки из панели надстроек, которые могут повлиять на поведение этого ключа.
\nВсегда просматривайте панель аддонов, откуда они взяли Key Bind, а также документацию по аддонам. </text>
</string>
<string id="ui_mcm_mcm_desc_kb_all2">
<text>Незавершенные изменения на других панелях не будут отражены на этой панели, а ожидающие настройки на этой панели не будут отражены на других.
\nПримените изменения до и после использования этой панели. Несоблюдение этого правила может привести к нежелательному поведению.
\n\nНесколько замечаний по поводу красного цвета конфликтующих клавиш.
\n1. Это может не иметь значения. Если ключи используются в двух разных пользовательских интерфейсах или если привязка одной клавиши срабатывает только при одновременном удерживании сдвига, то тот факт, что клавиша используется дважды, не имеет значения.
\n2. MCM не знает, что надстройка может делать с ключом. ВАМ нужно понимать, как надстройка использует ключ, чтобы знать, актуален ли конфликт.
\n3. Для одного ожидающего изменения цвет обновляется правильно, для нескольких ожидающих изменений - нет. Примените изменения и снова откройте MCM, чтобы проверить правильность статуса конфликта. </text>
</string>
<string id="ui_mcm_menu_mcm_kb_conflicts">
<text>Конфликты привязки клавиш.</text>
</string>
<string id="ui_mcm_mcm_desc_kb_conflicts">
<text>На этой панели собраны все привязки клавиш MCM, помеченные как конфликтующие, в одном месте, отсортированные по ключам.
\nЕсли ключ появляется в этом списке только один раз, он, вероятно, конфликтует с клавиатурой движка. Они перечислены в обычных параметрах аномалии..
\nОднако этот список не может включать дополнительные настройки из панели надстроек, которые могут повлиять на поведение этого ключа.
\nВсегда просматривайте панель аддонов, откуда они взяли Key Bind, а также документацию по аддонам. </text>
</string>
<string id="ui_mcm_mcm_kb_modifier">
<text>С ключом-модификатором.</text>
</string>
<string id="ui_mcm_mcm_kb_modifier_desc">
<text>Вышеупомянутая комбинация клавиш активируется только в том случае, если эта клавиша также удерживается.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_none">
<text>Без модификатора.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_ctrl">
<text>Клавиша управления.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_shift">
<text>Клавиша Shift.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mod_alt">
<text>Клавиша Alt.</text>
</string>
<string id="ui_mcm_mcm_kb_mode">
<text>Режим ввода.</text>
</string>
<string id="ui_mcm_mcm_kb_mode_desc">
<text>Вышеупомянутая комбинация клавиш активируется, если клавиша вводится таким образом.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mode_press">
<text>Простая пресса.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mode_dtap">
<text>Двойное нажатие.</text>
</string>
<string id="ui_mcm_lst_mcm_kb_mode_hold">
<text>Длительное нажатие.</text>
</string>
</string_table>
@@ -0,0 +1 @@
#include "ui\ui_mcm_16.xml"
@@ -0,0 +1,211 @@
<w>
<background x="0" y="0" width="1024" height="768">
<auto_static x="0" y="0" width="1024" height="768" stretch="1">
<texture x="0" y="0" width="1280" height="768">ui\ui_actor_main_menu_one</texture>
</auto_static>
</background>
<main x="51" y="23" width="923" height="676">
<frame x="0" y="0" width="923" height="676" stretch="1">
<texture>ui_options_background</texture>
</frame>
<cap_right x="638" y="16" width="275" height="25" stretch="1">
<text complex_mode="1" r="250" g="250" b="250" align="c" vert_align="c" font="letterica18"/>
</cap_right>
<cap_1 x="12" y="16" width="102" height="25" stretch="1">
<text complex_mode="1" r="150" g="150" b="250" align="c" vert_align="c" font="letterica16"/>
</cap_1>
<cap_2 x="123" y="16" width="102" height="25" stretch="1">
<text complex_mode="1" r="150" g="150" b="250" align="c" vert_align="c" font="letterica16"/>
</cap_2>
<cap_3 x="233" y="16" width="102" height="25" stretch="1">
<text complex_mode="1" r="150" g="150" b="250" align="c" vert_align="c" font="letterica16"/>
</cap_3>
<!-- 51 -->
<tree_1 x="22" y="61" width="94" height="525" right_ident="0" left_ident="0" top_indent="0" bottom_indent="0" vert_interval="0" always_show_scroll="0"/>
<tree_2 x="128" y="61" width="94" height="525" right_ident="0" left_ident="0" top_indent="0" bottom_indent="0" vert_interval="0" always_show_scroll="0"/>
<tree_3 x="234" y="61" width="94" height="525" right_ident="0" left_ident="0" top_indent="0" bottom_indent="0" vert_interval="0" always_show_scroll="0"/>
<st_tree x="0" y="0" width="94" height="25"/>
<frame_1 x="22" y="63" width="92" height="499" stretch="1">
<texture r="0" g="0" b="0" a="150">ui_icons_PDA_tooltips</texture>
</frame_1>
<frame_2 x="133" y="63" width="92" height="499" stretch="1">
<texture r="0" g="0" b="0" a="150">ui_icons_PDA_tooltips</texture>
</frame_2>
<frame_3 x="243" y="63" width="92" height="499" stretch="1">
<texture r="0" g="0" b="0" a="150">ui_icons_PDA_tooltips</texture>
</frame_3>
<cap_preset x="638" y="16" width="80" height="25" stretch="1">
<text r="180" g="180" b="180" align="c" vert_align="c" font="letterica18">ui_mm_preset</text>
</cap_preset>
<preset x="718" y="19" width="176" height="9020" stretch="1">
<list_font r="170" g="170" b="170" font="letterica16"/>
<texture>ui_inGame2_edit_box_2</texture>
<text_color>
<e r="170" g="170" b="170"/>
<d r="70" g="70" b="70"/>
</text_color>
</preset>
<scroll x="340" y="60" width="573" height="606" right_ident="0" left_ident="0" top_indent="0" bottom_indent="0" vert_interval="0" always_show_scroll="0"/>
<st x="0" y="0" width="573" height="40"/>
<btn_accept x="12" y="626" width="80" height="34" stretch="1">
<text align="c" font="letterica18">ui_mm_apply</text>
<texture>ui_button_ordinary</texture>
</btn_accept>
<btn_reset x="92" y="626" width="80" height="34" stretch="1">
<text align="c" font="letterica18">ui_mm_reset</text>
<texture>ui_button_ordinary</texture>
</btn_reset>
<btn_default x="172" y="626" width="80" height="34" stretch="1">
<text align="c" font="letterica18">ui_mm_default</text>
<texture>ui_button_ordinary</texture>
</btn_default>
<btn_cancel x="252" y="626" width="80" height="34" stretch="1">
<text align="c" font="letterica18">ui_mm_cancel</text>
<texture>ui_button_ordinary</texture>
</btn_cancel>
<notify x="12" y="583" width="323" height="34" stretch="1">
<text complex_mode="1" r="250" g="150" b="75" align="c" vert_align="c" font="letterica18"/>
</notify>
<notify_frame x="15" y="587" width="317" height="30" stretch="1">
<texture r="0" g="0" b="0" a="150">ui_icons_PDA_dialog_frame</texture>
</notify_frame>
</main>
<elements>
<btn_list x="0" y="0" width="93" height="22" stretch="1">
<texture>ui_checkbox_TabLED</texture>
</btn_list>
<txt_list x="15" y="0" width="93" height="22" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="l" vert_align="c" font="letterica16"/>
</txt_list>
<block x="0" y="0" width="573" height="616" stretch="1">
<text complex_mode="1" r="250" g="100" b="100" align="c" vert_align="c" font="letterica18"/>
</block>
<cap x="10" y="5" width="282" height="30" stretch="1">
<text r="170" g="170" b="170" font="letterica16" align="l" vert_align="c"></text>
</cap>
<btn_all x="210" y="7" width="60" height="23" stretch="1">
<texture>ui_button_ordinary</texture>
</btn_all>
<cap_all x="210" y="7" width="60" height="23" stretch="1">
<text r="170" g="170" b="170" align="c" vert_align="c" font="letterica16">ui_mm_btn_apply_all</text>
</cap_all>
<frame_button x="90" y="20" width="400" height="30" stretch="1">
<texture>ui_stroketextbox</texture>
</frame_button>
<btn_button x="90" y="20" width="400" height="30" stretch="1">
<texture>ui_button_inv</texture>
</btn_button>
<cap_button x="90" y="20" width="400" height="30" stretch="1">
<text r="170" g="170" b="170" font="letterica18" align="c" vert_align="c"></text>
</cap_button>
<frame_key_button x="292" y="5" width="100" height="30" stretch="1">
<texture>ui_stroketextbox</texture>
</frame_key_button>
<btn_key_button x="292" y="5" width="100" height="30" stretch="1">
<texture>ui_button_inv</texture>
</btn_key_button>
<txt_key_button x="292" y="5" width="100" height="30" stretch="1">
<text r="170" g="170" b="170" font="letterica18" align="c" vert_align="c"></text>
</txt_key_button>
<line x="10" y="5" width="563" height="16" stretch="1">
<texture>ui_inGame2_opt_slider_bar_back</texture>
</line>
<image x="10" y="0" width="563" height="50" stretch="1"/>
<desc x="10" y="0" width="563" height="50" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="l" vert_align="c" font="letterica16"/>
</desc>
<title_l x="20" y="0" width="558" height="50" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="l" vert_align="c" font="graffiti22"/>
</title_l>
<title_c x="20" y="0" width="558" height="50" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="c" vert_align="c" font="graffiti22"/>
</title_c>
<title_r x="20" y="0" width="558" height="50" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="r" vert_align="c" font="graffiti22"/>
</title_r>
<slide x="5" y="0" width="563" height="50" stretch="1">
<line_1 x="0" y="-8" width="563" height="16" stretch="1">
<texture>ui_inGame2_opt_slider_bar_back</texture>
</line_1>
<pic x="0" y="0" width="563" height="50" stretch="1"/>
<txt x="282" y="0" width="282" height="50" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="c" vert_align="c" font="graffiti22"/>
</txt>
<line_2 x="0" y="42" width="563" height="16" stretch="1">
<texture>ui_inGame2_opt_slider_bar_back</texture>
</line_2>
</slide>
<check x="292" y="8" width="35" height="30" stretch="1">
<texture>ui_inGame2_checkbox</texture>
</check>
<list x="292" y="8" width="252" height="9020" stretch="1" list_length="10">
<list_font r="170" g="170" b="170" font="letterica16"/>
<text_color>
<e r="170" g="170" b="170"/>
<d r="70" g="70" b="70"/>
</text_color>
</list>
<input x="292" y="5" width="252" height="30">
<text x="5" font="medium" vert_align="c" align="l"/>
<texture>ui_inGame2_edit_box_2</texture>
</input>
<track x="292" y="8" width="242" height="16" stretch="1" step = "1.0"/>
<track_value x="533" y="5" width="40" height="30" stretch="1">
<text complex_mode="1" r="200" g="200" b="250" align="c" vert_align="c" font="letterica16"/>
</track_value>
<edit x="292" y="5" width="100" height="30" align="l">
<text x="5" r="170" g="170" b="170" font="letterica16" vert_align="c" align="1"/>
<auto_static x="0" y="0" width="100" height="30" stretch="1">
<texture a="255" r="26" g="34" b="26">ui\ui_console</texture>
</auto_static>
</edit>
<radio_horz x="292" y="5" width="272" height="40" stretch="1">
<btn x="0" y="0" width="35" height="30" stretch="1">
<texture>ui_radio</texture>
</btn>
<txt x="-30" y="30" width="90" height="10" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="c" vert_align="c" font="letterica16"/>
</txt>
</radio_horz>
<radio_vert x="292" y="5" width="272" height="1000" stretch="1">
<btn x="0" y="0" width="35" height="30" stretch="1">
<texture>ui_radio</texture>
</btn>
<txt x="40" y="30" width="200" height="30" stretch="1">
<text complex_mode="1" r="200" g="200" b="200" align="l" vert_align="c" font="letterica16"/>
</txt>
</radio_vert>
</elements>
</w>
@@ -0,0 +1 @@
#include "ui\ui_mm_main_16.xml"
@@ -0,0 +1,134 @@
<w>
<background x="0" y="0" width="1024" height="768">
<auto_static x="0" y="0" width="1024" height="768" stretch="1">
<texture x="0" y="0" width="1280" height="768">ui\ui_actor_main_menu</texture>
</auto_static>
<auto_static x="15" y="666" width="55" height="64" stretch="1">
<texture>ui\moty2018</texture>
</auto_static>
<auto_static x="70" y="666" width="55" height="64" stretch="1">
<texture>ui\moty2019</texture>
</auto_static>
<auto_static x="125" y="666" width="55" height="64" stretch="1">
<texture>ui\moty2022</texture>
</auto_static>
<auto_static x="180" y="666" width="55" height="64" stretch="1">
<texture>LogoAMCM.dds</texture>
</auto_static>
</background>
<shniaga_wnd x="400" y="419" width="392" height="280">
<buttons_region x="8" y="0" width="220" height="380" always_show_scroll="false" vert_interval="4"/>
<shniaga x="7" y="-20" width="219" height="61" stretch="1">
<texture>ui_inGame2_slider</texture>
<magnifire x="27" y="18" width="162" height="24" stretch="1">
<texture>ui_magnifier2</texture>
<y_offset>1</y_offset>
</magnifire>
</shniaga>
</shniaga_wnd>
<button h="24"/>
<menu_main btn_height="34" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_newgame" caption="ui_mm_newgame" />
<btn name="btn_load" caption="ui_mm_load_game" />
<btn name="btn_lastsave" caption="ui_mm_last_save" />
<btn name="btn_options" caption="ui_mm_options_n" />
<btn name="btn_mcm" caption="ui_mm_menu_mcm" />
<btn name="btn_originals" caption="ui_mm_originals" />
<btn name="btn_quit" caption="ui_mm_quit2windows" />
</menu_main>
<menu_network_game btn_height="30" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_internet" caption="ui_mp_internet" />
<btn name="btn_localnet" caption="ui_mp_localnet" />
<btn name="btn_new_back" caption="ui_mm_back" />
</menu_network_game>
<menu_main_logout btn_height="30" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_newgame" caption="ui_mm_newgame" />
<btn name="btn_load" caption="ui_mm_load_game" />
<btn name="btn_logout" caption="ui_mm_logout" />
<btn name="btn_options" caption="ui_mm_options_n" />
<btn name="btn_mcm" caption="ui_mm_menu_mcm" />
<btn name="btn_quit" caption="ui_mm_quit2windows" />
</menu_main_logout>
<menu_main_last_save btn_height="30" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_newgame" caption="ui_mm_newgame" />
<btn name="btn_load" caption="ui_mm_load_game" />
<btn name="btn_lastsave" caption="ui_mm_last_save" />
<btn name="btn_options" caption="ui_mm_options_n" />
<btn name="btn_mcm" caption="ui_mm_menu_mcm" />
<btn name="btn_quit" caption="ui_mm_quit2windows" />
</menu_main_last_save>
<menu_new_game btn_height="34" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_novice" caption="ui_mm_novice" />
<btn name="btn_stalker" caption="ui_mm_stalker" />
<btn name="btn_veteran" caption="ui_mm_veteran" />
<btn name="btn_master" caption="ui_mm_master" />
<btn name="btn_new_back" caption="ui_mm_back" />
</menu_new_game>
<menu_main_single btn_height="34" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_ret" caption="ui_mm_return_game" />
<btn name="btn_lastsave" caption="ui_mm_last_save" />
<btn name="btn_load" caption="ui_mm_load_game" />
<btn name="btn_save" caption="ui_mm_save_game" />
<btn name="btn_options" caption="ui_mm_options_n" />
<btn name="btn_mcm" caption="ui_mm_menu_mcm" />
<btn name="btn_quit_to_mm" caption="ui_mm_quit_game" />
<btn name="btn_quit" caption="ui_mm_quit2windows" />
</menu_main_single>
<menu_main_single_dead btn_height="34" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_lastsave" caption="ui_mm_last_save" />
<btn name="btn_load" caption="ui_mm_load_game" />
<btn name="btn_options" caption="ui_mm_options_n" />
<btn name="btn_mcm" caption="ui_mm_menu_mcm" />
<btn name="btn_quit_to_mm" caption="ui_mm_quit_game" />
<btn name="btn_quit" caption="ui_mm_quit2windows" />
</menu_main_single_dead>
<menu_main_mm btn_height="34" font="graffiti19" a="255" r="240" g="240" b="240">
<btn name="btn_ret" caption="ui_mm_return_game" />
<btn name="btn_options" caption="ui_mm_options_n" />
<btn name="btn_mcm" caption="ui_mm_menu_mcm" />
<btn name="btn_quit_to_mm" caption="ui_mm_disconnect" />
<btn name="btn_quit" caption="ui_mm_quit2windows" />
</menu_main_mm>
<menu_sound random="0" >
<!--whell_sound>ui_menu_click</whell_sound-->
<whell_click>ui_menu_click</whell_click>
<!--menu_music>music\_anomaly_heifehen_defenders_of_the_barrier</menu_music-->
<menu_music>music\_anomaly_ilya_ponomarenko_day_one</menu_music>
</menu_sound>
<static_version x="14" y="740">
<text align="l" font="letterica16" r="0" g="0" b="0" complex_mode="0"/>
</static_version>
<static_disclaimer x="256" y="640" width="512" height="100">
<text align="c" font="letterica16" r="0" g="0" b="0" complex_mode="1"/>
</static_disclaimer>
<msg_wnd x="0" y="0" width="210" height="100">
<background x="0" y="0" width="210" height="100">
<texture>ui_icons_PDA_tooltips</texture>
</background>
<text x="20" y="20" width="190" height="100">
<text font="letterica18" color="ui_6" complex_mode="1" align="l" vert_align="t"/>
</text>
</msg_wnd>
</w>
@@ -0,0 +1,104 @@
--[[
------------------------------------------------------------
-- ---
-- MCM Savefile Storage
-- ---
-- Savefile-specific persistent MCM configuration storage
-- You are free to do with this file as you want, as long as you keep this header intact.
--
-- Version 1.0 for Anomaly 1.5.1 / MCM 1.3
-- By dph-hcl
------------------------------------------------------------
USAGE
--
Usually the only thing you need to do is call register_module(mod) from on_game_start() in your addon.
The parameter "mod" here is the ID of the tree you return on_mcm_load() in your script.
You may want to check for existence of "dph_mcm_save_storage" beforehand, unless you distribute this script with your addon.
For example:
function on_mcm_load()
op = { id="example_example", ,gr={ ... } }
return op
end
function on_game_start()
if dph_mcm_save_storage then
dph_mcm_save_storage.register_module("example_example")
end
end
And that's it. All config options inside that tree are now saved/loaded with the players savefile.
You can also save only a subset of your options, or everything in a collection by passing the correct path as parameter:
For example:
-- this isn't any different than the above example,
-- but since "example_collection" is a collection name the path will match all options starting with example_collection/
dph_mcm_save_storage.register_module("example_collection")
-- this will match "example_option1" in the tree "example_example"
dph_mcm_save_storage.register_module("example_example/example_option1")
-- this will match everything in the tree "example_example" belonging to "example_collection"
dph_mcm_save_storage.register_module("example_collection/example_example")
And so on. It'll simply use all options that match the path you pass register_module, regardless of its semantics.
]]--
local modules = {}
function register_module(mod)
m = tostring(mod)
if (not m) then
return
end
table.insert(modules, mod)
end
local function compare_paths(mt, pt)
m = tostring(mt)
p = tostring(pt)
if (not m) or (not p) then
return
end
local mm = str_explode(m, "/")
local pp = str_explode(p, "/")
for i, seg in ipairs(mm) do
if (not pp[i]) or (seg ~= pp[i]) then
return false
end
return true
end
end
function load_state(data)
local t = axr_main.config:collect_section("mcm")
for p, v in pairs(t) do
for i, m in ipairs(modules) do
if not data[m] then
goto continue
end
if compare_paths(m, p) then
ui_mcm.set(p, (data[m][p] or false))
end
::continue::
end
end
end
function save_state(data)
local t = axr_main.config:collect_section("mcm")
for p, v in pairs(t) do
for i, m in ipairs(modules) do
if not data[m] then
data[m] = {}
end
if compare_paths(m, p) then
data[m][p] = ui_mcm.get(p)
end
end
end
end
function on_game_start()
RegisterScriptCallback("save_state", save_state)
RegisterScriptCallback("load_state", load_state)
end
@@ -0,0 +1,231 @@
--[[
MCM Logging Utility
17DEC2021
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License
Author: RavenAscendant
--]]
--[[
Usage:
log = mcm_log.new("prefix")
Log files are created at appdata/logs/mcm and are named after the script that created them.
Because of this multiple log objects created in one script function more like channels with thier output to the shared file identified by the provided prefix.
Each log object must be individualy enabled. This allows for easy control of diferent levels of logging
err = mcm_log.new("ERR")
err.enabled = true
msg = mcm_log.new("MSG")
msg.enabled = true
A log object can be flagged to save the log file every line. (continuous logginf must also be enabled by the user in the MCM settings)
err.continuous = true
Three functions are provided
log(fmt) this function takes the same input as the anomaly printf it will write that text to a line in the log file
that line will be prefaced with the log objects pfrefix and the time_continual time stamp.
msg:log("hello %s", "world")
Oputput: MSG |22877|| hello world
printf(fmt) behaves just like log except that it will print to the xray log and console as well. (printing to the console will still work even if user disables MCM logging. Printing to the console will not happen if the log object is not enabled)
msg:printf(fmt)
lastly log_table(tbl, name) formats and prints a table to the log
changelog
1.0.0 inital
1.0.1 removed unused ltx, corected callback.
1.0.2 adding error handeling to more file operations
--]]
local mcm_path = "mcm/mcm_log/"
local NUMLOGS = axr_main.config:r_value("mcm", mcm_path.."numlogs", 2, 2)
local LOG_SAVE_FREQUENCY = axr_main.config:r_value("mcm", mcm_path.."savefreq", 2, 1000)
local CONTINUOUS_ENABLED = axr_main.config:r_value("mcm", mcm_path.."continuous", 1, false)
local TIMESTAMP_FREQ = axr_main.config:r_value("mcm", mcm_path.."timestamp", 2, 1000)
local logging_enabled = axr_main.config:r_value("mcm", mcm_path.."enable", 1, true)
local string_gsub = string.gsub
local files = {}
local PATH = getFS():update_path("$logs$","mcm")
local last_console = 0
local flush_time = 0
local function write_log(file, tc, prefix, fmt, continuous)
if not (logging_enabled and file) then return end
local txt = prefix.."\t|"..tc.."||" .. fmt.."\n"
file:write(txt)
if continuous and CONTINUOUS_ENABLED then
file:flush()
end
end
class "MCM_Log"
function MCM_Log:__init(prefix)
self.prefix = prefix or ""
self.enabled = false
self.continuous = false
local info = debug.getinfo(4,"S")
local path_list = str_explode(info.short_src, "\\")
local name = path_list and str_explode(path_list[#path_list], "%.")
self.fname = name and name[1] or "mcm_log_fail"
end
function MCM_Log:Open_file()
if (not files[self.fname]) and logging_enabled then
local file, msg = io.open(PATH.."/"..self.fname.."_"..ui_mcm.get_session_id()..".log","a+")
if not file then
printf("!ERROR MCM Logs unable to create log file. Manualy creating the directory appdata/logs/mcm/ may solve this issue.")
return
end
files[self.fname] = file
files[self.fname]:write("======================\n")
files[self.fname]:write("=="..os.date("%d%b%Y %X") .."==\n")
files[self.fname]:write("=Continuous logging:=\n")
if not CONTINUOUS_ENABLED then
files[self.fname]:write("=========FALSE========\n")
else
files[self.fname]:write("=========TRUE=========\n")
end
files[self.fname]:write("======================\n")
files[self.fname]:flush()
end
end
function MCM_Log:log(fmt, ...)
if not (self.enabled and logging_enabled )then return false end
if not (fmt) then return end
local fmt = tostring(fmt)
self:Open_file()
if (select('#',...) >= 1) then
local i = 0
local p = {...}
local function sr(a)
i = i + 1
if (type(p[i]) == 'userdata') then
if (p[i].x and p[i].y) then
return vec_to_str(p[i])
end
return 'userdata'
end
return tostring(p[i])
end
fmt = string_gsub(fmt,"%%s",sr)
end
local tc = time_continual()
write_log(files[self.fname], tc , self.prefix, fmt, self.continuous)
return tc
end
function MCM_Log:printf(fmt, ...)
if self.enabled then
local tc = self:log(fmt, ...) or time_continual()
last_console = tc
printf("%s|%s|%s||"..tostring(fmt), self.prefix, self.fname, tc, ...)
return tc
end
end
function MCM_Log:log_table(tbl, name)
if not (self.enabled and logging_enabled )then return false end
if type(tbl) ~= "table" then return end
name = name or tostring(tbl)
local txt = utils_data.print_table(tbl, false, true)
return self:log("TABLE:%s \n%s", name, txt)
end
function new(prefix)
local temp = MCM_Log(prefix)
return temp
end
local function flush_logs()
flush_time = time_continual()
for _,file in pairs(files) do
file:flush()
end
end
function fsgame_append(str,ap)
path = getFS():update_path("$fs_root$","fsgame.ltx")
local fsg = io.open(path,"a+")
local data = fsg:read("*all")
if not (string.find(data,str)) then
fsg:write("\n"..ap)
fsg:close()
return false
end
fsg:close()
return true
end
function close_logs()
fsgameupdated = fsgame_append("mcmlogs", "$mcmlogs$ = true | false | $logs$| mcm\\")
--printf("MCM_Log close fsgameupdated:%s",fsgameupdated)
if not fsgameupdated then return end
for fname,file in pairs(files) do
pcall(function() file:close() end )
local f = getFS()
local flist = f:file_list_open_ex("$mcmlogs$",bit_or(FS.FS_ListFiles,FS.FS_RootOnly),fname.."*")
local f_cnt = flist:Size()
flist:Sort(5)
for it=2, f_cnt-1 do
local file = flist:GetAt(it)
pcall(function() f:file_delete(f:update_path("$mcmlogs$",file:NameFull())) end)
end
end
end
function timed_flush()
if time_continual() - flush_time > LOG_SAVE_FREQUENCY then
flush_logs()
end
end
local pf = _G.printf
function _G.printf(...)
if (time_continual() - last_console > TIMESTAMP_FREQ) and logging_enabled then
last_console = time_continual()
pf("Time continual is:%s",last_console)
end
pf(...)
end
local function on_option_change(mcm)
if mcm then
NUMLOGS = axr_main.config:r_value("mcm", mcm_path.."numlogs", 2, 2)
LOG_SAVE_FREQUENCY = axr_main.config:r_value("mcm", mcm_path.."savefreq", 2, 2)
CONTINUOUS_ENABLED = axr_main.config:r_value("mcm", mcm_path.."continuous", 1, false)
TIMESTAMP_FREQ = axr_main.config:r_value("mcm", mcm_path.."timestamp", 2, 2)
logging_enabled = axr_main.config:r_value("mcm", mcm_path.."enable", 1, true)
end
end
function on_game_start()
flush_logs()
RegisterScriptCallback("on_before_level_changing",flush_logs)
RegisterScriptCallback("actor_on_before_death",flush_logs)
RegisterScriptCallback("GUI_on_show",flush_logs)
RegisterScriptCallback("GUI_on_hide",flush_logs)
RegisterScriptCallback("save_state",flush_logs)
RegisterScriptCallback("main_menu_on_init",flush_logs)
RegisterScriptCallback("main_menu_on_quit",flush_logs)
RegisterScriptCallback("on_option_change",on_option_change)
AddUniqueCall(timed_flush)
end
@@ -0,0 +1,411 @@
--[[
File: UI_MAIN_MENU.SCRIPT
Description: Load Dialog for STALKER
Created: 28.10.2004
Last edit: 10.01.2015
Copyright: 2004 GSC Game World
Author: Serhiy Vynnychenko (narrator@gsc-game.kiev.ua)
Version: 0.9
-----------------------------------------------------
Modified by Tronex
2018/7/17 - Prevent saving when hardcore save modes are active
2019/10/28 - New keybinds and actions
--]]
class "main_menu" (CUIScriptWnd)
function main_menu:__init() super()
math.randomseed(device():time_continual())
self.mbox_mode = 0
ui_mcm.init_opt_base()
self:InitControls()
self:InitCallBacks()
SendScriptCallback("main_menu_on_init",self)
RegisterScriptCallback("on_localization_change",self)
if not (level.present()) then
xrs_debug_tools.on_game_start()
end
end
function main_menu:__finalize()
end
function main_menu:InitControls()
self:SetWndRect (Frect():set(0,0,1024,768))
local xml = CScriptXmlInit()
xml:ParseFile ("ui_mm_main.xml")
xml:InitStatic ("background", self)
self.shniaga = xml:InitMMShniaga("shniaga_wnd",self);
self.message_box = CUIMessageBoxEx()
self:Register (self.message_box, "msg_box")
local _ver = xml:InitStatic ("static_version",self)
local mm = _G.main_menu.get_main_menu()
_ver:TextControl():SetTextColor (GetARGB(190, 190, 190, 190))
local flavor_name = ""
if anomaly_flavor then
flavor_name = " - " .. anomaly_flavor.get_flavor()
end
_ver:TextControl():SetText (game.translate_string("ui_st_game_version") .. flavor_name .. (DEV_DEBUG and " (Debug mode - Press F1 for help)" or ""))
local _disc = xml:InitStatic ("static_disclaimer",self)
_disc:TextControl():SetTextColor(GetARGB(223, 223, 223, 223))
_disc:TextControl():SetText (game.translate_string("ui_mm_disclaimer"))
-- Message Window
self.msg_wnd = xml:InitFrame("msg_wnd:background",self)
self.msg_wnd:SetAutoDelete(false)
self.msg_wnd_text = xml:InitTextWnd("msg_wnd:text",self.msg_wnd)
self.msg_wnd_text:SetTextAlignment(2)
self.msg_wnd:Show(false)
self.msg_wnd:SetColor(GetARGB(255,0,0,0))
end
function main_menu:InitCallBacks()
self:AddCallback("btn_newgame", ui_events.BUTTON_CLICKED, self.OnButton_new_game, self)
self:AddCallback("btn_options", ui_events.BUTTON_CLICKED, self.OnButton_options_clicked, self)
self:AddCallback("btn_mcm", ui_events.BUTTON_CLICKED, self.OnButton_mcm_clicked, self)
self:AddCallback("btn_originals", ui_events.BUTTON_CLICKED, self.OnButton_originals_clicked, self)
self:AddCallback("btn_load", ui_events.BUTTON_CLICKED, self.OnButton_load_clicked, self)
self:AddCallback("btn_save", ui_events.BUTTON_CLICKED, self.OnButton_save_clicked, self)
self:AddCallback("btn_quit", ui_events.BUTTON_CLICKED, self.OnButton_quit_clicked, self)
self:AddCallback("btn_quit_to_mm", ui_events.BUTTON_CLICKED, self.OnButton_disconnect_clicked, self)
self:AddCallback("btn_ret", ui_events.BUTTON_CLICKED, self.OnButton_return_game, self)
self:AddCallback("btn_lastsave", ui_events.BUTTON_CLICKED, self.OnButton_last_save, self)
-- message box
self:AddCallback("msg_box", ui_events.MESSAGE_BOX_OK_CLICKED, self.OnMsgOk, self)
self:AddCallback("msg_box", ui_events.MESSAGE_BOX_CANCEL_CLICKED, self.OnMsgCancel, self)
self:AddCallback("msg_box", ui_events.MESSAGE_BOX_YES_CLICKED, self.OnMsgYes, self)
self:AddCallback("msg_box", ui_events.MESSAGE_BOX_NO_CLICKED, self.OnMsgNo, self)
self:AddCallback("msg_box", ui_events.MESSAGE_BOX_QUIT_GAME_CLICKED,self.OnMessageQuitGame, self)
self:AddCallback("msg_box", ui_events.MESSAGE_BOX_QUIT_WIN_CLICKED, self.OnMessageQuitWin, self)
self:Register(self, "self")
self:AddCallback("self", ui_events.MAIN_MENU_RELOADED, self.OnMenuReloaded, self)
end
function main_menu:Update()
CUIScriptWnd.Update(self)
-- Warning messages timer
if (self.msg_wnd_timer) then
self.msg_wnd_timer = self.msg_wnd_timer - 1
if (self.msg_wnd_timer <= 0) then
self.msg_wnd_timer = nil
self.msg_wnd:Show(false)
end
end
end
function main_menu:Show(f)
self.shniaga:SetVisibleMagnifier(f)
end
function main_menu:OnButton_last_save()
if ( alife() == nil) then
local flist = getFS():file_list_open_ex("$game_saves$",bit_or(FS.FS_ListFiles,FS.FS_RootOnly),"*"..".scop")
flist:Sort(FS.FS_sort_by_modif_down)
local file = flist:GetAt(0)
if not (file) then
return
end
local file_name = string.sub(file:NameFull(), 0, (string.len(file:NameFull()) - string.len(".scop")))
exec_console_cmd("main_menu off")
exec_console_cmd("start server("..file_name.."/single/alife/load) client(localhost)")
return
end
if ( (db.actor ~= nil) and (db.actor:alive() == false) ) then
self:LoadLastSave ()
return
end
self.mbox_mode = 1
self.message_box:InitMessageBox ("message_box_confirm_load_save")
self.message_box:ShowDialog(true)
end
function main_menu:OnButton_new_game()
--game.start_tutorial("credits_seq")
self:ShowFactionUI()
end
function main_menu:OnButton_originals_clicked()
game.open_originals_link()
end
function main_menu:OnButton_quit_clicked()
self.message_box:InitMessageBox("message_box_quit_windows")
self.message_box:ShowDialog(true)
end
function main_menu:OnButton_disconnect_clicked()
self.message_box:InitMessageBox("message_box_quit_game")
if (level.game_id() ~= 1) then
self.message_box:SetText("ui_mm_disconnect_message") -- MultiPlayer
else
self.message_box:SetText("ui_mm_quit_game_message") -- SinglePlayer
end
self.message_box:ShowDialog(true)
end
function main_menu:OnButton_save_clicked()
-- Saving will be interrupted if flags.ret is set to true by a custom script that have "on_before_save_input"
if level.present() then
local flags = {ret = false}
SendScriptCallback("on_before_save_input", flags, 1, game.translate_string("st_ui_save"))
if (flags.ret == true) then
return
end
end
if self.save_dlg == nil then
self.save_dlg = ui_save_dialog.UISaveDialog()
self.save_dlg.owner = self
end
self.save_dlg:FillList()
self.save_dlg:ShowDialog(true)
self:HideDialog()
self:Show(false)
end
function main_menu:OnButton_options_clicked()
if (self.opt_dlg == nil) then
self.opt_dlg = ui_options.UIOptions()
self.opt_dlg.owner = self
end
self.opt_dlg:ShowDialog(true)
self:HideDialog()
self:Show(false)
self.opt_dlg:Reset_last_opt()
end
function main_menu:OnButton_mcm_clicked()
printf("MCMBTN press")
if (self.mcm_dlg == nil) then
self.mcm_dlg = ui_mcm.UI_MCM()
self.mcm_dlg.owner = self
end
self.mcm_dlg:ShowDialog(true)
self:HideDialog()
self:Show(false)
self.mcm_dlg:Reset_last_opt()
end
function main_menu:OnButton_load_clicked()
if self.load_dlg ==nil then
self.load_dlg = ui_load_dialog.UILoadDialog()
self.load_dlg.owner = self
end
self.load_dlg:FillList()
self.load_dlg:ShowDialog(true)
self:HideDialog()
self:Show(false)
end
function main_menu:OnButton_return_game()
exec_console_cmd("main_menu off")
SendScriptCallback("main_menu_on_quit",self)
end
function main_menu:OnMsgOk()
if (self.mbox_mode == 2) then
if mcm_log then
mcm_log.close_logs()
end
exec_console_cmd("quit")
end
self.mbox_mode = 0
end
function main_menu:OnMsgCancel()
self.mbox_mode = 0
end
function main_menu:OnMsgYes()
if self.mbox_mode == 1 then
self:LoadLastSave()
end
self.mbox_mode = 0
end
function main_menu:OnMsgNo()
self.mbox_mode = 0
end
function main_menu:OnMessageQuitGame()
exec_console_cmd("disconnect")
end
function main_menu:OnMessageQuitWin()
if mcm_log then
mcm_log.close_logs()
end
exec_console_cmd("quit")
end
function main_menu:StartGame()
if (alife() ~= nil) then
exec_console_cmd("disconnect")
end
device():pause(false)
exec_console_cmd("start server(all/single/alife/new) client(localhost)")
exec_console_cmd("main_menu off")
end
function main_menu:ShowFactionUI()
if self.new_game_dlg == nil then
self.new_game_dlg = ui_mm_faction_select.UINewGame(self)
end
self.new_game_dlg:ShowDialog(true)
self:HideDialog()
self:Show(false)
end
function main_menu:LoadLastSave()
exec_console_cmd("main_menu off")
exec_console_cmd("load_last_save")
end
function main_menu:on_localization_change()
self.opt_dlg = nil
self.mcm_dlg = nil
self.new_game_dlg = nil
end
function main_menu:Dispatch(cmd, param) --virtual function
if cmd == 2 then
self:OnButton_multiplayer_clicked()
end
return true
end
function main_menu:OnKeyboard(dik, keyboard_action) --virtual function
CUIScriptWnd.OnKeyboard(self,dik,keyboard_action)
local bind = dik_to_bind(dik)
SendScriptCallback("main_menu_on_keyboard",dik,keyboard_action,self,level.present())
if keyboard_action == ui_events.WINDOW_KEY_PRESSED then
if (level.present()) then
if (dik == DIK_keys.DIK_ESCAPE) then
if (db.actor and db.actor:alive()) or (IsGameTypeSingle() ~= true) then
self:OnButton_return_game()
end
return true
elseif (bind == key_bindings.kQUICK_SAVE) then
level_input.action_quick_save()
return true
elseif (bind == key_bindings.kQUICK_LOAD) then
level_input.action_quick_load()
return true
-- F6 in menu = Hardsave (script originally made by NamelessWanderer)
elseif (dik == DIK_keys.DIK_F6) then
-- Saving will be interrupted if flags.ret is set to true by a custom script that have "on_before_save_input"
if level.present() then
local flags = {ret = false}
SendScriptCallback("on_before_save_input", flags, 3, game.translate_string("st_ui_save"))
if (flags.ret == true) then
return true
end
end
if level.present() and (db.actor ~= nil) and db.actor:alive() then
local Y, M, D, h
Y, M, D, h = game.get_game_time():get(Y, M, D, h)
m = level.get_time_minutes()
if m < 10 then
m = ("0"..m)
end
local comm = utils_xml.get_special_txt(db.actor:character_community())
local map = utils_xml.get_special_txt(level.name())
exec_console_cmd("main_menu off")
exec_console_cmd("save " .. comm .. " - " .. map .. " - hardsave - " .. string.format("%d.%d.%d %d-%d", D, M, Y, h, m))
end
end
else
if (dik == DIK_keys.DIK_F2) and DEV_DEBUG then
axr_main.config:w_value("character_creation","new_game_test",true)
--axr_main.config:w_value("character_creation","new_game_story_mode",true)
axr_main.config:w_value("character_creation","new_game_difficulty",1)
axr_main.config:w_value("character_creation","new_game_economy",1)
--axr_main.config:w_value("character_creation","new_game_opened_routes",true)
axr_main.config:w_value("character_creation","new_game_faction","stalker")
axr_main.config:w_value("character_creation","new_game_loadout", "device_pda_1")
axr_main.config:save()
self:StartGame()
elseif (bind == key_bindings.kQUICK_LOAD) then
self:OnButton_last_save()
return true
end
end
if (dik == DIK_keys.DIK_Q) then
self:OnMessageQuitWin()
elseif (dik == DIK_keys.DIK_NUMPAD0) and DEV_DEBUG then
reload_ini_sys()
game.reload_language()
printf("system_ini_reload = success!")
elseif (dik == DIK_keys.DIK_F1) and DEV_DEBUG then
self:SetMsg( game.translate_string("st_ui_dbg_help"), 10 , 3)
end
end
return true
end
function main_menu:OnMenuReloaded()
printf("- main_menu:OnMenuReloaded()")
--self:OnButton_options_clicked()
end
function main_menu:SetMsg(text,tmr,align)
if (text == "") then
return
end
self.msg_wnd:Show(true)
align = align or 2
local _x = (align == 3) and -512 or 0
self.msg_wnd_text:SetTextAlignment(align)
self.msg_wnd_text:SetText(text)
self.msg_wnd_text:AdjustHeightToText()
self.msg_wnd_text:SetWndSize(vector2():set(1024,self.msg_wnd_text:GetHeight()+10))
self.msg_wnd_text:SetWndPos(vector2():set(_x,20))
self.msg_wnd:SetWndSize(vector2():set(1024,self.msg_wnd_text:GetHeight()+44))
self.msg_wnd:SetWndPos(vector2():set(0,80))
self.msg_wnd_timer = 100*tmr
end
File diff suppressed because it is too large Load Diff
Binary file not shown.