Professional :: Why Does Setting A MovieClip's Alpha Prevent It From Moving In Another Keyframe

Mar 12, 2012

I have a MovieClip, named "thing", that's in one position and in another position on the next frame. I added an eventlistener to "thing" to advance frames. Very simple, everything works fine.I then add "thing.alpha = 0.5" in the button's event listener. Now when I publish the file, thing fades but doesn't move.

p.s. For reference, here's the entirety of my AS3 on the first frame:
  
import flash.events.MouseEvent; 
stop(); 
thing.addEventListener(MouseEvent.CLICK, doClick);

[code]....

View 6 Replies


Similar Posts:


ActionScript 3.0 :: Setting The Alpha Of MovieClip With Objects Changes The Alpha Separately For Each Object

Oct 23, 2010

[URL] i want the object to fade out but in the object there's a lot of overlapping pictures and each becomes half transparent. how to make the movieclip to change the alpha as it was without objects?

[Code]....

View 2 Replies

ActionScript 3.0 :: Button To Play Movieclip Before Moving To Next Keyframe?

Aug 13, 2009

I have a play button (instance name - play1)

When I click it I want it to play a short movie clip (called - introExpandMC) then for it to move on to frame 2 of my my main time line.[code]...

View 5 Replies

Professional :: Moving A Keyframe Within A Motion Tween Span?

Feb 7, 2010

I have created a motion tween to fade in a symbol on the stage. I have set a there is a diamond keyframe marker at the point where the alpha of the symbol goes to 100%. I want to be able to drag that marker to a later point on the motion tween span (not sure if I have my terminology right here) but I find that I cannot -- I have to delete the keyframe and recreate it at the point where I want it.

View 1 Replies

ActionScript 2.0 :: Setting A Movieclip To Alpha 0 %?

Jul 10, 2005

like my movie container in my _root, how do i set it`s alpha to 0? does this work: _root.contMovie.setAlpha(0); ? or is there any other possibility to set it`s alpha to 0?

the best thing for me would be if i could fade it to alpha via AS command, i can't control it direct because the movieclip is 2 levels above....:-)

View 6 Replies

ActionScript 3.0 :: Change MovieClip Color & Alpha Setting?

Nov 17, 2011

I have a MovieClip with white background and would like to change it's Background color and alpha settings at runtime. How can I?

View 1 Replies

ActionScript 2.0 :: Setting Movieclip Alpha From Text File?

Dec 16, 2009

I am currently trying to set a movieclips alpha property from an external text file. The movieclip is called Text_Main_Slide1

The text file:
banner_settings_468x60.txt
which contains:
&Alpha_Main_Slide1=0&

I have currently written:

loadVariables("banner_settings_468x60.txt", 0);
Text_Main_Slide1._alpha = Alpha_Main_Slide1;

which doesn't work.I can however set it manually: Text_Main_Slide1._alpha = 0;

But I need to be able to set the number from the text file.

View 6 Replies

ActionScript 3 :: Flash CS5 - Mask With Keyframe Prevent Bitmap Loading

Feb 12, 2012

I have a Flash app that loads a PNG as a bitmap and adds it to a MovieClip instance called test_mc on the stage. test_mc contains a placeholder clip that we hide after adding the bitmap. E.g
test_mc.addChild(bmp);
test_mc.placeholder.visible=0;
This works fine. I then move the MovieClip around the stage in the timeline with a lot of keyframes. This works fine.

I then add a layer, called layer_mask, above the layer with the movieclip on. I create a shape on layer_mask and set layer_mask to mask the movieclip's layer. This still works fine. Now I add a keyframe in layer_mask. This stops working. The bmp is no longer loaded into the movieclip, and the placeholder is no longer hidden. The bitmap is actually loaded in and displayed correctly until the keyframe in the mask is hit, at which point it reverts to displaying the placeholder without the loaded bitmap.

View 1 Replies

ActionScript 3.0 :: Mouse Events - Keyframe That Plays A Movie Clip By Fading From 0 Alpha To 1

Apr 29, 2010

I have a gallery made of 3 layers : actions, buttons, and images. Fore every image i have a keyframe that plays a movie clip by fading from 0 alpha to 1. I made a new keyframe that has no image so the page doesnt display the big photo from the start just the thumbs(which are the buttons). What i want to do is that the big images to be dispalyed only while i hold the mouse button, and on release to go back to the first frame state (no image).

