diff --git a/indra/lscript/lscript_library/lscript_library.cpp b/indra/lscript/lscript_library/lscript_library.cpp index 108dff2f22..16da4af8e0 100644 --- a/indra/lscript/lscript_library/lscript_library.cpp +++ b/indra/lscript/lscript_library/lscript_library.cpp @@ -541,6 +541,13 @@ void LLScriptLibrary::init() addFunction(0.f, 0.f, dummy_func, "llGetAnimationOverride", "s", "s"); addFunction(0.f, 0.f, dummy_func, "llResetAnimationOverride", NULL, "s"); + // Server RC LeTigre/BlueSteel/Magnum 13.05.14.275813 new functions + addFunction(0.f, 0.f, dummy_func, "llJson2List", "l", "s"); + addFunction(0.f, 0.f, dummy_func, "llList2Json", "s", "sl"); + addFunction(0.f, 0.f, dummy_func, "llJsonGetValue", "s", "sl"); + addFunction(0.f, 0.f, dummy_func, "llJsonSetValue", "s", "sls"); + addFunction(0.f, 0.f, dummy_func, "llJsonValueType", "s", "sl"); + // According to Kelly Linden we don't need to obey the function ID order in the viewer! // Opensim/Aurora scripting functions - Please add Second Life LSL functions above this line! diff --git a/indra/newview/app_settings/keywords.ini b/indra/newview/app_settings/keywords.ini index 792550a645..b1c0eb733a 100644 --- a/indra/newview/app_settings/keywords.ini +++ b/indra/newview/app_settings/keywords.ini @@ -706,7 +706,17 @@ PURSUIT_GOAL_TOLERANCE Used with llPursue(). Defines approximately how close th CHARACTER_CMD_STOP Used with llExecCharacterCmd(). Makes the character jump. CHARACTER_CMD_SMOOTH_STOP Used with llExecCharacterCmd(). Stops any current pathfinding operation in a smooth like fashion. -CHARACTER_CMD_JUMP Used with llExecCharacterCmd(). Stops any current pathfinding operation. +CHARACTER_CMD_JUMP Used with llExecCharacterCmd(). Stops any current pathfinding operation. + +JSON_INVALID Returned by llJsonGetValue and llJsonValueType if the specifiers to do specify a valid in the json value. +JSON_OBJECT Represents a json datatype represented in LSL as a strided list of name/value pairs +JSON_ARRAY Represents a json datatype mappable to the LSL datatype "list" +JSON_NUMBER Represents a json datatype mappable to the LSL datatypes "integer" and "float" +JSON_STRING Represents a json datatype mappable to the LSL datatype "string" +JSON_TRUE Represents the constant "true" of a json value. +JSON_FALSE Represents the constant "false" of a json value. +JSON_NULL Represents the constant "null" of a json value. +JSON_APPEND Used with llJsonSetValue as a specifier to indicate appending the value to the end of the array at that level. # Manually added constants # Partially commented out because they have been added manually with a custom description diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index 2ef2b3a064..f4a3982e78 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -2177,6 +2177,26 @@ Returns a string that is the name of the animation that is being used for the sp llResetAnimationOverride(string anim_state) Resets the animation override of the specified animation state (anim_state) to the corresponding default value. + +list llJson2List(string json) +Converts the top level of the json string to a list. + + +string llList2Json(string type, list values) +Converts either a strided list of key:value pairs to a JSON_OBJECT or a list of values to a JSON_ARRAY + + +string llJsonGetValue(string json, list specifiers) +Gets the value indicated by specifiers from the json string. + + +string llJsonSetValue(string json, list specifiers, string value) +Returns a new json string that is the json given with the value indicated by specifiers set to value. + + +string llJsonValueType(string json, list specifiers) +Returns the type constant for the value in json indicated by specifiers. +