public ThermoController(string id, ControllerType controllerType, PlayStatusType playStatusType, EventDispatcher eventDispatcher) : base(id, controllerType, playStatusType) { this.isDead = false; this.temperature = 30f; this.dropRate = 1f; eventDispatcher.UseItem += EventDispatcher_UseItem; }
public CurveController(string id, ControllerType controllerType, Transform3DCurve transform3DCurve, PlayStatusType playStatusType, int curveEvaluationPrecision) : base(id, controllerType) { this.transform3DCurve = transform3DCurve; this.elapsedTimeInMs = 0; this.curveEvaluationPrecision = curveEvaluationPrecision; }
//allows us to set the PlayStatus for all controllers simultaneously (e.g. play all, reset all, stop all) public virtual void SetAllControllers(PlayStatusType playStatusType) { if (this.controllerList != null) { foreach (IController controller in this.controllerList) { controller.SetControllerPlayStatus(playStatusType); } } }
//allows us to set the PlayStatus for all controllers simultaneously (e.g. play all, reset all, stop all) public virtual int SetAllControllersPlayStatus(PlayStatusType playStatusType) { if (this.controllerList != null) { foreach (IController controller in this.controllerList) { controller.SetPlayStatus(playStatusType); } } return(this.controllerList == null ? 0 : this.controllerList.Count); }
//allows us to set the PlayStatus for all controllers with the same GROUP parameters simultaneously (e.g. "play" all controllers with a group ID of 1) public virtual void SetAllControllers(PlayStatusType playStatusType, Predicate <IController> predicate) { List <IController> findList = FindControllers(predicate); if (findList != null) { foreach (IController controller in findList) { controller.SetControllerPlayStatus(playStatusType); } } }
//allows us to set the PlayStatus for all controllers (e.g. play all, reset all, stop all) corresponding to the predicate public virtual int SetControllerPlayStatus(PlayStatusType playStatusType, Predicate <IController> predicate) { List <IController> findList = null; if (this.controllerList != null) { findList = FindControllers(predicate); foreach (IController controller in findList) { controller.SetPlayStatus(playStatusType); } } return(findList == null ? 0 : findList.Count); }
public virtual void SetControllerPlayStatus(PlayStatusType playStatusType) { this.playStatusType = playStatusType; }
//allows us to specify the initial state for a controller (e.g. play, off) public Controller(string id, ControllerType controllerType, PlayStatusType playStatusType) { this.id = id; this.controllerType = controllerType; this.playStatusType = playStatusType; }
//allows us to play, pause, stop, reset a controller public virtual void SetPlayStatus(PlayStatusType playStatusType) { this.playStatusType = playStatusType; }
public virtual bool SetControllerPlayStatus(PlayStatusType playStatusType) { //does nothing return(false); }
//pre-curveEvaluationPrecision compatability constructor public Track3DController(string id, ControllerType controllerType, Track3D transform3DCurve, PlayStatusType playStatusType) : this(id, controllerType, transform3DCurve, playStatusType, DefaultCurveEvaluationPrecision) { }
public ThermoController(string id, ControllerType controllerType, PlayStatusType playStatusType) : base(id, controllerType, playStatusType) { this.isDead = false; this.temperature = 30f; this.dropRate = 1f; }
public SlipController(string id, ControllerType controllerType, PlayStatusType playStatusType) : base(id, controllerType, playStatusType) { this.rnd = new Random(); }