5 namespace droid.Runtime.Prototyping.Actuators {
8 [AddComponentMenu(ActuatorComponentMenuPath._ComponentMenuPath
10 + ActuatorComponentMenuPath._Postfix)]
15 protected string _Layer_Mask =
"Obstructions";
20 protected bool _No_Collisions =
true;
25 protected Space _Relative_To = Space.Self;
29 public override string PrototypingTypeName {
get {
return "IndexedMotion"; } }
37 var layer_mask = 1 << LayerMask.NameToLayer(this._Layer_Mask);
42 vec = Vector3.forward;
54 throw new ArgumentOutOfRangeException();
57 if (this._No_Collisions) {
58 if (!Physics.Raycast(
this.transform.position, vec, Mathf.Abs(motion.
Strength), layer_mask)) {
59 this.transform.Translate(vec, this._Relative_To);
62 this.transform.Translate(vec, this._Relative_To);
override void InnerApplyMotion(IMotion motion)