-
Notifications
You must be signed in to change notification settings - Fork 31
Setfield
Sets the value of a specific field in the current tag.
The setfield command can set fields by specifying the field name and the value you want to give it.
SetField <field name> <field value>
- field name - the name of the field you would like to edit.
- field value - the value you want to give the field.
The setfield command can set fields in tag blocks by specifying the block name and index before the field name and value, you can set fields multiple blocks deep by specifying all the block names and indexes until you reach the field you want to set.
setfield <block name>[block index].<field name> <field value>
- block name - the name of the block you would like to edit.
- block index - the index of the block you would like to edit.
- field name - the name of the field you would like to edit.
- field value - the value you want to give the field.
There are many different field types each with their own way of setting them.
Flag fields containain multiple flags that can be turned on and off, multiple flags can be turned on at the same time by separating the flag name with comma's.
setfield <field name> <flag1>,<flag2>,<flag3>
- field name - the name of the field you would like to edit.
- flagX - the name of the flag you want to check.
Range fields have lower and upper bounds
setfield <field name> <lower> <upper>
- field name - the name of the field you would like to edit.
- lower - the lower bounds of the range.
- upper - the upper bounds of the range.
Real point 3D fields use x y z coordinates.
setfield <field name> <x> <y> <z>
- field name - the name of the field you would like to edit.
- x - the value of the x axis.
- y - the value of the y axis.
- z - the value of the z axis.
String Id's fields use the value of a string id.
setfield <field name> <string id>
- field name - the name of the field you would like to edit.
- string id - the name of an existing string id, if the string id doesn't exist, you will need to create it with the stringid command.
Tag reference fields reference other tags in the cache.
setfield <field name> <tag name>
- field name - the name of the field you would like to edit.
- tag name - the name of the tag you would like to reference.