The ifSGNodeField interface allows you to query, and get, set, and perform other similar manipulation operations on Scene Graph node fields. The ifSGNodeField interface also allows you to set and unset event observers on a subject node field.
Description of Methods
hasField(name as String) as Boolean
Returns true if the subject node has a field whose name exactly matches name, or whose fully lowercase analog is identical to that of name. Returns false otherwise.
getField(name as String) as Object
Returns the appropriately-typed value from the subject node field identified by name.
setField(name as String, value as Object)
Sets the value of the subject node field identified by name to value. This will fail and stop script execution if the value is not of the appropriate type.
setFields(aa as Object)
Sets the value of subject node fields indicated by the corresponding key. TBD actually not sure what this does, looks like a mass setting of fields using an associative array TBD
observeField(name as String, port as roMessagePort)
Creates a connection from the subject node field identified by name to the given port. An roSGNodeEvent with the node ID and the field name will be posted to the port each time the corresponding field value changes. TBD this is not how we've been using this, we trigger a callback function, probably an early upgrade TBD
unobserveField(name as String)
Removes the previously established connections between the subject node field identified by name and all ports which were observing that node field. TBD again, probably ports are used, but not how observeField works now TBD