ActionScript 2.0 :: Moving MovieClip In Relation To Border Of Scaled Object
Oct 20, 2009
I have a frame_mc that get scaled 400 % onPress with a fusekit tween. Now I'll like to anchor a title_mc to the the top edge of the frame_mc without scaling it. How to do that? onEnterframe in the onPress function?
i have a character_mc that moves on mouse click, a logtxt dyanamic text box and a mc named $box. The camera follows the character and when the log and $ boxes are staying put.
I want them to stay on the same point on the stage(meaning I want them to stay at the same place on the camera) I was wondering what i might do for this? I have tried to put them in a movie clip but it doesn't really seam like it worked well so i discarded the idea.
I have a stack of images that I need to move down when the mouse is above y = 250 and up when the mouse is below y = 250. I have this code, but the problem is I don't know how to add easing.
how i could change the movieclip border around a circular object/movieclip.cuz know my my hitTestObject will also test on the corner of the movieClip and not the actual see able object like i show down here how coud i change this border to the second image?
I'm trying to draw a rectangle with as2 the to strech it's wirdth. It seems to work but something strange is happening while the rectangle is streched it is slwloy lmoving across the scene .
I have a situation where i have relations like this:A person has one or more addresses.A customer has one or more addresses.Person,customers and addresses are separate tables.I used to do this with the @OneToMany relations.This is giving me problems since our flex client is sending me objects wich are created in the client ad have to be created in the DB.If the client sends me a person and customer which reference to the same address hibernate will create two address objects since the two address object are not the same java objects (not the same pointers).This is a problem which is caused by BlazeDS and Dozer which will create new objects when they are send to the server.So what i would like to have is the address id in the person and customer object without an relation so hibernate does not create the objects. But when i read a person object i would like to fill a transient address object based on the stored address id.
I'm building a class at the moment for transforming and scaling content with align, constrain and scaling options.
This is just just fine if the transform center is LEFT or TOP_RIGHT, or what have you, and always within the object bounds, but I haven't yet tackled situations where objects are NOT nicely aligned, or the transform point is outside of the object bounds.
I've been struggling with making boundaries with my game. I've managed to make boundaries, but in stead of my game character not moving across that border it just bounces back. Which is not the effect I want.
Here's my code onClipEvent (enterFrame) { if (Key.isDown(Key.LEFT)) { xspeed -= power; } if (Key.isDown(Key.RIGHT)) { xspeed += power; [Code] .....
This is a CS4 file so and I have CS5 so if you give me either it will be awesome
I have a movie clip that follows the mouse..
Its not done yet but its gonna be a dog chasing a/the mouse...
I want to have it where the if the mouse is left or right of the following movie clip it shows it walking toward the mouse... so something like
if mouse positions is less the the cursor + 10 (pixels) goto and play frame with dog walking left and one for right up down (I want this to walk till its directly under or over mouse and then laydown or jump only when over or under mouse..
(say its a 20 pixel wide object and 10 on each side will cover the whole thing and not just the exact center pixel, thats what the 10 + movie clip position is for, but Is there a way to tell it to goto and play whatever_frame when mouse is left of any graphic on the sitting dog section??? like the equivalent of onRollLeft or whatever.)
this is the code i have.. its the top statement that doesn't work the bottom 2 do..
I already created the shapes and placed them in the appropriate frames.. you should only need to mess with the actions on the instance "detail" (the dog face in frame 1 of scene 1 in layer "follower" ---- just the actionscript needed for that instance is needed in the reply.. you should not need to chage any of the layers, but if you do just tell me what you did and why.
my fla is to big to upload to this form so im placing it on my website here
Its not done yet but its gonna be a dog chasing a/the mouse. I want to have it where the if the mouse is left or right of the following movie clip it shows it walking toward the mouse... so something like
if mouse positions is less the the cursor + 10 (pixels) goto and play frame with dog walking left
and one for rightup down(I want this to walk till its directly under or over mouse and then laydown or jump only when over or under mouse.. (say its a 20 pixel wide object and 10 on each side will cover the whole thing and not just the exact center pixel, thats what the 10 + movie clip position is for, but Is there a way to tell it to goto and play whatever_frame when mouse is left of any graphic on the sitting dog section???like the equivalent of onRollLeft or whatever.)
Okay this is always something that's puzzled me. If I create a movieclip, place that clip on the stage, then inside that movieclip, create another movieclip, how does flash determine the coordinates of that second movieclip in relation to the stage. The reason I am asking this, is that I have a large movieclip which contains a number of other smaller movieclips. When a user clicks on one of the smaller movie clips, I need the larger movieclip to move so that the clicked movieclip is now centered on the stage.
I figure that this would be easier to know if I knew how to calculate the distance which the second, smaller movieclip is from the center of the main stage in x and y coordinate values. Am I making any sense? If not I'll try to explain again.
Is it possible to export a 9-slice scaled object as a transparent PNG? At the moment File > Export > Export Image > Transparent PNG will not output any 9-slice objects. This is quite a hassle, since I can't seem to get these objects transparently into Photoshop or Illustrator (both CS4) - what's the use of working with 9-slice objects if you can't export them flattened even to other applications? I use them extensively, but looks like I will have to convert them all the separate movieclips without this cool functionality, since it is more a pain than anything else once you need to use these graphics outside Flash CS4.
Am I missing something? "Work seamlessly between Adobe apps" is starting to sound more than a marketing/sales pitch than an actual reality. I have tried export these images as EPS/AI to open in Illustrator CS4 - they don't come out correctly at all / gradients messed up / errors on open. So, no more 9-slice scaling objects if I want to export to tranparent PNG from the IDE?
i have a movieclip(content_mc) that contains 4 movieclips(img1, img2, img3, img4) of different widths within it. The content_mc has been scaled to the browser using _xscale and _yscale. so if i want to center img1 on the screen the math WITHOUT content_mc being scaled would look like this
but being the fact that it's scaled...it returns the original _width values of the nested movieclips. How do i get the values of the new, scaled widths?
I'm building an application where the user can upload a photo of their head, scale it and position it, and then pick a colour from the photo.The photo gets put into a movieclip called 'head'I'm stuck at the colour picker part and I just can't seem to work out the whole bitmapData thing. Here's my colour picker code -
ActionScript Code: private function beginColourPick():void { _bmd = new BitmapData(head.width, head.height);
[code]...
This code kind of works, but not correctly.
Problem #1: The colour picker only works in the bottom right quarter of the image because I moved the head mc so the registration point is bang in the middle. So the problem here is that I can't figure out how to move the bitmapData in line with the head mc.
Problem #2: If the user scales the head mc (even a tiny bit) the colour picker stops working altogether. Now I'm thinking I've got to use a transform matrix - but I read up on it and haven't got anywhere.
I have a video inside of another movieclip. When I go full screen, I scale up the outer movieclip to fit the screen. So that OuterMovieClip.width is equal to screenWidth etc. How do I maintain the aspect ratio on my video so it does not get distorted? Whats the proper math for that?
I was working on a frame by frame scene when all of a sudden (I don't exactly remember what I did) borders show up around each brush stroke I draw like the figure shown here:
I tried turning off highlights (Ctrl + H), but the borders keep re appearing. Basically, I just want to revert back to the original selection mode as well as get rid of the borders after I draw my brushes like this figure shown below:
How do I turn off highlights / object borders permanently as well as enable regular brush selection?
I'm well aware of the Eleos/Microsoft issues that came before IE 8. However this isn't my problem. My company's website is able to display the swf file fine in FF but in IE, as soon as somebody clicks on the swf file, it does its thing without having to double-click (as in the ActiveX issue previously discussed) but also has what looks like a pink border around it. I'm testing in IE and created the Flash component in Flash CS4 using AS 3.0.Like I said before, the SWF object is activated on the first click, and doesn't have to do with the previously mentioned ActiveX control issue.
I am kind of new to the whole flash sceen and am getting a little bit frustrated with the snapping (I am used to Photoshop Snapping). I have a bunch of objects the exact same size as the stage and I would like to snap them to the stage (I am making a slideshow-rotating image). I always find myself having to zoom in extreamly to make sure the edge of my image is lined up with the edge of the stage... is there a way to snap my images to the stage.
I am embedding swf object into my html document, but its showing border on top and left of swf object, how to remove it? Same result on all browsers. If I increase the dimensions of swf object then border start appearing on all sides. I don't want the border at all.
I'm not sure what is causing this but I have objects that are transparent on the stage till they are called (object.alpha==0). The background image is of a room with fairly bright light.But when the background changes to a dark room the transparent items in front of it have white outlines around them...making the file unusable.
I am trying to do a apply a tween for the width property on a MovieClip Object but every time it changes the width and the position too, and I don't want that. I want to change the width going to one side without changing the x and y of the object.
I tried both of thes and they gave the same result.
var c:Tween = new Tween(left, "scaleX", Strong.easeOut, 1, 1.5,20,true); var c:Tween = new Tween(left, "width", Strong.easeOut, 20, 200,20,true);
I think it is applying the transformation according to a center of the movie clip. but I don't know how it can be changed.
Im working on a small project and it involves a guy which you move with the arrow keys. The arrow keys add to his x, y velocities and his position is updated accordingly. How can i get this man to grab onto an object and spin around it (like when you grab pole and letting your momentum swing you around) . I can make him grab the object but I dont know how to modify his x,y speeds to simulate the arc.
I'm trying to make a little program. It works right now by drawing the top shape to the dark gray area, where it then copies itself and changes color. The new shape can be re-dragged as well. What I want to do now is add a dynamic border when I click on the new object, I want the box to adjust to an appropriate size. And on mouse release I want the selection border to disappear on the new shape. I want the selection border to be dashed much like you find in many of Adobe's programs, if at all possible. Attached is my .fla file
how you display a border around every MovieClip in Flash. I've done it once but I can't seem to find it at all. What happens is that a blue (I think) box is drawn for the bounding box of the movieclip, and it does this for every movieclip automatically, so I don't think it's creating a border manually for every movieclip you add.
In addition this box doesn't rotate with the movieclip, instead it is just a square that completely surrounds the movieclip. If the movieclip rotates, the square just gets bigger or smaller to match.