ATTRIB(Keyframe, currentChild, entity, NULL)
ATTRIB(Keyframe, firstChild, entity, NULL)
ATTRIB(Keyframe, lastChild, entity, NULL)
-ENDCLASS(Animation)
+ENDCLASS(Keyframe)
entity makeHostedKeyframe(entity, void(entity, float), float, float, float);
entity makeKeyframe(entity, void(entity, float), float, float, float);
float getNewChildStart(entity);
return me;
}
-entity addEasingKeyframe(entity me, float animDurationTime, float animEnd, float(float, float, float, float) func)
+entity Keyframe_addEasing(entity me, float animDurationTime, float animEnd, float(float, float, float, float) func)
{
entity other;
other = makeEasing(me.object, me.setter, func, getNewChildStart(me), getNewChildDuration(me, animDurationTime), getNewChildValue(me), animEnd);
return me.startValue;
}
-void addAnimKeyframe(entity me, entity other)
+void Keyframe_addAnim(entity me, entity other)
{
if(other.parent)
error("Can't add already added anim!");
me.lastChild = other;
}
-float calcValueKeyframe(entity me, float tickTime, float animDuration, float animStartValue, float animDelta)
+float Keyframe_calcValue(entity me, float tickTime, float animDuration, float animStartValue, float animDelta)
{
if (me.currentChild)
if (me.currentChild.isFinished(me.currentChild))