[F8] Smooth Random Movement
i have this code
Code: offx+=(random(4)-random(4))/5; offy+=(random(4)-random(4))/5; if(Math.abs(offx)>2){ offx = Math.floor(offx/2); } if(Math.abs(offy)>2){ offy = Math.floor(offy/2); } scope._x=_xmouse+offx; scope._y=_ymouse+offy;
but it is jerky i want it to move smoothly. Anyone know a better way?
FlashKit > Flash Help > Flash ActionScript
Posted on: 08-13-2007, 09:10 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Smooth & Random AS Movement
Hi Guys...
Here's the script:
onClipEvent (enterFrame) {
xPos = this._x;
randomNum = Math.round(Math.random()*(max-min+1)+(min1));
trace(randomNum);
this._x = xPos+randomNum;
}
Im trying to move an object (like a cloud), smoothly and randomly across the screen...
But this is a bit jerky, any ideas?
Thanks, Rob
Smooth Movement
Hi,,
I am new to Flash. I created a scene with an object. I have included 15 frames from the first keyframe and set to motion tween.
Now when I play the scene, the object doesn't move smoothly from first frame to last frame. The movement is kind of broken. Am I missing something here?
I have seen many flash files with very smooth moving objects. How do I do it?
Any Help will be appreciated.
Smooth Movement
Hi everybody,
I am trying to do a simple motion tween, shape enters from upper left corner & exits from the lower right corner.
My problem is the the movement looks jerky, I tried to increase/decrease the number of frames and increase/decrease the frame rate. I did not succeed to make the movement smooth.
Can somebody counsel me on this.
Thanking you in advance
Hrisula
Smooth Movement
I have an image that I want to move in a sort of smooth rolling manner. Like the following site.
http://www.detremmerie.be/
The movement of the image seems to slow down before it stops. In my Flash document, the image just moves from one end to the other at a constant speed, before it stops. Here's my code:
onClipEvent(enterFrame) {
speed = 12;
if (this._x < -327.75) {
this._x += speed;
}
//makes the movement stop
else {
this._x = -327.75;
}
}
Any suggestions on how to make my movement more like the example?
Thanks
Smooth Movement
Hello.
I'm making a flash project that is a small vector city. There I have o lof of buildings that must be all as vector images, because my flash will be full screen. My problem is every move I make there looks like a little jumpy. I can't get smooth movements on the cars, the train and the airplane. I've tried make the animation using the timeline and in a couple of actionscript scripts, but the result I have is always that jumpy movement. Who of you are the guru to give me the solution? I'll be very pleased about.
Thank you very much.
Marcelo.
Smooth Movement
Hey everyone,
I am producing a game where a gitty little dog runs around and does cool little quests. All is grand and dandy except for the most important part, the movement. I want him to be able to run over wavy hills, but my script doesnt allow that. It's very jigged. Basically my script sais
"when the dog touches these bounds, it will be pushed away from the bounds"
here is the script attached to the hills:
onClipEvent (enterFrame) {
with (_root.dog) {
if (hills.hitTest(getBounds(_root).xMax, _y, true)) {
_x -= 12;
}
if (hills.hitTest(getBounds(_root).xMin, _y, true)) {
_x += 12;
}
if (hills.hitTest(_x, getBounds(_root).yMax, _x, true)) {
_y -= 6;
}
}
}
My dog also is moved with the keys, this is a simple script that works fine, but the script attached to the hills is screwy.
I feel like totally deleting script, and taking a smoother one you guys tell me. I would like the dog to be able to run along the hills and rotate with their slope.
Can someone help? Anyone have previous history with side-scrolling games?
Smooth Movement?
What I am doing is moving a movie clip around on the stage when the user presses one of the arrow keys. Since I am moving it by a number of pixels each time the user presses the key the movement looks choppy, and I was wondering if anyone could recommend a way to do this so that the movement looks more smooth. A quick example of what I'm doing (although I'm sure you've already assumed this):
if ((Key.isDown(Key.RIGHT))) {
this._x += 20;
}
Any help would be greatly appreciated. Thanks so much!
Smooth JPG Movement
Does anybody know how to create a smooth JPG movement like this
http://www.beverlyhillshotel.com/
All the thing try (Actioscript _xscale etc.) end up looking bad......
Need some help here
Thanks in advance
Martin, Holland
Smooth ._y Movement
Hello all. I have a simple problem, which I'm sure can be resolved quite easily. I have a movie clip that's viewable through a mask, acting as a window for content. There are two buttons which move the movie clip up and down through the window, moving in increments of 5, but the user has to repeatedly press the button to make it keep moving, which is quite tedious.
Is there a way I can have the action repeat continuously as the user holds the button down, creating a smooth movement of the movie clip?
Much thanks.
How You Do That Smooth Movement?
Was just wondering how a lot of sites can do that smooth movement. Everytime I do motion tween with objects I get that slow rough stiffy movement.
Thanks.
Movement Not Smooth
Hi,
I have the following script in both frame 1 and 2 to let a movieclip move from right to left on the stage:
Code:
speed =-5
name._x += speed
if (name._x<-500) {
name._x = 250;
}
And the clip is indeed moving from right to left on the stage and when it reaches _x -550 it is going back to it's starting position _x 250 only the movement isn't smooth at all.
What should I do to make the movement more smooth or should I use a completely different script?
Thanks in advance
Key Movement Not Smooth... :(
Hi.
I´m looking for a way to code keyboard movement that is smooth. I mean, constant from the moment the key gets pressed to the moment it gets released. What I have now works like typing: u press the key, u get one glyph, then if u dont release after half a second or so u start typing lots of glyphs.
It will not do for caracter animation, and that is what i need to code.
Any ideas?
Smooth Out Movement
Hey, I just used a tutorial -> http://www.kirupa.com/developer/mx/random_motionMX.htm
and it works fine...but i didn't know if anyone knew how to smooth out the movement between positions...so its not so rigid....THANKS!
How You Do That Smooth Movement?
Was just wondering how a lot of sites can do that smooth movement. Everytime I do motion tween with objects I get that slow rough stiffy movement.
Thanks.
Movement Not Smooth
Hi,
I have the following script in both frame 1 and 2 to let a movieclip move from right to left on the stage:
Code:
speed =-5
name._x += speed
if (name._x<-500) {
name._x = 250;
}
And the clip is indeed moving from right to left on the stage and when it reaches _x -550 it is going back to it's starting position _x 250 only the movement isn't smooth at all.
What should I do to make the movement more smooth or should I use a completely different script?
Thanks in advance
Key Movement Not Smooth... :(
Hi.
I´m looking for a way to code keyboard movement that is smooth. I mean, constant from the moment the key gets pressed to the moment it gets released. What I have now works like typing: u press the key, u get one glyph, then if u dont release after half a second or so u start typing lots of glyphs.
It will not do for caracter animation, and that is what i need to code.
Any ideas?
How To Get Smooth Movement
i have seen movies that have motion that seems way smoother than what i can get, i am thinking that there must be some better way to move things around, including open boxes, menus and such. anybody want to fill me in on the secret? simply putting in a motion tween is always jumpy, especially on fade ins and fade outs of images, even at 35 frames.
thanks folks
Help With Smooth Movement
I want to use an effect like the one on this site: http://www.federicafontana.it/index3.html
(Settle down boys Nice work, huh?)
That is, I like the way the small windows open. Can anyone lead me to how this is done? I suspect it is scripted vs. tweened, no? It'd be great if you can lead me to a site with some source.
Anyway, have fun on the site.
Thanks,
Rick
Truly Smooth Eased Movement
i was looking for how to script the smoothest movement possible myself and had to pull it together from a few places so i'm gonna post it here real quick
the problem is the jerkiness, all scripted movement or tweening is tied to frame rates, even at its best (an absolutely empty flash with one square box drawn on it) you can jerkiness in the movement, the higher you turn your fps the better it looks but the less likely it is to look that way to the user, fps overclocking isn't the answer
the solution is to use an equation triggered by the clock to control the movement with updateAfterEvent() at the end of the function that does the movement
using updateAfterEvent() with on mouseMove clip event produces a perfect cursor (windows movement), not a jerky one
so to move a clip called box along x:
Code:
// set variables needed to whatever
seconds = 5;
duration = seconds*1000;
x_start = 100;
x_target = 400;
startTime = getTimer();
function doMover() {
// calculate easing based on how much time has passed
var elapsedTime = getTimer()-startTime;
k = elapsedTime/duration;
if (k >= 1)
{
k = 1;
clearInterval(ih);
}
k = k*k*(3-2*k);
// apply easing
block._x = x_start+(x_target-x_start)*k;
// now don't wait for next frame
updateAfterEvent();
}
// call function at intervals
ih = setInterval(doMover,10);
this is just the heart of the code you need, jbum's favorite ease equation triggered by setInterval with updateAfterEvent() to make sure it doesn't have to wait for movie, use it to do anykind of easing - color, size, alpha
help me if i'm wrong!!! or if something could be better
Smooth Movement Using Keyboard
I'm making a platformer that uses WASD for movement, and I am using the form (using d to to move left as an example):
onClipEvent (keyDown) {
if (Key.getAscii()==100){
this._x +=10;
}
}
The problem is that, when the key is held down, the MC moves a tiny bit to the right, sits for a second, then scrolls smoothly (like the speed things go when you hold down a letter key in a word processor) and i need it to scroll smoothly all the time. Any tips on how this can be accomplished? I am using MX 2004.
Smooth And 'flowing' Movement
Can anyone please give me tips on how to create smooth-flowing (just like in the cartoons) animations in Flash?
My problem is, when I create a tweening animation, the graphics seem to be choppy just like a GIF animation; the frame rate seem to "skip" along the way; evidently showing jerky movement.
Thanks for looking, I use Flash MX 2004.
Smooth Game Movement
Hey all,
I'm having issues with the characters and objects moving monumentally different between the standalone player and inside a browser. Obviously, the characters are moving significantly slower in the browser.
How can you correct this? How can I make the player move at the correct speed regardless of framerate (within a limit)? I can set the FPS to something like 90, but that's just a fix on my machine and won't make things smooth on other's necessarily.
Any tips and tricks to smooth movement?
Smooth Wavy Movement
I was trying to make some cool looking smooth wavy enemy movement. Kind of something like the enemy movement in Bubble Tanks 2.
I can make my enemys go where I like to and do what I like to, but everything looks very abrupt. I would like to make them curve around when they change direction and even curve around a bit while moving. But I can't seem to figure out how. Any help?
Smooth Easing Movement
hi,
i'm using flash mx 2004, and i need a simple script that's easily customizable, where a button press would trigger a movie clip to move to certain point using easing, where it zooms out, then slows down as it reaches the point.
i'm starting to move into using more actionscript and less tweens for movement.
thanks.
Smooth Movement Sometimes Not Working
Hi everybody,
I have the code below, creating movements and changes of alpha values of three mc.
When I test the animation sometimes the animation is smooth, sometimes it isn't. Is there anything wrong with this code?
Thanks a lot
Code:
mc3._alpha = 0;
//
function fvmoving() {
mc1._xscale += (50 - mc1._xscale) * 0.3;
mc1._yscale += (50 - mc1._yscale) * 0.3;
mc1._y += (300 - mc1._y) * 0.3;
if (mc1._xscale > 50 - 1 && mc1._xscale < 50 + 1 && mc1._yscale > 50 - 1 && mc1._yscale < 50 + 1 && mc1._y > 300 - 1 && mc1._y < 300 + 1) {
mc1._xscale = 50;
mc1._yscale = 50;
mc1._y = 300;
mc2._xscale += (50 - mc2._xscale) * 0.3;
mc2._yscale += (50 - mc2._yscale) * 0.3;
if (mc2._xscale > 50 - 1 && mc2._xscale < 50 + 1 && mc2._yscale > 50 - 1 && mc2._yscale < 50 + 1) {
mc2._xscale = 50;
mc2._yscale = 50;
mc3._alpha += (100 - mc3._alpha) * 0.3;
if (mc3._alpha > 100 - 1 && mc3._alpha < 100 + 1) {
mc3._alpha = 100;
clearInterval(fvmov);
}
}
}
updateAfterEvent();
}
//
var fvmov = setInterval(fvmoving, 50);
Make Smooth Movement
One more question. I tried to create a floating effect on a big image using motion tween. When it moves, the movement is very jerky no matter how slow I make it by increasing the frame.
Is there any way to make the floating effect smooth? Thanks again for all the replies.
Smooth Movement Sometimes Not Working
Hi everybody,
I have the code below, creating movements and changes of alpha values of three mc.
When I test the animation sometimes the animation is smooth, sometimes it isn't. Is there anything wrong with this code?
Thanks a lot
ActionScript Code:
mc3._alpha = 0;
function fvmoving() {
mc1._xscale += (50 - mc1._xscale) * 0.3; mc1._yscale += (50 - mc1._yscale) * 0.3; mc1._y += (300 - mc1._y) * 0.3;
if (mc1._xscale > 50 - 1 && mc1._xscale < 50 + 1 && mc1._yscale > 50 - 1 && mc1._yscale < 50 + 1 && mc1._y > 300 - 1 && mc1._y < 300 + 1) {
mc1._xscale = 50;
mc1._yscale = 50;
mc1._y = 300; mc2._xscale += (50 - mc2._xscale) * 0.3;
mc2._yscale += (50 - mc2._yscale) * 0.3;
if (mc2._xscale > 50 - 1 && mc2._xscale < 50 + 1 && mc2._yscale > 50 - 1 && mc2._yscale < 50 + 1) {
mc2._xscale = 50;
mc2._yscale = 50;
mc3._alpha += (100 - mc3._alpha) * 0.3;
if (mc3._alpha > 100 - 1 && mc3._alpha < 100 + 1) {
mc3._alpha = 100;
clearInterval(fvmov);
}
}
}
updateAfterEvent(); }
var fvmov = setInterval(fvmoving, 50);
Smooth Randomly Generated Movement
Hi,
I want to display an object as if it was up in the air. I mean in “suspension”.
To do so I need to animate this object with smooth little movements generated randomly.
I get how to make move my object randomly with this :
//create the limits for the numbers
maxNum=.1;
minNum=-.1;
range=maxNum-minNum;
//Randomize
Xplus=minNum + Math.random();
Yplus=minNum + Math.random();
//Position changes
Button1._x = 25 + Xplus
Button1._y = 75 + Yplus
The thing is that the movements are not smooth.
I have tried to play with the value of “minNum” and also to divide the value returned by “Math.random()”, but even if the generated movements are smaller, they still are not smooth.
Could anyone give me some help on this ?
Hugues.
Smooth, Dynamic Movement Idea...
Well I haven't worked with actionscript for ages... Well in all honesty... all i really knew was the goto and play( commands
--
I was wondering if anyone would be able to enlighten me as to how i would go about performing the following:
I want, oh let's say three boxes. These boxes are independant of each other, and are sized and placed using actionscript. On a certain action: "onclick" let's say that i wanted the content of the boxes (which need not be contained within the "box" symbol) to be faded out, and then the boxes to move (again, independantly) to a new position, and a new size (and shape [ex. square, rectangle (sized)]). Any ideas?
Thanks
Irfaan
Smooth Movement Back And Forth With Math.cos()?
I have a movie clip called myBox. I want myBox to move back and forth repeatedly - left to right to left to right, etc. Now I know I could just write some IF statements to move it a certain number of pixels left and right when it gets to a certain point, but I actually want something smoother. I want myBox to slow down when it gets all the way to the right, come to a near stop, then slowly speed up as it moves back to the left side, then slow down as it approaches the far left coming to a near stop, etc. You see the pattern here?
I am wanting this code to be in an onEnterFrame = function(){}. I presume that I need to use Math.cos() or sin() or tan() but I have tried to find tutorials using them, but they seem to be too confusing or advanced. Some of the examples I saw were using variables I never saw declared, so I just figured I'd make my own topic asking my specific question.
Rolling Menu Smooth Movement
hello all,
I have followed this tutorial on making a rolling menu http://www.shadowness.com/tutorial.p...orial_id=43#02
The problem I am having is making the menu item scroll smoothly and stop at a picture frame when you mouse over. I would also like to load a 2nd layer of images into this menu once a picture has been selected. any help on this would be ace ..
Cheers Peeps ...
Assigning Smooth Movement To Mc Problems
I have problem with assigning an smooth animation to mc, in main time line I have this script:
ActionScript Code:
function move_foto() {
if (ww>194) {
_root.zdj["fot"+i].foto_a.foto_a_a._x = 194-ww;
}
}
function readme() {
for (i=1; i<(n3/2); i++) {
duplicateMovieClip(_root.zdj.fot, "fot"+i, i+200);
setProperty(_root.zdj["fot"+i], _x, i*197);
if (myFOTO.childNodes[i].nodeName == "foto_a") {
nazwa = myFOTO.childNodes[i].attributes.pict;
trace("nazwa zdjecia: "+nazwa);
loadMovie("foto/"+nazwa+".jpg", _root.zdj["fot"+i].foto_a.foto_a_a);
//ww: the width of the foto;
ww = myFOTO.childNodes[i].attributes.w;
move_foto();
}
}
}
Now the script just moves the loaded image right to the final place, but how to modify the script or the mc so that it can be seen the movement of the jpg.
Please help, it's urgent.
Smooth Circular Motion/movement
Hello guys,
how can I make a circular movement of an object around a point ?
I.E: a word around a dot ? I know I need to use some math funcs. but I cant manage to do it. Also I want it to move smoothly, like floating in water, like elastic. I hope u understand.
Thanks.
Re: Smooth Movement Back To Origin.
What up. I'm making a website, and it's using a drag and drop type deal for navigation. Basically the user must click and drag a module into the "dropZone" to go to that particular section.
here's the AS I'm using so far:
ActionScript Code:
<i>this.onLoad = function() { startX1 = button1._x; startY1 = button1._y;};</i>dropZone.onMouseUp = function() { //------------------------------ if (dropZone.hitTest(button1)) { button1._x = dropZone._x; button1._y = dropZone._y; button1.stopDrag(); <b>} else { button1._x = startX1; button1._y = startY1; button1.stopDrag(); }</b>};
Basically, button1 is the button that the user is dragging to the drop zone. Now, my query is about the bolded section. What that does, is when the user *unclicks* the mouse button, the module springs back to its origin which is defined during an onLoad event (in italics). Right now, it just jumps back to the origin, as opposed to smoothly animating back to the origin (which is what i want, and don't know how to code). Thanks in advance!!!!
Smooth Mouse / Scolling Movement
Hi there,
I am creating a dragging scrollbar movie of a timeline (the history kind, not the flash kind). I am using the actionscript to control the movement of the clip. The following code is placed on the dragging movie:
PHP Code:
onClipEvent (enterFrame) {if (dragging) { this._x = _root._xmouse; dxdrag = this._x - start_x; start_x = this._x; _root.timeline._x -= speed*dxdrag; }}
Now this all works great, and is pretty smooth. But I would like to smooth it out more and add some easing, both in and out.
Does anyone have any ideas how to do this? Do I need to use a tweening class like PennerEasing?
Thanks,
Steve
EDIT: I just realised i missed off a massive thing. Because this is a timeline, certain points on the scrolling area have to correspond exactly with points on the main content.
Had best add that "speed" is worked out as the difference between the widths of the two movieclips, the dragger and the content..
Smooth Circular Motion/movement
Hello guys,
how can I make a circular movement of an object around a point ?
I.E: a word around a dot ? I know I need to use some math funcs. but I cant manage to do it. Also I want it to move smoothly, like floating in water, like elastic. I hope u understand.
Thanks.
Re: Smooth Movement Back To Origin.
What up. I'm making a website, and it's using a drag and drop type deal for navigation. Basically the user must click and drag a module into the "dropZone" to go to that particular section.
here's the AS I'm using so far:
ActionScript Code:
<i>this.onLoad = function() { startX1 = button1._x; startY1 = button1._y;};</i>dropZone.onMouseUp = function() { //------------------------------ if (dropZone.hitTest(button1)) { button1._x = dropZone._x; button1._y = dropZone._y; button1.stopDrag(); <b>} else { button1._x = startX1; button1._y = startY1; button1.stopDrag(); }</b>};
Basically, button1 is the button that the user is dragging to the drop zone. Now, my query is about the bolded section. What that does, is when the user *unclicks* the mouse button, the module springs back to its origin which is defined during an onLoad event (in italics). Right now, it just jumps back to the origin, as opposed to smoothly animating back to the origin (which is what i want, and don't know how to code). Thanks in advance!!!!
Smooth Interpolation Movement ? (not Shaggy)
Hello,
Do you know how to do a very clean interpolation movement
of a light rotating (from -45 degres to 45 degres for instance) ?
I ve done one manually and i find it bad to look at. (not clean)
I could post the *.fla if it is possible. Tell me...
Thank you
Anthony
Smooth Circular Movement On Release
I have a draggable movieclip that can be dragged to anywhere on the stage and on release if it doesn't drops on the target makes a smooth movement back to the initial position. My idea is to on the drop if it doesnt' drop on target when going back th movieclip should do a smooth curved movement, like the image (a bombshock worthy image)
Could any point to this kind of effect?
Stupid Problem About Smooth Mc Movement
I am doing something really simple and I dont understand where my coding error is... I am just trying to make an MC move smoothly to a certain point using AS. Here is my code:
on (release) {
current_y = _root.info.slider._y;
y_difference = current_y - new_y;
new_y = "50";
do {
current_y = _root.info.slider._y;
y_difference = current_y - new_y;
setProperty(_root.info.slider, _y, (y_difference)/2);
} while (new_y ne current_y);
}
I am getting an error that says the script is causing it to move slowly, which i guess means an infinite loop. any ideas?
My Animation In Flash Dosen't Have A Smooth Movement
Hi there
I have a problem with flash
here is the link of my menu that I made with Flash
http://www.graphicday.com/moving%20menu.html
but I don't know for what reason the movement is not smooth.
how can I make something the same but with a smooth movement?
thanks
Object To Mouse Position - Smooth Movement Problemo
Hi all, I've got a ruler type line where the central point of the line follows the mouse on the x co-ordinates and scrolls left or right depending on where it is.
I've accomplished this using a MC which contains the following code and works spot on. But what do I need to do so that the central point adjusts with tweening so it doesn't follow at the same pace, like when you set the easing to 100 using tweening?
Thanks in advance. Here's the code I've used so far.
:::::::::::::::::::::::::::::::::::::::::::::::::: :
Frame 1 of MC
:::::::::::::
if (_root._xmouse>_level0.calib._x) {
_level0.calib._x = (_level0.calib._x+1);
} else {
_level0.calib._x = (_level0.calib._x-1);
}
:::::::::::::
Frame 2 of MC
:::::::::::::
if (_root._xmouse>_level0.calib._x) {
_level0.calib._x = (_level0.calib._x+1);
} else {
_level0.calib._x = (_level0.calib._x-1);
}
gotoAndPlay (1);
MX2004: Campus Map, Smooth Scripted Movement And Other Problems
hi everyone.
I could really use some help. I am working on designing a flash map for our university campus. Using MX2004. I have a lot working so far, but I am running into some stumbling blocks. I've used flash for a while, but only for simple animations, I'm pretty new to actionscripting but so far have been able to piece together tutorials, examples and so forth to get the functionality I need so far.
However, I need some tips on a few things and I hope this thread can help with the development of this.
The map loads from an external flash file so it can be updated more easily by other people down the road.
I have the controls to move it around and zoom it in by using a slider and some nav buttons, both of which has been hacked together from different examples.
Now, I am trying to create a list of buildings that when clicked on colors the building and moves the view to where that building is located.
I am doing this in the following way:
each building in the imported map is a movie clip comprised of 2 frames, each with a stop(); command. the first frame is the normal color, the 2nd frame the building is colored orange.
in my list, which will be just a list of text buttons, a user clicks once on a building name and it advances the building movie clip frame foward to the next frame, which changes the color, and the next click on the same button moves to the previous frame setting the color back to green.
Problem is, if the user is not zoomed all the way out, they won't see which building is being highlighted. So what I would like, is despite what zoom or x/y position the map is currently at, when they click on a building it moves to a preset x/y coordinate and zoom level that is preset to center that selected building within the viewable area of the map window.
I have the movement and zoom kind of working, but it jumps to it. What i would like is some actionscripted smooth movement toward the preset x and y coordinates from whereever the viewer currently is.
here is the code i'm using right now for when a user clicks on a building name button:
Code:
on (release) {
if (Number(button) == 2) {
_root.mainMap.mainMap.alumnicenter.nextFrame();
_root.mainMap._y = 404; //vertical position
_root.mainMap._x = 457; //horizontal position
_root.mainMap._xscale = 300;
_root.mainMap._yscale = 300;
_root.slider._y = 27; //height of slider on range bar
_root.slider._x = 144.3; //dont change
button = 1;
} else {
_root.mainMap.mainMap.alumnicenter.prevFrame();
_root.mainMap._y = 204; //vertical position
_root.mainMap._x = 457; //horizontal position
_root.mainMap._xscale = 150;
_root.mainMap._yscale = 150;
_root.slider._y = 95; //height of slider on range bar
_root.slider._x = 144.3; //dont change
button = 2;
}
}
the flash file is too big to attach and like i said it pulls from external files, if needed I can package up the folder in a zip file, but here is the latest swf file to give you an idea. http://acketon.com/campus_map1.html
here's what's being replaced: http://www.selu.edu/map this is all part of a major redesign effort of the entire website. Most of which is done or underway, but I have taken this on as a project.
Tips For Tweening Large Movieclips For Smooth Movement?
Hi there!
Ive always had problems tweening big movieclips, motion isnt as smooth as I would like. I usually work in video so I am used to seeing everything precomposed! Are there any tips or best practices I can employ for smooth motion?
Here is what I normally do:
I use the Zigo tween engine from the Fusekit.
Wherever possible, I cacheAsBitmap
I also avoid using strokes, and have solid filled objects.
Set my frame rate at 30fps
For my next project im going to need to recreate a world that rotates, very similar to the Patapon website. The motion on this looks pretty good! How have the achieved that?
Thanks!
Steve
Random Rotation To Equal Random Movement Direstion?
k i finally got it so that my things randomly move around the screen and have walls etc etc.. anyways now i wanna know how to make it so that my randomly moving ship will rotate to face there direction if you want i can post the code i am using for random movement and thanks in advance
Smooth Random?
hello!
i got this random script from a flash book. it makes the ball bump around randomly in a area 200x200. is there anyway to make it smooth, instead of the circle popping about here and there?
bluX = random(200);
bluY = random(200);
circle._x = bluX;
circle._y = bluY;
thanks!
nitroblu
Smooth Random Motion?
Hey all,
I'm trying to create a preloader effect with random motion and having a lot of trouble...
Basically, there is a bar into which 10 "pieces" (mcs) fit inside. I want the mcs to float around the stage randomly, and as each 10% of the movie is loaded, one mc stops floating around and slides into place on the loading bar. Hopefully that makes sense? It's been done before, so maybe you've seen the effect out there.
Anyway, no matter what I've tried I can't get the mcs to float around randomly, let alone do what I want them to do. Can someone point me in the right direction? I did manage to get a clip to duplicate 10 times, and then give each clip a random location on the stage. From there, every script I've tried either moves things around WAY too quickly/abruptly, or the pieces all end up moving to the same coordinates. I want each to move individually, and with a nice smooth animation rather than assigning a value and just jumping them around.
I have no idea what I'm doing wrong, and at this point my code is fouled up royally and is all but useless or I would post that. Can someone give me an idea how to do this? Any help would be great! Some code, a tutorial, whatever...I'm open.
Thanks.
Random Smooth Waving Line
Hi guys,
I've searched the net and I couldn't find anything on this.
I have this line:
http://img216.imageshack.us/img216/3...inglineej8.png
And I want it to randomly wave like if it was a hair in the wind, or like a snake moving, or even like a flame waving.
Is there any way of doing it with actionscript?
Is it also possible to make react to the cursor? When I pass through it with the mouse it moves, like if I just touched it.
Thank you very much
Smooth Transition Between Random Colors
how can I make a smooth transition between random colors?
so far I have this done:
this is on the frame action:
myColor= new Color (_root.box);
_root.b1.onRelease = function(){
myColor.setRGB(_global.rndColor)
}
and this is in a movie clip which is off stage, generating a random
value:
onClipEvent (enterFrame) {
_global.rndColor=Math.round(Math.random()*0xffffff );
}
There is a nice one in the tutorials, but I'm not able to use it for some reason. Maybe because it is not for MX 2004.
can anybody help?
|