[jQuery] SVG animation question
I am the amazing jQuery SVG plugin with the animation extension for a
browser-based game.
When the character walks around, the camera follows him. Right now I
just pan the in huge chunks with this code:
svg.configure({viewBox: x+' '+y+' '+width+' '+height})
So I need to make a custom animation. Here's what I have so far.
jQuery.fx.step.panX = function(fx)
{
fx.elem.setAttribute('viewBox', fx.now+' '+y+' '+width+' '+height)
}
svg.animate({panX: x}, 100)
As you can see, it only works for the x-axis. How do I animate more
than one variable at a time?
Thanks for the help.