This is a tool I’ve put together for some artists I work with sometimes, so that they would be able to set up their work functionality inside of a level without needing to wait for me to get around to writing the code to drive the Animator parameters.
The idea is really simple-
Activators trigger a UnityEvent, Reactors listen and set the appropriate values to the appropriate parameters, all through the inspector. No scripting necessary.
Above, a proximity activator- specify the layers to look for, and attach to an object with a trigger collider. The Event can be called on enter or exit. Delay is a time delay(in seconds) for firing the event.
Other types of Activators-
Impact- Fires on collision, with an optional field for a minimum force requirement
Animation- Fires on an Animation state enter or exit.
Reactors allow you to specify activators that will be listened to, as well as parameters to be set upon the event firing. Bools have an additional option to simply invert the current value rather than set the same value repeatedly.
What do you think? Useful? Something better out there already?
I took a look at the ITween Editor, and it looks very robust!
A few differences I notice is that my package makes use of the Animator and Animation features of the Unity Editor, which means you can build state machines where animations trigger other animations.
iTween also uses Unity Events to call methods- do you use this functionality often?
I have to say, I like iTween’s easing presets- I’m conflicted since the Animation window in Unity allows tweaking the easing curves manually, which is more flexible- but there isn’t a straight “click and done” option to auto shape a curve to conform to an easing formula.
I’ve expanded the concept of Activators to include evaluations- additional checks that can be added to an activator.
For instance, a Proximity Activator’s base evaluation can fire its event when an object enters the trigger zone. This will start an input evaluation that checks for a particular button press.
Because there are multiple events per Activator, other objects can subscribe to different parts of an activator- in the gif above, the 3D text prompt is driven by the proximity activator’s base event, and the door itself is driven by the post evaluation event.
If driving the Animator with events sans scripting sounds like something you could use, I’m actually gearing up to enter a closed alpha testing phase.
I’m seeking individuals to test drive the project, report bugs, and correspond with me a bit on how to improve it. This will all be done through a google group.
Let me know if you’re interested by sending me a message via the forums, posting here, or sending an email to macriluke0@gmail.com. Please include “Activators And Reactors” in the subject line.
I’ve put this project on hold- it couples really closely with the Animator component- which it seems is undergoing some exciting changes that i’d like to take advantage of.