ActionScript 2.0 :: Set The Opacity Of An Object Similar To The .setRGB Thing?
Mar 14, 2003I was wondering if there is a way to set the opacity of an object similar to the .setRGB thing..
View 14 RepliesI was wondering if there is a way to set the opacity of an object similar to the .setRGB thing..
View 14 RepliesI was wondering if there is a way to set the opacity of an object similar to the .setRGB thing..
View 14 RepliesJust taking Koolmoves for a test drive and ran into a snag, I want to change the opacity of some shapes/objects that Ive created but I cant seem to find an option to adjust the opacity anywhere.
View 1 RepliesI have a plan of a park and want to make some different zone (red, green, blue, etc.) I know how to make them but dont know how to put them to 50% of opacity.
View 3 RepliesI want to have an object start off with an alpha of 0 but then opacity in to 100% later on the timeline BUT I have to use Actionscript.
View 6 RepliesI'm trying to get it so whenever the object is clicked it reduces in opacity by 10% each time, and if it gets to 10% and it's clicked again it stays at 10% instead of going to 0. I got it to keep going down in opacity fine I just don't know the code to keep it from going lower. this is what I have so far
function fadeOut(e:MouseEvent):void {
instrument.alpha -= .1;
} if (instrument.alpha<.1) {
instrument.alpha = .1
} else {
instrument.alpha -= .1;
}
I'm trying to get it so whenever the object is clicked it reduces in opacity by 10% each time, and if it gets to 10% and it's clicked again it stays at 10% instead of going to 0 I got it to keep going down in opacity fine I just don't know the code to keep it from going lower. this is what I have so far
[Code]...
Im looking to rotate an object 360' around its registration pointer thing. The only problem is i dont know where to strat.
View 2 RepliesI'm kinda new to Flex. I have trying to send Hash from Ruby on Rails application to Flex using RubyAMF.Results look like this:
result (mx.utils.ObjectProxy (@22b207d9))
|
|-->errors (object (@16c64dd1))
[code]......
I would like to fade in and out and object with the colorTransform-method. When I apply the colorTransform to my object it does fade out the thing but not fade in. At first I set the alpha of the bitmapData to 0 (for the fade in-effect). After applying the colorTransform it does nothing. No fade in. Otherwise when I set the alpha of the bitmapData to 100 and let it fade out it works.
[Code]....
I've been searching everywhere and I can't find a solution. I use swfobject and flashvars and whenever I use flashvars the dynamic text color won't change. If I put my variable inside the fla timeline, the text color changesHere is my setRGB code:
Code:
var c:Color = new Color(button4.txt);
c.setRGB(0xffffff);
[code]....
i have a for loop to attach a movieclip X times, and an Array with several color codes to apply in the loop.everything works fine with the setRGB. the movies have an internal background movieclip that gets the color i want to apply.
the thing is the movieclip's loose the animation i created to that internal movie (the one who get's the color). they do not respond to gotoAndPlay, or gotoAndStop...i disabled the setRGB lines, and the movie's play fine now. does setRGB transform my movieclips to a bitmap or something? disabling every animation inside?
Is it possible to use setRGB inside a btn?I have a buttom that has a textfield and a background.I want to change only the color of the textfield!here is the code i`m using:
Code:
function AbtnPress() {
for (var i=1; i<8; i++) {
var btn = _root.A["btnA0"+i];
[code]....
I am using the most up to date version of SWFobject.When i use a simple rollOver and out state on my mc's .. I have been using setRGB to change the colour depicting the state.However since installing SWFobject - This setRGB property refuses to work.
Code:
t.onRollOver = function()
{
col = new Color(this);[code]....
is how im doing it in flash - simple - but why is SWFO disabling it? .. is it something to do with the parameters?
I am trying to set up a dynamic flash movie so i can set the color of text with a dropshadow applied using setRGB.
Here is the code i am using to set the text color (simple setRGB call):
var my_color:Color = new Color(this.tagLine_txt);
my_color.setRGB(tagLineColor);
Now here is the problem, setRGB automatically makes my dropshadow color the same as the fill color. The only solution i have found is to stack two identical text boxes on top of one another and then setting the dropshadow on the text behind to black to make it look proper.
I have tried using filter to set the dropshadow color as well with no luck:
// Makes the filter available to use in the Movie.
import flash.filters.DropShadowFilter;
// Creates a variable with info about the Filter settings
[Code]....
Code:
onClipEvent(load){
_global.tinta=0xFF0000;
tintb=0xFF0000;
box = new Color("_root.boxy"); //This instance is named "boxy"
} onClipEvent(enterFrame) {
box.setRGB(tintb); //Turns it red
}
This works and makes the box red. However, if I change it so it's "box.setRGB(_global.tinta)", it turns it black. Even setting "tintb=_global.tinta" and using the "box.setRGB(tintb)" doesn't work any more. Why doesn't setRGB() like _global variables?
See, I have a Symbol- in's an animation of a "Cycler" (bicycle driver) seen from above and I want to use a function to duplicate it with actionscript as needed.
So far so good, has been done before.
But in this Symbol I have "sub-Symbols" on the timeline (within the Cycler's animation)... how would I do it to use a setRGB on one of them for each duplicated driver individually? The way I tried it now (see attached files) makes the animation stop for the sub-Symbols I use setRGB on (in my example the shirt of the left Cycler and the helmet of the right Cycler).
Why does the animation stop? I had a similar problem before and I solved it by coloring a fixed simple square on a layer and the animation for the motion was really a mask, ontop of it... but why doesn't it work like this?
Feel free to test is yourself- I am open to suggestions. The Cyclers are called "Biker_1" and "Biker_2" and the sub-Symbols are called "Helm", "Koerper" and "Rumpf", for the Helmet, the Body and the "Rump" of the Cycler.
What is the equivalent alpha code to setRGB?Ps Im trying to change this code so it contorls the alpha of a movie clip instance name circle the code is bellow:
Code:
onClipEvent(enterFrame){
_parent.alpha = (_parent.RedSlider.RedControlBar._y+122).toString(16);
if (length(_parent.alpha) == 1)
_parent.alpha = "0" + _parent.alpha;
[code]....
I need to convert an integer value to hex to use with the setRGB thingy. (I want a slide bar that controls the colour of a movie clip) I know that you can use parseInt to get an integer from a hex value but how do you do the opposite?
View 3 RepliesIve got a button with black text that text fades blue on(rollOver) & I also have this script attached to the button.
on(press) {
myColor = new Color(this.servicesTxt);
myColor.setRGB(0x990000);
[code]....
Although the .setRGB turns the button text back to black the button text doesnt fade to blue.How do I remove the .setRGB(0x990000); on (release)?
If I have a piece of a function that is telling Flash to[code]...
How do I tell Flash to call a MovieClip as opposed to setRGB for the background MovieClip?
not sure if this is technically "actionscript"but i didn't know wher eelse to post iti need to place an flv on top of a background image, and i want to set the flv to have an opacity of like 30%-
View 4 RepliesCan we change the layer's opacity in flash CS4? Such as change the photoshop's layer's opactiy.
View 3 Repliesis there such a thing as an opacity mask in flash? (like the one in illustrator--or something similar?)
View 5 Replieshow to animate the movieclip opacity using Tweensy engine.
View 1 RepliesI'm trying to figure out how to make a slide bar that would control opacity. If I were to take to pictures on top of each other, the slide bar would control the opasity of the top image.
View 3 RepliesSuppose I have an image in the background with a white box over the image. What I am trying to do is get the box to oscillate it's _alpha property while diminishing to zero. Producing a 'twinkling' effect. I have the actionscript on the box_mc in an onClipEvent (enterFrame) function. Really there will be a lot of these boxes so the oscillation would have to be random.The code I have right now, which just lowers the opacity at a random rate - no oscillation is below:
onClipEvent (load) { h = Math.random();}
onClipEvent (enterFrame) { if (this._alpha>0) { this._alpha -= h;
}}
I have buttons inside/on window01/mc that are still active/clickable when the opacity is 0, I basically have a area on my website that if you click it opens the window corresponding to the button. how do I stop this? I only want the buttons to work when window01 is opacity 100. I'm not a pro at AS so please if you reply, walk me through it a bit or edit my code. [URL] just click in the blank black area below the nav bar and the window will appear. The normal way to get to this window is click products than the buttons.
Code: Select allimport gs.TweenLite;
btn06.addEventListener(MouseEvent.CLICK,f2);
function f2(e:Event){
[code]....
could someone point me in the right direction of how to pulse the opacity property. Math.sin on something and offset and scale the wave to run from 0-1 ?
View 2 RepliesI am trying to create a Photo Editor using Flash One of its features is to change the Opacity of the Image. Now my problem is how to change the Opacity of a bitmapData and save the image so that the resultant image has a changed Opacity.
View 2 Replies