设置映射值


描述

With this action you can add a key/value pair into the map data structure. You supply the variable that holds the map index (as returned by the action Create Map) and then give a "key" (which is the identifier within the map for a value), and then the "value" to be associated with that key. Both keys can be either integer values (like 0, 200, 36712, etc...) or strings (like "Name", "Shield" etc...), but the value can be any valid data type.


动作语法:

Set Map Value Syntax


参数:

参数 描述
映射 The index (stored in a variable) of the map to set
The key to set (integer or string)
The value to be stored with the given key


例如:

Set Map Value Example
The above action block code creates a new map data structure and then sets three key/value entries in it.