Skip to content

V1.1.1

Choose a tag to compare

@thekingofspace thekingofspace released this 05 Sep 03:13
· 5 commits to master since this release

Taking instances Vision did not make

  • fromClone(Template) stands in for a ClassName. The node copies the template instead of building something new and owns the copy, so Cleanup destroys it and mounting again stamps a fresh one. The template is never touched.
  • fromInstance(Existing) is identical in every way but one: it adopts the instance you hand it and never destroys it. Cleanup runs your callbacks, disconnects everything Vision connected, and leaves the instance exactly where it was. Its parent is left alone too, unless you give the node a mount.
  • FromParent = "ChildName" is the third way a node gets its instance: find the child of that name on the node around it. That is how a tree built in Studio, or a template full of children, gets wired up. It nests as deep as you like.
  • Cleanup takes what Vision made and nothing else. A ClassName child you declare inside an adopted node is owned and gets destroyed, while everything the instance already had stays put.
  • Cloning a vision that holds a fromInstance errors instead of quietly making two visions fight over one instance. It tells you to use fromClone.
  • lint knows about all three, and now also flags a ClassName sitting next to a source marker, since it will be ignored.

Animation

  • Animation:Play(). Animate now stages the animation and touches nothing until you play it, matching how a flipbook already worked.
  • Play resumes from wherever the playhead is rather than restarting, so a stopped animation carries on from where it stopped. Run.Time is that playhead, and it survives a Stop. Jump(0):Play() is a replay.
  • An animation can drive a vision as well as an instance. Pass one and the keyframes name its values rather than instance properties, so every handler bound to them runs and every instance they drive follows. Value names are checked when you build it, not part way through playing.

Fixes

  • A track never landed on its last keyframe exactly, stopping wherever the final frame happened to fall. A single keyframe animation applied nothing at all, and a zero length one never fired its events.
  • A loop restarted a property from wherever it ended rather than from its first keyframe, so anything spanning several keyframes stuck at its end value.
  • Replaying an animation reused the finished run's track state, so a fresh Play at the start inherited the end of the timeline and never moved.
  • Keyframes take 0 for the tween time. TweenInfo is there for the shape of the curve, not its length, and Roblox refuses nil for that argument.