Nope. It's strongly not recommended to use any variables in json. It's a temporary deprecated feature for old mods.
Pass named parameters to json instead.
in json value: "You know, parameter_1 value is @parameter1_value@".
Code:
Version 2.6.2
------------------------
[+] 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 "?".
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!"
}