-
Posts
161 -
Joined
-
Last visited
-
Days Won
19
Content Type
Forums
Store
Gallery
Downloads
Everything posted by loodakrawa
-
Hi, What exactly do you mean by "animations I had in my file in the animator"? Do you mean animations in the .scml file? The importer basically generates a prefab for every entity, and every entity should have all the animations as in the .scml file. If you need to check the imported data structure you can find a generated name.asset (where name is the same as in name.scml) which you can expand in the editor and take a look at all the data. Take a look at the attached screenshot. Let me know if this gives you all the answers you need. Cheers
-
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
I assume you're talking about Unity. Since SpriterDotNet is a framework agnostic library, it doesn't use Unity's animation system and because of that it's not possible to use the animator. However, I'm working on a state machine driven approach in the library itself to achieve a similar effect. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Did you manage to do what you wanted? I'd like to know if you managed to do it as I suggested (with char maps) or if you had to use another way -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
I have another simpler idea. You could add transparent placeholder sprites in the animation itself and then create a character map during runtime to replace the required placeholders with real sprites. This way you get all tranforms and z-indexes calculated out of the box. Does this solve your problem? If not, we'll figure something out. Regarding IK and other advanced features - I'm investigating what can be done and already working on some features (state machine driven animations). If you feel inspired, feel free to contribute -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Hi, That would be possible via runtime modification of the Spriter data structure. However, could you perhaps achieve the same effect by adding points to the animation and just drawing armor pieces on those points? -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Hi, I saw on GitHub that you already found a solution. Nice work! I added a comment: https://github.com/loodakrawa/SpriterDotNet/issues/15#issuecomment-155096864 Also, I'll leave the issue open for a short while and then close it as "wontfix" since it only affects older versions + I'll add the version requirements to the docs. -
SpriterDotNet.Unity The Unity plugin for SpriterDotNet. Supports all Spriter features. https://github.com/loodakrawa/SpriterDotNet/tree/develop/SpriterDotNet.Unity Documentation The most up to date documentation can be found on the GitHub Repository.
-
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Hi everybody, I'm happy to announce that I finished the Unity plugin and that I released SpriterDotNet as version 1.0.0! -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
I probably haven't explained it well enough. The pivot I was referring to is Spriter's pivot point, not the "pivot" object created in Unity. The "pivot" in Unity is basically the position of the object and it's being set to X and Y and the "child" is moved by deltaX and deltaY to account for the pivot point defined in Spriter. I took a quick look to the files you sent me. If you check the .meta files of your /parts folder you'll notice that the spritePivot property is not {x: 0.5, y: 0.5} as it should be with the default settings. I'm pretty sure resetting the pivot point of your sprites in Unity should fix the issue. I will however try to incorporate support for sprites with different pivot points. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
I've been looking into the issue you're having and couldn't replicate it. The DeltaX and DeltaY take care of the Spriter's pivot point. If you set it to 0,0 it's not going to work properly if anything has a non default pivot point. The only other thing I could think of is pivot points of imported Sprites in Unity. The plugin assumes that the Sprites are imported with Unity's default settings. Let me know if this helps. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
There's a Unity project in the SpriterDotNet repo. It is not up to date due to a recent push to implement all the features in the core library. However, it's being worked on and should be complete soon (as a nice Unity package). Thanks for the feedback! While writing the library I took really a lot of effort into breaking down everything into smallest possible methods and naming everything in a consistent and meaningful way (hoping to have self-documenting code). Also, I used only the most common data structures which are available in virtually any language. But I understand why it might be a bit hard to understand, especially if you're not familiar with the scml data structure. In light of this, I will add a document that explains the general flow. In the meantime, you can start by looking at the "main" method and trying to follow the flow while keeping any scml open for reference. I've added a note about animation blending in the official documentation. The crash you discovered should not be happening and I'll fix it asap. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Yeah, I didn't even realise that. The Unity plugin is a little behind the MonoGame example because I've been focusing on implementing all the features in the core library. With that finished, I'll focus on fixing the Unity plugin ASAP. Thanks for reporting the issue! -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Glad you like it :) Which animation is affected by this? In the next couple of weeks I'll add support for the remaining features in the Unity plugin so I'll probably heavily modify the current version but still, I'd like to keep an eye for these potential bugs. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Massive update. SpriterDotNet now implements ALL Spriter features. :mrgreen: -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Implemented Animation Blending. Changed the license from MIT to zlib. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Fixed, thanks. @All if you find any other issues, please let me know. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Yeah, it is related to negative scales and angles. I managed to find a solution but I'm waiting for lucid to confirm (sent him a pm) if I got that right. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Thanks! :) There's definitely an issue with this. Everything except the last keyframe seems to be working fine. Also the instant curve works as it should - not interpolating between keys, just showing the last keyframe. But in the last keyframe (Time = 171) something goes wrong and everything is at a weird angle/position. I manually stepped through the code and it seems that everything gets calculated as per the scml. @Lucid, any ideas what might be the cause? Screenshots of the anim at the 3 keyframes: -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Yeah, absolutely. Just try to describe the issue as best as you can and pinpoint the exact .scml / animation / time and I'll give my best to fix it. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Good catch! Everything alpha related should be fixed now. Out of interest - which framework do you use? -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
I changed the default behaviour from forcing the loop to respecting the data from the scml. Based on this, Walk and Idle are looping and Get_hit_0, Get_hit_1, Attack, Crumble, Regenerate and Gonna_Regenerate don't. Crumbled also technically loops but it only has one keyframe so it looks static. I added the X key to reset the animation for testing animations that don't loop. IMO, it's easier to see what's going on if you loop these animations on demand. If you want all the animations to loop you can either override the AnimationFinished method (or Step if you need more constrol) in MonogameSpriterAnimator or your derived class. Let me know if you have any other issues. Cheers -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Fixed! Thanks to Lucid for great support. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Oh, that explains a lot. I was crunching through a lot of data and going through raw XML never bothering to actually look in Spriter :) As always, thanks Mike for the quick support. I updated the GitHub source and now the Walking animation should work fine. Also, I added the issue of animations with changing hierarchy as an enhancement for the future (when this feature gets documented) -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
I managed to get the WonkySkeleton walk animation working. However, I noticed that the Crumble animation also behaves in a strange way so I'm investigating that at the moment. Did you encounter any other animations that behave in a strange way? I'm trying to find more examples since the skeleton is rather complex and that makes it harder to pinpoint the actual cause. I'll update the lib when I fix the second problem as well. -
SpriterDotNet - An implementation for all C# frameworks
loodakrawa replied to loodakrawa's topic in Spriter Implementations
Thanks for the feedback - I'll test it out and try to fix it ASAP.