| View previous topic :: View next topic |
| Author |
Message |
Simbad
Joined: 17 Jul 2008 Posts: 4
|
Posted: Thu Jul 17, 2008 6:24 am Post subject: Bug animation problem |
|
|
Hello,
I wish to use one of the bug from animation in background animation of my Site.
However, the bug has small radius. I mean, it's path is about 200 px around, and I wish to move it on the whole my screen.
What need I change?
Thank you very much. |
|
| Back to top |
|
 |
Simbad
Joined: 17 Jul 2008 Posts: 4
|
Posted: Thu Jul 17, 2008 4:18 pm Post subject: |
|
|
Thank you Rich,
But I see this... and this doesn't solve my problem.
| Quote: | | Radius a value from 0 - 10 that controls how 'curved' the motion path. A value of 0 indicates a straight line path. |
As you can see, Radius values can't help in this case. I wish that bug move around not just 200-300 px, but to walk on the whole page.
Thanks. |
|
| Back to top |
|
 |
Simbad
Joined: 17 Jul 2008 Posts: 4
|
Posted: Fri Jul 18, 2008 7:49 am Post subject: |
|
|
Thanks Rich,
Unfortunately I can find bounding clip value.
Here it is what I have:
| Code: | onClipEvent(load) {
// Begin MotionWalk Behavior
// create motion path
_global.mw_testing = false;
var motion_path = new flextnet.utility.MotionPath(this);
var path_sign = 1;
// user defined params
var radius = 5/10;
var speed = 3;
var bounds = this.getBounds(this._parent);
var walk_direction = "both";
// inner and outer boxes for path endpoints
var h_walk = new Object();
h_walk.left = bounds.xMin -_width;
h_walk.top = bounds.yMin + _height;
h_walk.right = bounds.xMax + _width;
h_walk.bottom = bounds.yMax - _height;
var v_walk = new Object();
v_walk.left = bounds.xMin + _width;
v_walk.top = bounds.yMin -_height;
v_walk.right = bounds.xMax - _width;
v_walk.bottom = bounds.yMax + _height;
var active_walk = h_walk;
var fixed_walk = (walk_direction != "both");
if (walk_direction == "top <-> bottom") active_walk = v_walk;
// kick start
clearPath();
// move the bug every frame
function onEnterFrame()
{
// create a new path if necessary
if (!motion_path.isPathDefined())
{
var path_params = new Object();
// get a random position in the outer ring box
var fx, fy;
if (active_walk == h_walk)
{
fx = (path_sign < 0) ? h_walk.left : h_walk.right;
fy = h_walk.top + Math.floor(Math.random()*(h_walk.bottom-h_walk.top));
}
else
{
fx = v_walk.left + Math.floor(Math.random()*(v_walk.right-v_walk.left));
fy = (path_sign < 0) ? v_walk.top : v_walk.bottom;
}
path_params.fx = fx;
path_params.fy = fy;
path_params.control_multiplier = (Math.random() < 0.5) ? radius : -radius;
motion_path.createPath(path_params);
// create circular overall motion
path_sign = -path_sign;
// possibly change directions
if (!fixed_walk)
{
active_walk = (Math.random() < 0.5) ? h_walk : v_walk;
}
}
var timer = getTimer();
var t = (timer - start_time) / life_time;
if (t <= 1) motion_path.moveActiveClip(t);
else clearPath();
}
function clearPath()
{
// time bounds
start_time = getTimer();
life_time = (11-speed) * 1000; // milliseconds
motion_path.clearPath();
}
}
// End MotionWalk Behavior
|
I don't know what I need to change from above. |
|
| Back to top |
|
 |
Simbad
Joined: 17 Jul 2008 Posts: 4
|
Posted: Fri Jul 18, 2008 1:51 pm Post subject: |
|
|
| Quote: | | To get more precision, what you can do is create a rectangle on the stage of the size you want the bugs bound to, then turn it into a movie clip and give it an instance name. Then pass that to the 'getBounds' function-- it's just looking for a movieclip there. |
Yes, it works
Thank you very much. |
|
| Back to top |
|
 |
deloresi
Joined: 25 Jul 2009 Posts: 1
|
Posted: Fri Jul 31, 2009 7:55 am Post subject: |
|
|
What elements come together to make a classic animation? I'm a fan of animation of most types be it a 24 minute comedy, an hour and a half feature. (By animation I mean ANIMATION, not CGI rubbish thats ruined disney over the last 10 years). So what in your opinion makes a classic animation?
_____________
matrimonial |
|
| Back to top |
|
 |
gladysila
Joined: 19 Dec 2009 Posts: 1
|
Posted: Wed Dec 23, 2009 6:48 am Post subject: |
|
|
What kind of license do I need to include an animation in a tv programme? I am making a one off tv documentary where I wish to include a short animation. The animation is a totally complete entity in itself with titles etc and is currently distributed as a finished short film. It's five minutes long and I do have permission from the owner to include it. What kind of release forms or licenses should I get signed to cover me in case of any future disputes? Especially as it's a major part of the programme and I don't want it's inclusion jeopardised. Many thanks.
__________________
external keyword tool ~ keyworddiscovery.com ~ keycompete.com ~ compete.com ~ webmasterworld.com
Last edited by gladysila on Tue Dec 29, 2009 9:55 pm; edited 1 time in total |
|
| Back to top |
|
 |
rich Site Admin
Joined: 25 May 2007 Posts: 286 Location: nyc
|
Posted: Wed Dec 23, 2009 2:42 pm Post subject: |
|
|
Hi gladysila
Thanks for contacting us... as soon as you purchase an item on our site, you are granted full legal rights to use it anyway you wish, except for re-sale.
Regards,
Rich Lovejoy
www.flashextension.net |
|
| Back to top |
|
 |
|