• Unity
  • Small Improvements, Bugs, Curiosities

Related Discussions
...

Spine Preferences:

  • It would be really helpful to have in the Spine section under preferences the option to set a default import scale as well as Textureformat and alpha setting. With our workflow we have to (re)set those on every (re)import.

Last Frames:

  • With animations fading out the alpha of graphics we have reports that if the last keyframe is alpha null the animation might stop semi-transparent alpha instead of a flat zero, to counter this we added a few empty frames at the end of most animations to make sure nothing gets lost.

  • Also Custom Events seem not to get triggered on the very last frame as well, we don't want to use the Complete callback for workflow reasons and have to buffer here at least one frame as well to get the event.

SkeletonGraphics:

  • Is there an update about (soft)masking these? I have seen that the SekeltonGraphic is deriving from MaskableGraphic, however in our test cases they are clipped as a whole. Is there something wrong with our setup, or how would it be possible to to have them dissected/clipped inside the animation graphics?

  • Would it be possible to have the SkeletonUtility for SkeletonGraphics as well?

Atlastextures:

  • When the texture gets imported, is it possible to pass the regions of the single sprites as well? So we could use the the sprites on the atlas directly in unity as well? Otherwise it would be nice, if the texture import would set the SpriteMode to None instead to avoid confusion inside projects.

Spine Prefs:
seems simple enough.

Last Frames:
This is an Animation.Apply/AnimationState thing that's shared logic across all runtimes. Whatever changes and fixes applied needs to be applied to all runtimes.
Work is currently being done on this front though and an update is coming soon. More on that here: [runtimes] AnimationState improvements · Issue #621 · EsotericSoftware/spine-runtimes · GitHub

But if your case (with events) is simple enough but you have mixing, you may just be running into AnimationState ignoring the previous animation during a transition/crossfade. If that's the case, I point your attention to this: spine-runtimes/AnimationState.cs at master · EsotericSoftware/spine-runtimes · GitHub
In the AnimationState update above, we hope to make it some kind of setting.

SkeletonGraphic:
Can you describe what you mean by "soft masking"? And what you mean by "dissected/clipped" and what you mean by "inside the animation graphics".
SkeletonGraphic just does the stencil-buffer-based UnityEngine.UI.MaskableGraphic masking. Is there some other type of masking UnityEngine.UI is capable of?

Not sure if SkeletonUtility is possible.

Atlas textures:
"pass regions of the single sprites"?
Note that if you select the AtlasAsset, you can check the checkboxes and it will generate prefabs with meshes mapped to the regions. It's not a sprite but you can have single parts as static meshes in their own GameObject.

There are a number of things we want to do with Unity and sprite/atlas stuff. Including letting Unity do the packing for us so it doesn't have to be an additional Spine task/task for the animator. But as it is, there are a bunch of missing parts in Unity's Sprite/Sprite Packer API to allow us to do this cleanly and robustly.

I suppose setting SpriteMode to None would be a good default.


31 Jul 2016 10:34 pm


I'm not able to reproduce the alpha 0 color key at the end of an animation not working.

Thanks for all the pointers 🙂

I will look through those and check back with our code base and will leave you an edit here about the alpha-issue. Maybe it has something to do with the AnimationSates as well.

Masking in Unity is supposed to change/have changed in 5.4 or 5.5 (2D alpha-features etc.) also there are different Plugins that implement their own Shader. I tried with the Masking Shader from the UI Extensions GitRepo with no satisfying result. Maybe something in our project is broken. I will look through our shaders/settings and add a more detailed description in the edit as well.

Just pulled the Master Branch and saw the Sprite to None change. You are fast! Quick Question: Would you rather have me comment/post/provide at Github directly rather than this board?

Either is fine.
If it's a how-to, it's helpful for other users if they see that stuff here in the forum.
Also see the new Spine preferences. :cake:

Pharan a écrit

Also see the new Spine preferences. :cake:

:sun: Thanks! These changes do actually help to save quite some time.