View 3 Replies

ActionScript 1/2 :: Setting _height And _width Prevents Keyframe Movement?

Sep 3, 2009

I have a movie clip that jumps around over the course of my movie using standard keyframe animation. At every keyframe, it calls a function that moves a dynamic text box on top of it, autosizes the text box, then alters the movie clip's _width and _height to fit that of the text box.
 
The problem is, while the resizing code works fine and the text always fits, the act of altering the _width and _height seems to cancel out the keyframed positioning. The movie clip changes size, but it's forever locked to the position of the first keyframe.

[Code].....

View 1 Replies

ActionScript 2.0 :: Moving Array From Keyframe To Txt File And Shuffle

Nov 6, 2004

I have an array in a keyframe - but i want to have it in a textfile instead ( so that others can edit it for themselves. But i am having difficulty doing it. At the moment I have this on a button

[Code]...

What I'd like to know is how to change the above array so that it would work in a text file (which would be easier for others to edit you see). I think i could divide the letters by : and then use some code to break the array apart at ':'. But I am not really sure. Can anyone give me some pointers? Also - if u have time to shuffle the array so letters appear in different boxes each time?

View 1 Replies

ActionScript 2.0 :: Moving Array From Keyframe To Txt File And Shuffle?

Nov 6, 2004

I have an array in a keyframe - but i want to have it in a textfile instead ( so that others can edit it for themselves. But i am having difficulty doing it.At the moment I have this on a button

on(press){
letters = new Array ();
letters.push ("Y");
letters.push ("d");

[code]....

What I'd like to know is how to change the above array so that it would work in a text file (which would be easier for others to edit you see).I think i could divide the letters by : and then use some code to break the array apart at ':'.

View 1 Replies

Professional :: Moving Movieclip Up And Down

Aug 9, 2010

I have a movieclip that I want to move down and up.I use a new tween using the Elastic. easeOut property to move the movieclip down over a duration of 2 seconds.But right after it moves down I need to move it right back up so it looks like a uniform animation.I used setInterval(reverse,2000) and reverse contains yoyo();This almost works.Since Elastic slows down the movement of the movieclip at the very end, there seems to be a pause between the movieclip moving down and the movieclip moving up.It does not give the impression that it is 1 tween, which is what I was going for.I tried to set the duration to less than 2 seconds, but then Elastic property is not 'stretchy'.It is too fast and comes to a halt, not elastic, and then the reverse (when the movieclip goes back up) is much faster than when the movieclip goes down.Is it possible to move the movieclip down AND up by using just 1 "new tween" function?

View 2 Replies

Professional :: Moving Movieclip Up And Down?

Oct 25, 2006

I have a movieclip that I want to move down and up.  I use a new tween using the lastic.easeOut property to move the movieclip down over a duration of 2 seconds.  But right after it moves down I need to move it right back up so it looks like a uniform animation.  I used setInterval(reverse,2000) and reverse contains yoyo();This almost works.  Since Elastic slows down the movement of the movieclip at the very end, there seems to be a pause between the movieclip moving down and the movieclip moving up.  It does not give the impression that it is 1 tween, which is what I was going for.  I tried to set the duration to less than 2 seconds, but then Elastic property is not 'stretchy'.  It is too fast and comes to a halt,not elastic, and then the reverse (when the movieclip goes back up) is much faster than when the movieclip goes down.  Is it possible to move the movieclip down AND up by using just 1 "new tween" function?  I am out of ideas.

View 2 Replies

Professional :: Use The Color Effects And Blending Options Of MovieClip Square To Make Layer 1 Alpha

Aug 11, 2011

Inside movieClip container, there are colored buttons on layer1 and on layer2 there is movieClip square which covers the buttons. I want to use the color efffects and blending options of movieClip square to make layer 1 alpha. There are some blending options called alpha, difference, lighten and substract but Im not getting the right combinations. I want to make layer1 alpha only by using layer2.

View 1 Replies

Actionscript 3 :: Prevent A Rect From Moving From Its Position When Decreasing Width?

Apr 12, 2012

I seem to be having problems with rectangles moving from their assigned positions when all I want to do is decrease their width.A game I'm working on simulates an explosive with a fuse. The fuse decreases in size as a clock counts down to 0.I think the problem has to do with local coordinates vs. global coords, but I'm not sure how to rectify the problem. Here is some code:

//fuse
_fuse = new Sprite();
_fuse.graphics.beginFill(0x000000);[code]........

Nowhere in my code does the x position of the fuse change.Aside from this one issue, the rect functions exactly how I want it to.

View 1 Replies

ActionScript 3.0 :: Setting Alpha On A Loader?

Aug 11, 2011

set the alpha on a loader which is inside a class Portrait. I've got 27 pictures I load through a class. I can set the alpha for 23 pictures. But when I try to set the alpha for 27 pictures the alpha for the first 4 pictures cannot be set. I can set it only to 1. They've been loaded and when I trace the alpha value it states 0.5 for example but nothing is displayed. The strange thing is that this is only so for the first 4 pictures when there are more then 23 pictures to load. I've tried replacing the pictures but that doesn't make a difference.Here is the Portrait class:

Code:
package
{
import flash.display.*;

[code]....

When I change if(i==0) to if(i==6) that is, anything higher than 3 it works fine.

View 21 Replies

Alpha Setting When Paste In Place?

Dec 6, 2009

I am creating smiley faces and then copying them to a banner. I have two fla files open, one has the smiley in it and some layers of the smiley are made up of areas with a alpha setting of less then 100%.When I highlight all of the smiley and copy, then move to the other other open fla file that has a blue banner, and 'paste' the smiley pastes ok but all the areas that have an alpha setting of less than 100% have a blue shade to them from the banner. How do I prevent this and retain the colours I had?

View 1 Replies

ActionScript 2.0 :: [FMX2004] Setting The Alpha?

Jul 4, 2004

I am having trouble setting the alpha of a movie clip (this is a bitmap, if that matters). My code is as follows:

Code:
on (change) {
if (this.getSelectedItem().data == 3) {
set (this._parent.ahouston._alpha,100)}
if (this.getSelectedItem().data <> 3) {
set (this._parent.ahouston._alpha,0)}
}

I don't believe it is a problem with my combobox actionscript, as just putting:

Code:
set (this.ahouston._alpha,100)

in the only frame of the parent movie clip doesn't work either.

EDIT: Now it shows it with 0% alpha, but won't turn to 100%. I was wrong. It is a combobox problem.

View 7 Replies

ActionScript 3.0 :: Setting Alpha Value On Specific Color?

Nov 29, 2009

Suppose I have a Bitmap containing a color which is some arbitrary mix of RGB, how would I go about setting the alpha value of that particula color?

View 6 Replies

ActionScript 2.0 :: Setting Alpha Of Dynamic Masks

Oct 15, 2009

I am having problems with the _alpha property of dynamic masks. For some reason they don't seem to accept it. I have a holder mc that I use as a mask and the holder is full of dynamic mcs for which I would like to set apha properties. My code is:

[Code]...

View 6 Replies

ActionScript 3.0 :: Setting Alpha On Clip Already On Stage

Jan 7, 2011

If I have a clip already on the stage. how can I go about having code to set the alpha = 0 so that the clip is default invisible. If I set the alpha in the class constructor it gets reset to what its set on the stage. I tried to use the Event.ADDED event since that gets dispatched before rendering too (I think). I mean If I don't have any choice then I'll just set it to 0 manually . Just was hoping to have the capability to set it in code. So that I can still see the clips on the stage just to make it easy for moving them around if I needed to. Where I need to set the alpha so that it takes effect 'after' the default values get applied..

View 9 Replies

ActionScript 2.0 :: Change The Value Of The Alpha Setting Of An AttachedMovie?

Nov 2, 2005

is it possible to to change the value of the alpha setting of an attachedMovie

I have

Code:
function attachBk (thisBk, nextBk):Void {
if (thisBk == undefined) {
this.attachMovie(nextBk,"bkHolder1", this.getNextHighestDepth());

[Code]....

When I click a button I want bkHolder1 to fade out but so far I haven't had any success, I tried doing bkHolder1._alpha = 0 just to see if it would affect it's property but it didn't.

View 4 Replies

Flex :: Button Skin Disabled Alpha Setting Ignored?

Nov 14, 2011

I attempted to build a Flex 4 skin for a Spark button, typical practice. I adjusted the colors and other styles to my liking, including using dot selectors to specify alternate colors and such during different states. However, these are all ignored when the button is disabled. Regardless of what I do, in the disabled state, my button always has the wrong color and is alpha'd to 0.5 (even if I specifically state that alpha.disabled="1"). All the other skin states work as expected. This is my custom skin. If it were working correctly, it would appear to have no shadow or highlight, and would be a gradient grey color. Instead, it appears as a 50% alpha version of the up state (shiny green).

<?xml version="1.0" encoding="utf-8"?>
<s:SparkButtonSkin xmlns:fx="[URL]"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fb="[URL]"
minWidth="21" minHeight="21" alpha.disabled="1">
[Code] .....

This is the code used to create and then disable the button:
_action1Button = new Action1Button();
view.actionGroup.addElement(_action1Button);
_action1Button.enabled = false;

The error was that _action1Button is not the actual button, rather, it's the container of the button. Doh! Switching it to _action1Button.actionButton.enabled = false; fixed the issue.

View 1 Replies

ActionScript 2.0 :: Setting Default Alpha For Image During Loop

Sep 6, 2010

I have a script which dictates alpha on rollout and onroll but I want to set a default alpha setting for images which are loaded via xml. Here's a tidbit:

[Code]...

I've tried combinations of tn_group["tn"+i].tn_button.tn_pic._alpha = 85; and such but I'm still a big newbie

View 2 Replies

ActionScript 2.0 :: Setting Alpha/visibility Of Multiple Movieclips?

Apr 3, 2011

What I am trying to do I think is pretty simple.

Consider this code:

ActionScript Code:
var imageContainter:String;
var fileName:String;

[Code]....

This code appears to be working. I'm dynamically creating a bunch of movieclips that each contain an image. The also code stacks each clip on top of each other.

I'd like to be able to now set the alpha or visibility of all of those movieclips to 0 or false, except for the first one. I have other code that will set specific movieclips to display based on mouseEvents.

How do I refer to all of them? And should I be using arrays as well?

View 7 Replies

ActionScript 2.0 :: Alpha Setting - Object Goes To 0 Percent On MouseOver

Jun 7, 2005

I want to achieve the effect on [URL]. The effect on the left on the about page in which when the mouse moves over the alpha of the object goes to 0%. I have all the layers set up with masks and all but need the action script. I tried applying the following code to a mask which I converted to a movieclip.

on(rollover){
this._alpha--;
}
But this did not work for some reason.

View 2 Replies

ActionScript 2.0 :: Change Frame 20 Alpha Setting From Outside SWF File?

Feb 5, 2008

I have 20 frames on a timeline, and a mc in the frames. Frame 1 the mc is _alpha 0%, at frame 20 the _alpha is 100%. A tween between the frames fades up the mc alpha. How can I change the frame 20 _alpha setting from outside the swf file? Say I need the alpha to be 60% at frame 20 BUT I can't open up the FLA, can I adjust the Alpha setting (using Loadvars perhaps) without going back into the FLA? I won't have access to the FLA (when the file is online) and I want to be able to manipulate the frame 20 _alpha setting. I have tried doing this totally in actionscript and not using the timeline, but if I can't get that to work I will need to be able to adjust the alpha parameter without editing the FLA.

View 2 Replies

ActionScript 2.0 :: [CS3] Textfield - Setting Alpha In '.textColor' And '.backgroundColor'

Oct 26, 2008

Folx; Does the manual document the setting of transparency in TextField.textColor or TextField.backgroundColor, not just the _alpha of the TextField altogether? If so, I cant seem to find it. In addition to the RGB/hex values, the color palette in the Properties panel allows you to set transparency in %, yes, but can this also be achieved programmatically?

View 1 Replies

Actionscript 3 :: Setting Alpha On Parent Sprite Without Affecting Sprites Children

Mar 12, 2010

If I change some value for a parent sprite, the same value will affect all of its children. So if I set alpha or width on the parent, the child will automaticly get the same value.

View 4 Replies







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