Special variables and values
Certain variables have special meanings in steve. Their values are managed automatically by the breve engine and should not be assigned manually.
-
self (object).This variable always contains the value of the instantiation in which the current method is being run. The variable is used most frequently to call other methods within the same instantiation. For example, an object of class Mobile could move itself with the call:
self move to (10, 10, 10). -
super (object).This special value refers to the parent, or super-instance. This is used to invoke a parent class implementation of a method, instead of the current class implementation.
For example, in the Controller's iterate method, the superclass iterate method is often called: super iterate. This is because custom subclasses of Control typically preform simulation specific tasks, but must then call on the superclass implementation (Control) to actually step the physical simulation forward and update the state of the world. Anytime you wish to implement a custom object behavior in addition a parent class behavior, you should invoke the parent class method as well.
-
controller (object).The controller variable is defined for all instances. It always refers to the simulation's controller instance.
