ActionScript 2.0 :: How To Resize And Reposition MC

Nov 26, 2011

I'm trying to resize and reposition 'geschenke' which is a movie clip ... when you rollover the buttons a number will come out but since I resized the mc the positioning is off. How can I rewrite/use this code no matter what size the mc ends up being the positioning will scale with the stage.

this.createEmptyMovieClip("numbers", getNextHighestDepth());
for (i in geschenke){
zahl = Number(substring(geschenke[i]._name, 7, 8));
nummer = numbers.attachMovie("numbering", "numbering" + zahl, zahl);
nummer.stop();
[Code] .....

View 4 Replies


Similar Posts:


ActionScript 2.0 :: Resize And Reposition Dynamic Image?

Dec 4, 2006

I'm currently building an application that allows users to "import" uploaded images into the FUI and move them around to place them where they want. I have three seperate sections where they can do this and each section has a different maxWidth and maxHeight... What I'm trying to accomplich is to be able dynamically bring the image in resize it so that it fits within the _root.maxWidth and _root.maxHeight, while constraining the proportions, THEN I need it to be be placed (if needed) within the boundry of the section they are importing the image to...

I'm grabbing the image via the tree component and continuing from there... here is my code.

Code:
myTreeDataProvider = new XML();
myTreeDataProvider.ignoreWhite = true;
myTreeDataProvider.load("tree_source.xml");
myTreeDataProvider.onLoad = function() {

[Code]...

View 7 Replies

ActionScript 3.0 :: Reposition Bug On Mac?

Mar 8, 2009

i have made a site in flash cs3, with various things repositioning on screen resize, and everything works wonderfully, until i have checked it on a mac, on which everything's offsetted to the left. i thought that flash acted the same way on any platform (on all browsers in windows it does look great), but.just for some reference, this is the resize function (sorry for the length, i dont have a clue what's valuable and what aint):

Code:
function resizeHandler(Event):void {
if (stage.stageHeight>=400) {

[code]....

View 3 Replies

ActionScript 2.0 :: Way To Reposition Mouse

Feb 14, 2005

Is there a way i can reposition the mouse?

Iam working on an interface that requires the mouse pointer to begin from a certain area of interface.

View 4 Replies

ActionScript 2.0 :: Reposition The Blinker In A Text Box?

Apr 20, 2006

Is it possible to reposition the blinker in a text box?

I have a text box and the user can press a key to add a specific string and I've already done that. The problem is the blinker ends up between whatever the user typed and the new string, so they have to move the blinker to the end before resuming typing which is, needless to say, very annoying.

I was wondering if there was any sort of actionscript that can check and/or modify the position of the blinker.

Something like:

Code:
on (keyPress "*") {
//Move blinker to the end of the textbox here
}

View 4 Replies

Professional :: Reposition Element And Transparent Background?

Jan 29, 2010

I am trying to reposition a flash element.Go to [url].....I would like the badge and the cup in the center to be centered in the blue flash background.I would like the blue flash background to be transparent, so the web page can showup around the badge.How can I do this? I have attached the .fla and .swf.
 
EDIT-I was able to reposiiton the element, not sure why what I did earleir did not work. Still need to know how to have a transparent background on the flash.

Attachments:
badge-flash.swf (36.3 K)

View 1 Replies

ActionScript 3.0 :: Reposition Object Depending On How Many Left

Oct 24, 2011

I have a game: The object circled is the amount of shots you have left. But it removes the last object in the array, so the last bullet, its hard to explain, I have 20 bullets, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20. The array is removing the 1 first. Well what I am saying is number 1 is actually number 20, so the array is doing nothing wrong, I did. But I am not sure how to reverse the order.

So [ its removing this one-> o o o o o o o o o o o o o o o o o o o]
But [ --------------------------------- o o o o o o o o o o o o o o o o o o o <- I want it to remove this one]

The reason being is because the user cannot see how many they have left, so think angry birds, the amount of birds is displayed according to the amount there allowed, its to the left of the slingshot, like mine, every time the bird is shot, the rest of the birds shimmey towards the slingshot untill there is none left --- This is what I want, but have managed to confuse myself aswell as you most likely.

Here is my code, to generate and take awau my bullets/birds
public function createShotIcons() {
shotIcons = new Array();
for(var i:uint=0;i<20;i++) {
var newShot:ShotIcon = new ShotIcon();
newShot.x = 200-i*15;
newShot.y = 300;
addChild(newShot);
shotIcons.push(newShot);
}} public function removeShotIcon() {
removeChild(shotIcons.pop());
}

View 2 Replies

ActionScript 3.0 :: Reposition A Textfield From An Imported Class?

Nov 29, 2009

My project imports a custom class with a function called at runtime that creates a textField.

I want to be able to change the x and y coordinates of this textField [tf.x and tf.y in the class] from within the parent movie (not the class itself) but am having trouble.[code]...

View 5 Replies

ActionScript 2.0 :: Drag And Reposition MC's Over Multiple Pages?

Sep 13, 2011

This is hard to explain, so bear with me... I'm creating "pages" of draggable buttons so that I can reorder them according to their revised positions. Everything works great but I'm stumped as to how to drag the buttons forward or backward a page based on the current active page. If you look at the file you'll see exactly what I mean. I have a portion of the code commented out because that's the area I'm stuck on.

All the MC's are created on the initial load, with each additional page appearing "off the screen" by an adding 1000 pixels per page (in the X direction). Then I just reposition all the MC's as the pages are scrolled through.

What I really want to do is drag a button to the edge of the screen and have all the MC's move that represent the appropriate page. I think I need some sort of timer there or it just flies to the last page.

FYI, if you change the variable "TotalVBs" it will modify the number of displayed buttons. If you change the variable "myButtonScale" it will modify the scale of the buttons. Increasing either or both of these will add more pages to the program. [code]...

View 0 Replies

IDE :: Reposition Symbols On The Stage W/out Creating Motion?

Feb 9, 2010

I am using CS4. I have my Flash all setup and running perfect now w/ motion tweens etc.But I am trying to reposition some of my symbols on the stage (to get them into better alignment with other symbols), and every time I do this the move is recorded, and when I play back it shows the motion of my position change on my tween.Is there a way to simply move my symbols w/out losing their current tween, but not creating a new motion effect?

View 1 Replies

Professional :: Flash Zoom With Mouse Image Reposition?

Jul 24, 2011

Im currently designing a map with a drag and drop action as well as a zoom in and out with the mouse wheel, my problem is that when i drag and drop my image and then go to zoom in or out the image will automatically reposition itself back to the center, im wanting to be able to drag the image which is converted to a MC anywhere in my masked box then zoom in and out on that area that is shown is the masked box,

View 6 Replies

Flex :: Reposition An Icon Inside A Button On Any X,y Cordinates?

May 20, 2010

how to reposition an icon inside a button on any x,y cordinates . i know how to use labelplacement etc but still i dont get the full control over them. i m just wondering if there is a way to directly access and control the x,y position of an icon in a flex button

View 1 Replies

Actionscript 3 :: Remove A Movieclip Then Reposition Rest With Flash?

Aug 25, 2011

i would like to remove one or more object at runtime.

After each removed movieclip rest movieclips should be reposition as below. (Removed moviclip is 4 at representative figure)

Movieclips can be more.

View 6 Replies

ActionScript 2.0 :: Get A Movieclip To Reposition Itself Prior To Loading An Image?

Jul 12, 2007

using the following code i am trying to get a movieclip to reposition itself prior to loading an image. Then once the new image is loaded - the other movieclip will reposition itself. Currently, the functions are cancelling each other out - b/c the one function is within an onEnterFrame - take a look:

Code:
holderHitMC.onRelease = function() {
holderMask.newY = -854;
if (holderMask._y == -854) {

[Code]...

As you can see - i have a button with an onRelease command telling the movieclip to reposition - then onEnterFrame once the file is fully loaded the movieclip should return. The problem with this is that it does not allow the movieclip to move for the onRelease b/c the onEnterFrame is saying to go to the other position. If i add the delete this.onEnterFrame the movieclip - on future loads will reposition for the onRelease fuction but will not return.

View 6 Replies

ActionScript 3.0 :: Reposition All Of Movieclips When The OnResize Event Gets Triggered

May 4, 2010

There seems to be just one problem I cant get around. Its a full screen flash site so when the browser gets resized, it looks all weird until you refresh the browser. I think it would be too hard to make a function to reposition all of my movieclips when the onResize event gets triggered so I figured it may just be easier to restart the flash movie from the start when it gets triggered, how could I refresh the movie, or possibly even refresh the browser? here is the site so you can see what I am talkin about [URL]

View 4 Replies

ActionScript 3.0 :: Cancelling Functions - Control Bar Doesn't Reposition When In Full Screen

Aug 28, 2009

I'm working on a video player with full screen capabilities. I have the control bar set to tween in and out of the video screen with a mouse event. I'm also trying to position the control bar at the bottom of the screen when it's in full screen mode. My problem is that the control bar doesn't reposition when in full screen because of the tween functions. I'm thinking that whatever solution comes up that I might go in the if statement of the full screen code.

[Code]...

View 8 Replies

Professional :: Reposition The Movie Clip Dynamically When The Movie Is Launched?

Jan 24, 2010

I have an ActionScript 2.0 project with a very simple timeline Alpha Tween ("Classic tween" in CS4) of a movie clip. I need to reposition the movie clip dynamically when the movie is launched, before the Tween is executed (as in "x_mc._x = 100;").

I found out that after changing the clip position the Alpha Tween as well as the Alpha final value are totally ingored. The clip is shown in the updated position but remains throughout in the Alpha setting of the first keyframe (even when it reaches the last keyframe which has a different Alpha setting). I verified that the Tween itself is executed by placing Trace statements at both keyframes. If I remove the repositioning statement, the Alpha Tween works fine (but of course in the original position which is wrong)

View 1 Replies

ActionScript 3.0 :: Scale Or Resize The Image By Dragging And Resize Option?

Sep 19, 2011

I am working on image and i like to scale or resize the image by dragging and resize option.same working as "free transform tool" in flash (design part); i need same functionality in application.

View 7 Replies

ActionScript 3.0 :: Browser Resize Doesn't Trigger Resize Event?

Jul 7, 2011

I'm having a bit of a problem here. As per the title, my flash swf file works fine when tested from the IDE, but when I publish it and open it through the browser, the stage doesn't seem to resize along with the window.I post below a bare-bones example. The "back" movie clip should resize, only it remains at the starting dimensions

Code:
import flash.events.Event;
import flash.display.MovieClip;

[code].....

View 9 Replies

Flex :: Flash - Resize Children When Parent Is Resize?

Jul 29, 2009

I have Buttons which I have rotated vertically within a Canvas, that is working fine. The problem occurs, when the user resizes the window to a small size a vertical scroll bar appears, I would rather have each button squashed upto a smaller size.

<mx:Canvas xmlns:mx="http://www.adobe.com/2006/mxml" width="40" maxWidth="40" xmlns:myComponents="myComponents.*"
horizontalScrollPolicy="off"

[code].....

View 2 Replies

Flex :: Resize Event And Resize Effect Of A VBox?

Dec 8, 2010

I'm having a little issue with the resize event and resize effect of a VBox.

I have something like this:

<mx:VBox id="container"
backgroundColor="0xFFFFFF"
backgroundAlpha=".9"
paddingTop="15"
paddingLeft="15"

[Code]...

View 3 Replies

ActionScript 2.0 :: If Resize The Window Before The Swf Is Loaded - It Misaligns Until Resize

Jan 4, 2009

I have a main movie here that loads in an external swf through a container mc. everything is aligned and positioned to where it should be, and they are also set to that value onresize. the problem is, when my swf is loaded in, it works fine and is in the right position, same when you resize it. BUT, if you resize the window before the swf is loaded, it misaligns, until you resize!!

View 2 Replies

Flex :: Resize Datagrid On Browser Resize?

Sep 28, 2010

I have a datagrid that occupies 100% of browser screen. I want the grid to automatically resize when the browser is resized to small or full screen.

View 1 Replies

ActionScript 3.0 :: Can't Get Stage Resize Listener To Resize Movieclips In "main" Swf

Sep 9, 2009

I've got a large bitmap (1920 x1306) that my client wants as a bg image, scaled to the swf size on load (930 x 575); but that can "grow" up to its original size if/when a user expands the browser window. All the rest of clips in the display list are to remain in place (except for a copyright clip, which they want to always be 14 pix above the bottom of the browser frame. I've tried loading the bitmap dynamically at full size and then using scaleX,scaleY to set it's initial smaller (930x575) size, and I've tried just setting the height/width of the dynamically loaded image using the math of scaleX,ScaleY just in case the scaleX "transformed" the bitmap so that it couldn't return to its original size.  Both make the bitmap the right size. But the resize function below did  nothing to it, (or the copyright.y.) THEN I tried just putting the bitmap into the display list (both sizing methods work here, too). But even as an original member of the compiled display list, the resize event is still not reaching the target. Everything I've seen on the web says this should work - but...no luck.
 
Here's the AS3 code in the 1st frame of my swf:
 
import flash.display.Stage;
import flash.display.StageAlign;
import flash.display.StageScaleMode;

[Code]......

View 1 Replies

Flex :: Flex 3 Resize The Label And Text When Resize The Window?

May 11, 2010

i am creating flex 3 component when i re size the window i need to re size the labels and text.how to do this?

View 1 Replies

Resize A Document For Web Use?

May 5, 2009

I looked online on how to reduce file size od an .fla file for use on the web but not very clear. I have an .FLA file that is 800X600 px.  when I publish it, I reduce file size, audio to mono etc, and I am getting 1.8mb file, way to large for web use. I tried an swf and flv file but same results. I need to reduce the entire document. I read to use the onion skin the highlight everything then resize but I have over 5,000 frames in my movie. Can someone explain in detail, how to highlight all of the frames in the movie, and then reduce the file to say 400 X 300 px? I am able to drag the onion skin but only to the edge of the viewable document then I must scroll over and repeat the process. there must be an easier way to highlight all frames in the movie then resize the whole thing.

View 5 Replies

Resize Swf On Load?

Apr 13, 2010

I have swf, I want to resize it to fit browser window.So, that is width is always 100%, and height is proportional to width.[code]...

But, how can I now apply it to my swf file?

Like, i set its "id" to my "flash" (<embed src="final.swf" id = "flashme" )to pass it to the function, but I do not know how to alter params

View 2 Replies

ActionScript 3.0 :: Best Way To Resize SWF

Sep 3, 2009

I have a SWF with a video inside, later I loaded it into my website.I resized it with something like mc_loaded.width=stage.stageWidth and the same for height so i can get a fullscreen video.The problem is that this method takes a lot of the cpu performance and such.At least it becomes a bit laggy.Any idea on better ways to resize this SWF?

View 7 Replies

Flash 10 :: Way To Resize Swf

Oct 26, 2010

Can i resize swf to small size and make the data inside it take the same size ?

if i changed dimension "width and height" the data didn't change to the new size

View 0 Replies

ActionScript 2.0 :: Resize Flv With It?

Apr 19, 2011

I have an flv using the standard FLVPlayback component within my website. I want to be able to click a button to resize this player. Is this possible?

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved