Safely Set Value in Table

tools.setfield(id, v)
tools.setfield(t, id, v)

Safely write the value into the table t, or the root.
Will create the table tree structure if it isn't already there.

Parameter Type Description
id string Identifer
v string/number/boolean/etc Value
t table Table to write into