kayy / animatoraccess Goto Github PK
View Code? Open in Web Editor NEWCode generator utility for Unity game engine. Creates a class for convenient access Animator states and parameters
License: MIT License
Code generator utility for Unity game engine. Creates a class for convenient access Animator states and parameters
License: MIT License
Currently the generate AnimatorAccess has a default namespace which generates warning if the file isn't in the corresponding directory. I think you could very easily determine the correct namespace by the directory the user chose to save the generate file.
Also it has an unused "using System.Collections;".
Unlike transition handlers, state's onChange handler is not null checked.
Because of this, calling AnyState (0) without adding onChange event causes null reference exception.
It might look trivial, but this also happens when removing the registered onChange handler.
I made a small pull request - hope you like it this time too :)
There are many errors pop up and cannot function correctly.
I use Windows and get an inconsistent line endings on my generated AnimatorAccess class.
I checked the template for windows (DefaultTemplate-Win.txt) and it also contains inconsistent line endings, so I think it's the cause.
If anyState->otherState exists, AbstractTransitionHandler.GetTransitionInfo returns null with "No transition info found for transition" warning message. Thats because generated "InitialiseEventManager" method does not add anyState based transitions.
To handle these transitions, we need to handle this case separately.
I created a pull request, hope you like it. :)
Anyway its really an interesting idea and works well. I think its essential until unity5 is up.
Hey,
I realized now that there is no support for states that are substates.
How difficult would it be to support them?
Example:
AnimatorAccess.State(AnimatorAccess.stateIdSomSubState); //Cannot find such stateId.
Hi, its been a while since I last reported little issues.
Due to your help and many authors nice libraries' big help, my project is progressing daily.
Today I found a memory related problem. In animator access generated code, it looks like CheckForAnimatorStateChanges routine is constantly allocating memories. It might look trivial, but its done per frame - which need to be avoided if possible... As you know this can lead to frequent GC call..;
I don't know if you are still managing this project, but as a duty of users, reporting this issue :D
I attached an image for you, so you can easily identify the issue.
Let me know if you can handle this problem. Thank you !!
It would be nice to have access to the animation duration and current time in the animator state. e.g:
anim.state(anim.stateIdIdle).Duration
anim.state(anim.stateIdIdle).CurrentTime //not sure about the name, but what I mean is the time passed since the animation started (CurrentTime <= Duration).
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.