public static ParamSelector FlipY(string name = "flipY", int provider = 0, bool defaultValue = false) { Param def = new Param(defaultValue, name); ParamSelector ps = new ParamSelector(def, provider, relativityType: ParamRelativityType.Normal); return(ps); }
public static ParamSelector Rotation(string name = "rotation", int provider = 0, Quaternion?defaultValue = null) { Param def = new Param(defaultValue ?? Quaternion.identity, name); ParamSelector ps = new ParamSelector(def, provider, relativityType: ParamRelativityType.Normal); return(ps); }
public override void Reset() { base.Reset(); rotationParam = ParamSelector.Rotation("rotation", (int) Providers.Target); forwardParam = ParamSelector.Direction("forward", (int) Providers.Target, Vector3.forward); upParam = ParamSelector.Direction("up", (int) Providers.Target, Vector3.up); lookAtPositionParam = ParamSelector.Position("position", (int) Providers.Target); offsetParam = new ParamSelector(new Param(ParamType.Rotation, "offset"), (int) Providers.Follower); }
public static ParamSelector SortingOrder(string name = "sortingOrder", int provider = 0, int defaultValue = 0) { Param def = new Param(defaultValue, name); ParamSelector ps = new ParamSelector(def, provider, relativityType: ParamRelativityType.Normal); return(ps); }
public static ParamSelector Direction(string name = "direction", int provider = 0, Vector3 defaultValue = default(Vector3)) { Param def = new Param(defaultValue, name); ParamSelector ps = new ParamSelector(def, provider, relativityType: ParamRelativityType.Normal); return(ps); }
public override void Reset() { base.Reset(); anchorParam = ParamSelector.Position(provider: (int)Providers.Object1); connectedAnchorParam = ParamSelector.Position(provider: (int)Providers.Object2); targetParam = ParamSelector.Position(name: "target", provider: (int)Providers.Object2); limitsParam = new ParamSelector(new Param(ParamType.AngleLimits), (int)Providers.Object1); distanceParam = new ParamSelector(new Param(ParamType.Float, "distance"), (int)Providers.Object1); }
public void Reset() { lookAtPositionParam = ParamSelector.Position(); forwardParam = ParamSelector.Direction("forward", defaultValue: Vector3.forward); upParam = ParamSelector.Direction("up", defaultValue: Vector3.up); rotationParam = ParamSelector.Rotation(); offsetParam = ParamSelector.Rotation("offset"); tweenOptions.Reset(); }
public override void Reset() { base.Reset(); rotationParam = ParamSelector.Rotation(provider: (int)Providers.Leaf); forwardParam = ParamSelector.Direction(defaultValue: Vector3.forward, provider: (int)Providers.Leaf); upParam = ParamSelector.Direction(defaultValue: Vector3.up, provider: (int)Providers.Leaf); lookAtPositionParam = ParamSelector.Position(provider: (int)Providers.Root); offsetParam = ParamSelector.Rotation("offset", (int)Providers.Leaf); }
public static ParamSelector Position(string name = "position", int provider = 0, Vector3 defaultValue = default(Vector3)) { Param def = new Param(defaultValue, name); ParamSelector ps = new ParamSelector(def, provider, relativityType: ParamRelativityType.Normal); ps.showPositionOptions = true; return(ps); }
public override void Reset() { base.Reset(); anchorParam = ParamSelector.Position(provider: (int)Providers.Link); connectedAnchorParam = ParamSelector.Position(provider: (int)Providers.PreviousLink); targetParam = ParamSelector.Position(provider: (int)Providers.PreviousLink); limitsParam = new ParamSelector(new Param(ParamType.AngleLimits), (int)Providers.Link); distanceParam = new ParamSelector(new Param(ParamType.Float, "distance")); }
public override void Reset() { base.Reset(); rotationParam = ParamSelector.Rotation(provider: (int)Providers.PreviousLink); forwardParam = ParamSelector.Direction(name: "forward", provider: (int)Providers.PreviousLink, defaultValue: Vector3.forward); upParam = ParamSelector.Direction(name: "up", provider: (int)Providers.PreviousLink, defaultValue: Vector3.up); lookAtPositionParam = ParamSelector.Position(provider: (int)Providers.PreviousLink); offsetParam = new ParamSelector(new Param(ParamType.Rotation, "offset"), (int)Providers.Link); }
public override void Reset() { base.Reset(); anchorParam = ParamSelector.Position(provider: (int)Providers.Leaf); connectedAnchorParam = ParamSelector.Position(provider: (int)Providers.Root); axisParam = ParamSelector.Direction("axis", (int)Providers.Root, Vector3.forward); secondaryAxisParam = ParamSelector.Direction("secondaryAxis", (int)Providers.Root, Vector3.right); swingAxisParam = ParamSelector.Direction("swingAxis", (int)Providers.Root, Vector3.right); // limitsParam = new ParamSelector(Param.defaultNameForType[ParamType.AngleLimits], // new Param(ParamType.AngleLimits), (int) Providers.Object1); }
public override void Reset() { base.Reset(); anchorParam = ParamSelector.Position(provider: (int)Providers.Object1); connectedAnchorParam = ParamSelector.Position(provider: (int)Providers.Object2); axisParam = new ParamSelector(new Param(ParamType.Vector3, "axis"), (int)Providers.Object1); secondaryAxisParam = new ParamSelector(new Param(Vector3.right, "secondaryAxis"), (int)Providers.Object1); swingAxisParam = new ParamSelector(new Param(Vector3.right, "swingAxis"), (int)Providers.Object1); // limitsParam = new ParamSelector(Param.defaultNameForType[ParamType.AngleLimits], // new Param(ParamType.AngleLimits), (int) Providers.Object1); }
void ApplyContinuousOptions(AttachObject obj) { if (!obj.spriteRenderer) { return; } if (onAttachOptions.adoptSortingOrderOptions.enabled) { ParamSelector selector = onAttachOptions.adoptSortingOrderOptions.param; obj.spriteRenderer.sortingOrder = selector.GetSortingOrder(obj.attachment, obj); } if (onAttachOptions.adoptFlipXOptions.enabled) { ParamSelector selector = onAttachOptions.adoptFlipXOptions.param; obj.spriteRenderer.flipX = selector.GetFlipX(obj.attachment, obj); } if (onAttachOptions.adoptFlipYOptions.enabled) { ParamSelector selector = onAttachOptions.adoptFlipYOptions.param; obj.spriteRenderer.flipY = selector.GetFlipY(obj.attachment, obj); } }
public void Reset() { enabled = false; param = ParamSelector.SortingOrder(); keepUpdated = true; }
public override void Reset() { base.Reset(); followerAnchor = ParamSelector.Position(provider: (int)Providers.Leaf); targetAnchor = ParamSelector.Position(provider: (int)Providers.Root); }
public override void Reset() { base.Reset(); followerAnchor = ParamSelector.Position(provider: (int)Providers.Link); targetAnchor = ParamSelector.Position(provider: (int)Providers.PreviousLink); }
public void Reset() { enabled = false; param = new ParamSelector(new Param(ParamType.Layer)); }
public void Reset() { anchor1Param = ParamSelector.Position(); anchor2Param = ParamSelector.Position(); tweenOptions.Reset(); }
public void Reset() { enabled = false; param = ParamSelector.FlipY(); keepUpdated = true; }