Class: CT (of Cycler)

The CT class is an extension of the Cycler class adding the endCel property and an improved init() method.

Properties

  • client
  • caller
  • cycleDir
  • cycleCnt
  • completed
  • endCel

Methods

  • void init(heapPtr theClient, number theEndCel, number theCycleDir[, heapPtr theCaller])

    Sets up the CT cycler.

    It calls the super's init() method with theClient as it's parameter. It then sets the cycleDir property to theCycleDir. If theCaller is specified, it sets the caller property to it. Finally, it sets the end cel to theEndCel. If theEndCel is greater than the last cel of the loop, it sets it to that.

  • void doit()

    Increments the client's cel.

    If the cel is greater than the last cel, it is set back to the first cel. If the cycleCnt property is zero, and the endCel is equal to the client's current cel, the cycleDone() method is called.

  • void cycleDone()

    Sets the completed property to TRUE. If the caller property is set, it sets the global variable gCastMotionCue to TRUE. Otherwise, it calls it's motionCue() method.