Current time: 23.03.2024, 14:05 Hello There, Guest! (LoginRegister)
Language: english | russian  

Post Reply 
Threaded Mode | Linear Mode
ERA II
» WoG Era 2: Русская и Английская версии
Author Message
Berserker Offline
Administrators

Posts: 16449
Post: #2671

Не сохраняется, как и другие ресурсы игры. Но по F12 для удобства перезагружается всё Ab


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
02.12.2017 19:25
Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16449
Post: #2672

Image: NBy239hK3QFeQ8


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
02.12.2017 21:00
Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2673

Berserker, а описание втор.навыка?
Ну и далее инфо об артефактах и существах 118


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 00:17
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16449
Post: #2674

0 - имя, 1-3 описание по уровню.
Бред — название навыка, Глупизна — описание )


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
03.12.2017 00:44
Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16449
Post: #2675

Version 2.6.2
------------------------
Code:
[+] Added localization support for ERM scripts. All Lang\*.json files are loaded and merged into single dictionary of key => value pairs with language data.
Json files must be saved in UTF-8 encoding with preferably Unix line endings (#10 = 0x0A). The format is the following:

{
  "unique global key": "translation",
  "another key": "another translation"
}

During file loading text is converted from UTF-8 (Unicode, i.e Russian, Polish, Chinese and any other language is supported) into ANSI-encoding, used by player's operational system, ex. Windows-1251.
Thus you may ship the translation, other people may open and edit it without loss and characters, not representable on particular PC, will be replaced with "?".

Real example:

{
  "eqs.this_day_savegame_name": "@day@_@player@",
  "eqs.end_turn_autosave_name": "@day@_@player@_End",
  "eqs.quicksave_name":         "@day@_@player@_Quick",
  "eqs.saved_msg":              "Saved!",
  "eqs.quicksaved_msg":         "Quicksaved!"
}

It's recommended to prefix each key with string, unique for mod or author, like "pm." for "Phoenix Mod".

Translations may have parameters in the form of "@parameter name@". Those parameters are replaced with actual values during translation.
New ERM command !!SN:T is used to translate strings by key.
!!SN:T(key)/?(z-variable to place result to)/(parameter name 1)/(parameter value 1)/(parameter name 2)/(parameter value 2)...;

Example:

!!OW:R-1/6/?y1; y1 - player's gold amount
!!SN:T^test.gold_amount_report^/?z2/^gold^/y1;
!!IF:M^%Z2^; prints "You have 12850 gold left. Not bad!"

my test.json:

{
  "test.gold_amount_report": "You have @gold@ gold left. Not bad!"
}

[+] Added possibility to set secondary skills texts without z-variables dependence. SN:H^secskill^/skill 0..27/0 (name) or skill level/new hint.
[+] Added GET-syntax for all SN:H commands, allowing to get previously set hint for objects or current skill/specialty texts for heroes.
[+] v1-v10 and z1 will be restored after (OnKeyPress) event to the value, they had before event.
[+] Added fixes by Algor for 30 wog - enhanced secondary skills.erm, 75 wog - secondary skills boost.erm and 78 wog - wogify.erm. No more hardcoded numbers, !!SS is used instead.
[+] "Quick Saving" script is converted into default standalone mod, using named functions, unique SN:W variables and Era 2.6.2 localization means. Mod is now compatible with almost any other mod.
[+] Added msvcr90.dll (Microsoft Visual C++ Redistributable 2009) to support plugins, written with this dependency.
[+] Added meaningful messages to many asserts in code, making assertion crashes easier to understand.
[*] Each *.bin patch obtains unique name prefix, no more conflicts with 'no hota maps.bin', shipped with HD mod.
[*] Yona creature abilities are now off by default and need to be manually switched on via mod ini file.
[-] Fixed bug: SN:H^object^/x/y/z/hint didn't update hint.
[-] Removed Jim Vogan's scripts from WoG mod.


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
03.12.2017 01:17
Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2676

132


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 11:26
Visit this user's website Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2677

Berserker, эра карашится при запуске, если в json-файле есть параметры без кавычек (json-стандарт это разрешает):
{
    "par.name": 1,
}

Хотелось бы иметь возможность подгружать числовые значения через !!SN:T^par.name^/?y1; чтобы не конвертить дополнительно.
И может при неудачной подгрузке значения (нет ключа) вместо/кроме установки значения в <имя ключа> выставлять какой-нить флаг?

Upd: Всё не критично, если что 118


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 19:31
Visit this user's website Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2678

Не подгружает значения из json если они не в первой секции верхнего уровня.
Т.е.:
{
...подгружается...,
   {
   ...НЕ подгружается...,
   },
   {
   ...НЕ подгружается...,
   }
},
{
...НЕ подгружается...,
}

Тож не критично, так для информации.


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 19:44
Visit this user's website Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2679

Bers, ты каким редактором ковыряешь json'ы? А то меня уже бесят слеты кодировок и переносов Mad


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 19:58
Visit this user's website Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2680

Млять, пучок лучей ненависти и ведро помоев создателю json-формата запретившему использовать в нем коментарии.
Вопрос с редактором снимается.


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 20:43
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16449
Post: #2681

Algor, sublime text 3 — идеал.
Попробуй // комментарии

Они в реализации, как и многострочные строки, разрешены. Ну да, другие утилиты такой json не прочитают ) Ну и хрен с ними.


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
03.12.2017 21:42
Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2682

{
"key1": "value1", // Comment
"key2": "value2",
}

!!SN:T^key1^/?z1 T^key2^/?z2;
!!IF:M^%Z1, %Z2^; --выводит "key1, key2"

ЧЯДНТ?


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 22:25
Visit this user's website Find all posts by this user Quote this message in a reply
gamecreator Offline

Posts: 7107
Post: #2683

Algor, скорей всего запятая после второго поля ломает JSON и он не загружается.


When all gods have burnt to ashes in eternity of sorrow,
Demons gonna tear your soul because there is no tomorrow.
03.12.2017 22:45
Find all posts by this user Quote this message in a reply
Algor Away
Administrators

Posts: 3880
Post: #2684

gamecreator, не последнее поле с запятой отрабатывает нормально, проверял.


BattleHeroes Rus/Eng | ERA scripts (+ReMagic) Rus/Eng
03.12.2017 22:51
Visit this user's website Find all posts by this user Quote this message in a reply
Berserker Offline
Administrators

Posts: 16449
Post: #2685

Algor, json не разрешает строк без кавычек )
Если файл в Lang-папке, то попробуй-таки убрать последнюю запятую. Увы, это удобно, но она прописана как разделитель. Такая же ошибка была у меня.


Скачать Герои 3 Эра и всё, что с ней связано / ERA 2.46f для старых модов
Поддержать проект
03.12.2017 23:10
Find all posts by this user Quote this message in a reply
« Next Oldest | Next Newest »
Post Reply 


Forum Jump:

Powered by MyBB Copyright © 2002-2024 MyBB Group