A Unity ID allows you to buy and/or subscribe to Unity products and services, shop in the Asset Store and participate
in the Unity community.
Discussion in '2D' started by rustum, Jan 30, 2020.
i feel that ,,damn ,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,please fix this
so damn bad painfull
i got you but ,, how manyt bones should i make ??????????????????????????
I'm getting an error when trying to restore the default pose in the IKManager. The error is in the DoRestoreDefaultPoseButton() method:
private void DoRestoreDefaultPoseButton()
if (GUILayout.Button(Contents.restoreDefaultPoseString, GUILayout.MaxWidth(150f)))
foreach (var l_target in targets)
var manager = l_target as IKManager2D;
foreach(var solver in manager.solvers)
for(int i = 0; i < solver.chainCount; ++i)
var chain = solver.GetChain(i);
chain.target.position = chain.effector.position;
chain.target.rotation = chain.effector.rotation;
It throws a null reference error in the line foreach(var solver in manager.solvers). If I add
above the loop (and make that function public so I can call it there) it works, but I'm not sure if I am messing up stuff here? And I guess it's supposed to work from the get go. I am using Unity 2019.3.4f1 and IK 2D 2.0.2
Hey 2D Animation team. Thank you for your work.
I'm a Anima2D user for a long time and I tried 2D Animation recently.
I want to know do you plan to let user customize bone color and alpha in scene view like Anima2D did?
The bones in 2d animation are all white and opaque. It's hard to tell them apart when a character uses lots of bones (especially when they overlapped).
I used to color 'left arm bones' to red and 'right arm bones' to green so I can recognize them easily when making animations.
so is this function in your todo list? I'm curious about it.
As for now, is there any script file I can look into? Maybe I can modify the bone color thing by myself.
A few questiooons... and one suggestion
Is there any way to set the Effector Target of LimbSolver2D via code?
I want to setup some automation tools and it doesn't seem to be exposed.
Is there a solution for Sprite Attachments in the pipeline?
I would like to create a base rig and then be able to add and remove bones and components without rolling out my on system. Spline2D has some inspiration http://esotericsoftware.com/spine-skins
Suggestion: It would be good if the skinning tool could be integrated into the PSB workflow somehow, so I can just manage one Rig.
Thanks for all the hard work so far!
The local position z of a skinned sprite shouldn't be affected by bones. It currently breaks my art style's parallax and sorting (I don't use order in layer, because depth gives much more control, consistency in parallax, and depth).
I want to make a 2D game. I mean, I see her with a side view and pixel style. But I have a hypothesis that for 3D there are a lot of ready open source animations and models in internet. But for 2D games open materials are few. I want to use 3D models and apply some simple pixel shader to them to make 3D models in pixel style.
Tell me, what is technique of making characters and animations is still easier and faster? I have a designer in my team who can draw static objects, but not animations, so this is a problem for me.
We are now trying to use Ik manager but it contains performance issues.
Is there a bake animation feature that was included in Anima2d?
If not, do you plan to add similar features in the future?
Hi! Currently, when we copy a mesh and paste it, it pastes the mesh positioned relative to the sprite's pivot point. Could we have an option in the paste menu to instead paste it relative to the current viewport or something similar instead?
The issue is that sometimes I have a sprite split into different layers so I can colour the layers in-game, and right now the only way to keep the mesh positioned the same between them is to go back into Photoshop, and paste the largest layer with 1% transparency into all the other layers so Unity sets the pivot point the same for all of them, which is a hassle to do.
While I'm loving the new 2D animation package, I have some major pain points:
1. I have no control over the rotation of my bones. My "head" bone's rotation is set 90 degrees for some strange reason despite it being upright in the PSB. It looks fine obviously, but I need to move the head for procedural animation, meaning I need to modify things to move relative to its local rotation. I don't even understand why it's rotated 90 degrees in the first place - All my sprites in the PSB are rotated properly.
2. PSBs, ugh. I'm using gimp and exporting to photoshop, then changing the extension to PSB. When I need to update the sprite, it completely breaks all of the IK I've setup and often has weird side effects like moving every sprite to the corner in the skinning editor. Does this also happen if I use photoshop? Why are PSBs necessary? Does anyone have a workflow to allow updating the sprites without having to redo all the IK stuff?
3. My model pose in-editor will often bug out. It's fine ingame or if I click "reset/default pose", but it's a bit irritating. Not a big deal though.
Since there doesn't appear to be any details as to when there will be new features like FFD in the package, I started working on it myself. Here's my current progress:
I've had to change the SpriteSkin class, because I couldn't find a way to get access to the vertex data. Right now, the VertexExposer could be used to do all kinds of cool effects, it really just exposes the vertex positions for changing them in a super easy way. (You can just get a list of VertexData, which has x and y properties that will automatically be applied when altered.)
It even works together with existing bone and IK tech! I'll post it to github once it's a bit more usable! c:
I was wondering though, what would be the best strategy for changing the SpriteSkin class? It's sealed, so I can't inherit from it either. The way I have it right now, requires the user to remove the 2D Animation package and to put my custom one in place instead. That's super clunky. Any better ideas?
Wow! This is exactly what is missing in the 2D animation package!
And that's what many of us are waiting for!
Good Luck Dude!
Here's the github: https://github.com/democore/UnityVertexModify2D
Here's a video that shows how to use it: https://puu.sh/Gaa1B/4a8ec28c2d.mp4
This is fantastic!
i wish it can replace live2d 's feature
how to reduce the batch ? i used sprite skin entity but it doesnot work ,,and i can not find the tutorials :'( please help
I'm unfamiliar with 2D in unity, so sorry if this is a dumb question. But when I import your PSB file and open the skinning editor, the sprite comes out with all layers clumped in the bottom left like so.
Am I supposed to be re-arranging the layers somehow, or was the PSB supposed to have defined the correct layout? I don't currently have photoshop so it's difficult for me to verify. Thanks for the guide!
You can skip the last two steps using the weight slider tool. Just yank the slider to the right with a bone selected.
I'd like an option to just make a quad for the sprite mesh of a layer, would make things even faster for those times when that is all you need.
Is there any way to delete a swap category from texture metadata besides "Remove Empty Category" button?
I'm using PSD importer, and I've got quite a few undeletable categories after I removed some sprites from the *.PSB source (without resetting their categories to None). Later I've tried to delete them from the SpriteLibraryAsset, but it does nothing (also corrupted categories appear again every time I make changes in sprite editor ). "Clear all category" menu option erases all categories besides corrupted ones. Adding layers with the same names (as deleted ones) and resetting them to None doesn't help either (it says that the same label already exists).
Here is a part of the SpriteLibraryAsset preview:
Update: I've edited spriteCategoryList in metafile of *.PSB source. Though, for some reason, this nuked the whole list after Unity reprocessed edited metafile. I've lost all my categories, but it's still better than getting NULL errors because of corrupted ones.
i change the extension from psb to psb ,,then close editor ,then edit in krita software ,then change again the extension to psb ,,, but fail,,,,,,,,,,,,,,,,,,,,,,,damn ,,sometimes it was successs but now,,, damn
You can use this: https://github.com/Steffenvy/PSBer
It automatically copies over PSD file contents to PSBs of the same names
Hi, has anyone faced the same issue as I did here?
unity become not respontind when i import some psb file ,,,,,,,,,,,, idont know why ,,
i m not sure , imean i dont really know how to use that
That is really great! A really good basis for morphing/shapekeys, too.
Hi, so I'm trying to use the SpriteMask component with a rigged sprite. Basically, I have a whale and it can have spots or maybe shadows slapped onto it. So I had a SpriteMask component on it that would match its sprite to whatever the whale's body sprite was in LateUpdate. The spots mask interaction is set to "visible inside mask", so they appear on the whale's back but don't protrude. Now that I'm using bones to twist and turn my whale (which is beautiful, ty Unity), my sprite mask doesn't know to deform though and i get this kinda visual error:
How do I make the sprite mask reference sprite match the deformed sprite?
Continuing the conversation started here:
Here is the current situation with the layer IDs in the file from Adobe Illustrator:
on the left is the original file, on the right I swapped two layers.
The red frames outline the IDs incorrectly assigned to these layers when exporting from AI
as you can see, it does not differ from what I wrote about earlier here: #414
-When changing the order of layers Illustrator (unlike Photoshop) -will ignore this change ...
And than a picture imported earlier and already equipped with "bones", meshes, weights in the 2D Animation package,
when you try to "update" it to this file edited in AI,
-will go crazy ...
Honestly, just letting us set the layer IDs by name or in the importer would fix a lot of the problems. I understand that using the built in layer IDs is clever and seamless when it works, but the moment you step slightly outside of the best-case scenario it breaks all over the place.
(First - Sorry for my "English" )
-I ask for this from the beginning, as soon as I realized what exactly the developers did with these IDs
Asked to do at least as an "option"
But the code has been written, the Package is already linked to the ID, everything seems to work as it should.
(For the case when everything is perfect in the pipeline)
And it looks like there is no need to change everything so radically...
But in reality it is a dead end.
ID - internal, hidden from everyone, including script developers, function of Photoshop alone - Illustrator does not have them, generating "fake" IDs only specifically for export to Photoshop.
Obviously, the most correct way - is for Adobe developers to implement a mechanism for assigning an ID "like in Photoshop" to the AI
Why would they do this? From their point of view, everything is fine with Illustrator.
But here's to connect the most important mechanism of the developed 2D Animation / Importer package - tracking changes, to the internal feature of the Graphical Editor...
-It's a mistake, I'm sure.
This was explained by protection against accidental user errors - proof from accidental renaming of layers, rearranging them, etc.
But I have complete control over the layer names!
Even accidentally breaking - everything can be restored there!
And in the case of ID - even in Photoshop (not to mention Illustrator) - simply removing a layer or flattening a few will cause an avalanche ...
If you forget about this feature of the PSD Importer and not immediately roll back everything right away.
In addition, all this is completely incomprehensible - you can break something for a long time in the order of layers, but you will see it only after re-importing into Unity!
When it's too late to go back to editing the picture and remember what I changed here and how to fix everything.
To be honest - I can't imagine an Artist to whom You can explain something like:
- Ok! you Artist! -Draw, Create, but .... BUT for "this action", and "this" and "this", and in general - for EVERYTHING as far as the layers is concerned - you must Remember!
-"This" cannot be done, "this" can be done, but very carefully... And now "this" should be done only in this way!.. Do you remember everything? Now - go paint!
Any Artist will just say: "@#$% !" ...
Everithing this - is to the Question of the Convenience of working with the package and, as a consequence, the number of those who will use it...
I Hope the Developers hear us...
This is great!
We had added new API for it in SpriteSkin.GetDeformedVertexPositionData()
sir,,how to reduce batch using sprite entity ? or what is that called ?
Hi forum, I've been working with Unity's 2d bone systems for a while, and I'd like to know what could be the best way to animate clothes, hair and the like, which have their own physics when the character moves. Is that possible? What would be the most viable approach to achieve this effect? Thanks guys.
That is great news! What version will this be available for? And will that allow Democore's scripts to work without modification?
Oh wow, that would have made my life a bit easier hahaha. I just found it in SpriteSkin.cs
So are changes to the IEnumerable<Vector3> automatically applied or do I have to give them back to the SpriteSkin somehow?
I agree that using hidden IDs to recognize layers is not the brightest idea. If you need to import once, it's ok to use them. But in most cases, as a technical artist, you need to often backtrack to the image editor to make adjustments and reimport the PSB file back to Unity. When you can't see IDs before your eyes, it almost guarantees that after you edit the source, IDs will be messed up even when the layer structure seems completely the same for you.
Also, Photoshop is not the only image processing software in the world. We have many more, like Krita, ClipStudio, etc. How these programs set IDs is their own business, they never take account of PSB importer needs. For them, IDs is a completely internal thing that can be changed by whenever they need to as long as the output is the same layer name and the same image.
It's much more preferable to use layer names. In case they are not unique just auto-rename or ignore them.
This is read only. To make modification, you will need to manually set it to the SpriteRenderer.
How would I go about that without having access to the vertex data in the SpriteSkin?
As posted here #181 you are now able to access the deformed vertex data.
Is there any update on allowing other formats for the "Multiple Sprite Single Character rigging" or for setting up the character yourself with a flat file? The Photoshop format requirement is still causing me not to use this in production.
ve been wondering this too
.. I am kinda guessing he's talking about the rigged character after using the PSB process
Taking individual sprites from another sprite sheet and in each "part" and manually replacing each sprite from each game object parts. Realigning them up to remake the character.
So far the current process is only really usable if all your art is done completely without needing updates. Maybe also useful for testing somethings out, but it's not good for actual production use.
: ( I'm going to put using this on hold, until a better process is ready.
Are you able to give more details what is missing for you to use it in production?
I'm guessing that what is missing is 'a copy of Photoshop.' Using the psd-to-psb converter method on PSDs made by other software arbitrarily changes the layer IDs, so you cannot edit the file after rigging it without breaking the skin information.
I'm using Unity2020.1.3f1.
This article says that:
but Collections package is not found in the Package Manager.
Well, I know that it can be installed by "Add packages from git url" option with the input "com.unity.collections", but it causes a compile error, which says that NativeHashMap does not have "Length" property (deprecated since Collections 0.7.1).
The error can be fixed by downgrading Collections package to 0.8.0-preview.5, and I do so for now, but I think it should be fixed in 2D Animation package.
Yes a fix is incoming for this.
please how to fix this ,,, its take never end time to apply this weight ,and i got this error
UnityEditor.U2D.Animation.BoundedBiharmonicWeightsGenerator.Calculate (UnityEngine.Vector2 vertices, UnityEditor.U2D.Animation.Edge edges, UnityEngine.Vector2 controlPoints, UnityEditor.U2D.Animation.Edge bones, System.Int32 pins) (at Library/PackageCacheemail@example.com/Editor/SkinningModule/WeightsGenerator/BoundedBiharmonicWeightsGenerator.cs:68)
UnityEditor.U2D.Animation.SpriteMeshDataController.CalculateWeights (UnityEditor.U2D.Animation.IWeightsGenerator weightsGenerator, UnityEditor.U2D.Animation.ISelection`1[T] selection, System.Single filterTolerance) (at Library/PackageCachefirstname.lastname@example.org/Editor/SkinningModule/SpriteMeshData/SpriteMeshDataController.cs:267)
UnityEditor.U2D.Animation.GenerateGeometryTool.GenerateWeights (UnityEditor.U2D.Animation.MeshCache mesh) (at Library/PackageCacheemail@example.com/Editor/SkinningModule/GenerateGeometryTool.cs:198)
UnityEditor.U2D.Animation.GenerateGeometryTool.GenerateWeights (UnityEditor.U2D.Animation.SpriteCache sprite) (at Library/PackageCachefirstname.lastname@example.org/Editor/SkinningModule/GenerateGeometryTool.cs:178)
UnityEditor.U2D.Animation.GenerateGeometryTool.<BindElements>b__8_0 (System.Single d, System.Byte a, System.Single s) (at Library/PackageCacheemail@example.com/Editor/SkinningModule/GenerateGeometryTool.cs:55)
UnityEditor.U2D.Animation.GenerateGeometryPanel.GenerateGeometry () (at Library/PackageCachefirstname.lastname@example.org/Editor/SkinningModule/UI/GenerateGeometryPanel.cs:123)
UnityEngine.UIElements.Clickable.Invoke (UnityEngine.UIElements.EventBase evt) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.Clickable.OnMouseUp (UnityEngine.UIElements.MouseUpEvent evt) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventCallbackFunctor`1[TEventType].Invoke (UnityEngine.UIElements.EventBase evt) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventCallbackRegistry.InvokeCallbacks (UnityEngine.UIElements.EventBase evt) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.CallbackEventHandler.HandleEvent (UnityEngine.UIElements.EventBase evt) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.CallbackEventHandler.HandleEventAtTargetPhase (UnityEngine.UIElements.EventBase evt) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.MouseCaptureDispatchingStrategy.DispatchEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcher.ApplyDispatchingStrategies (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel, System.Boolean imguiEventIsInitiallyUsed) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcher.ProcessEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcher.ProcessEventQueue () (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcher.OpenGate () (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcherGate.Dispose () (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcher.ProcessEvent (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.EventDispatcher.Dispatch (UnityEngine.UIElements.EventBase evt, UnityEngine.UIElements.IPanel panel, UnityEngine.UIElements.DispatchMode dispatchMode) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.BaseVisualElementPanel.SendEvent (UnityEngine.UIElements.EventBase e, UnityEngine.UIElements.DispatchMode dispatchMode) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.UIElementsUtility.DoDispatch (UnityEngine.UIElements.BaseVisualElementPanel panel) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.UIElements.UIElementsUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at <845300afd0e1436dabda8619d647321a>:0)
UnityEngine.GUIUtility.ProcessEvent (System.Int32 instanceID, System.IntPtr nativeEventPtr) (at <819de1aa368e45faa4f78e26c97c62b0>:0)
Odd, the module should have been included in the package. can you share your project?
it has been fixed but idont know how it happened ,,,thanks
Wow it literally took someone outside of Unity some initiative to go and do this finally, good job Democore! Hope they compensate you somehow, they have been dodging this bullet for over 5 years now!