ActionScript 2.0 :: Changing Movie Clip Colour With AS?

Apr 16, 2008

I'm trying to get AS to change the colour of several MC's - but it's not working... I wondered if anyone could please tell me where I've gone wrong? I have 5 large MC squares - when hovered/rolled over they reveal text/colour within. That part works!

What I am trying to achieve is: When rolling over 1 of the squares (i.e. sq1) to tint the colour of the other 4 squares to grey - so that the one that is hovered over is full colour, but the other 4 are greyed out. On rollout of sq1, the other 4 grey squares return to their coloured state.

I worked through the Kirupa - Changing Colours with AS tutorial, and tried to apply that to my situation, but I still can't get it to work.

[Code]...

View 7 Replies


Similar Posts:


ActionScript 3.0 :: Changing Colour Of Button Movie Clip Child?

May 28, 2009

I have a few buttons which I need to change the state colors using AS. I am able to change the whole button color but not the state object (converted to a movie clip).

All the variables are dynamic and I have not been able to get to the child object.

var block_color = new Color("_root.c_Angola.c_1");
block_color.setRGB("0x234234");
OR
var block_color = new Color("c_1");
block_color.setRGB("0x234234");

How do I access the movie object which is in a button up state?

[URL]

View 5 Replies

ActionScript 3.0 :: Changing Colour Of A MC With A Colour Picker?

Aug 17, 2009

i have a background and i want to be able to change the colours of it using a colour picker... if the MC was to cover the whole stage... how could i then get a colour picker and make it so it would change to whatever colour i wanted from the colour picker?

View 5 Replies

ActionScript 2.0 :: Movie Clip Colour Transition ?

Jul 6, 2004

I have got one box to change colour but im trying to get all boxes to change into different tints and stuff like that. I have the variables set and they seem fine. What do I need to change on the actionscript to get all 3 boxes changing at once.

View 3 Replies

Duplicating & Changing Movie Clip Without Changing Original?

Aug 31, 2009

I want to create another button on the main menu of my flash site. I want to take one of the existing buttons (which are set as movie clips) and modify it to show a different menu name and page link. BUT when I go into my library and "duplicate" my movie clip, change the instance name, drag it to the stage and attempt to modify it, the original changes as well. I need to keep the original the same and create a new one with the same code, frames, etc but with different static text. I keep going in circles

View 1 Replies

ActionScript 3.0 :: Change The Colour / Tint Of A Movie Clip?

Feb 6, 2009

how you can change the colour / tint of a movie clip via code, and essentially via a RGB value specified in an external xml file.

Here is the xml file I'm working with right now...

PHP Code:

<Countdown year="2009" month="2" day="14" bgdcolour="0xFFFFFF" lcdcolour="0xFFFFFF" labelscolour = "0x000000" textcolour = "0x000000">
</Countdown>

[Code].....

The bits highlighted in red bold above is the section where I've got stuck.. I have tried code: var bgdcolour:uint = Countdown.@bgdcolour; , but no luck and all I get is '16777215' in the output panel..

View 4 Replies

ActionScript 2.0 :: Control The Background Colour Of A Movie Clip And The Stage?

Apr 27, 2005

how do you control the backround colour of a movie clip and the stage? i have thought about placing a mc within the mc as a backround_mc, then change the tint attribute from my main timeline, is this on the right track?

i have a movie where a user loads images into an image viewer (mc) i have craeted. If a user clicks on gallery 1, the loader appears, and load the jpg and then tells the viewer to show onceloaded. But, if a user clicks on gallery 1, then clicks on gallery 2, the movie finishes loading picture 1, before loading picture 2, is there any waqy i can force the loader to stop loading one,a dn load two immediately.

I have careted a class, now, how do i assign an mc to be an object of that class, from the main timeline or the onclipevent load event

View 3 Replies

ActionScript 3.0 :: Change Colour Of A Movie Clip / Stage Using Local Time?

Aug 5, 2009

I'm new to actionscript 3 but I do have a little actionscript 2, but, what I want to do is change the colour of a movie clip or the stage using local time. From what I could gather you can't change the stage colour but you can change the colour of a movie clip.[code]...

View 3 Replies

ActionScript 3.0 :: Changing The Hue Of A Movie Clip?

Mar 25, 2012

I'm working on a scrolling game for my multimedia class, and I want to be able to have the player choose the colour of their character. Rather than having three separate classes (which would result in having three copies of all the code), i wanted to know if I could set a hue value instead. This is what I have so far (for one of the three buttons) :

Frame 1:

Code:
var rPlayerColour:Number = 1;
addChild(blueBut);
blueBut.x = 10;
blueBut.y = 385;

[code]....

View 3 Replies

ActionScript 2.0 :: Changing The Colour Of A MC?

Nov 21, 2002

I am trying to automatically change the colour of an MC when it comes into play and am having a few problem. I used the code I found in the Flash AS Help, but it's not working.

Here's what I used:

myColor = new Color(rollover);
myColor = setRGB(0x993366);

Rollover is the instance of the MC I want to target.

View 14 Replies

Copy A Movie Clip And Changing Properties?

Apr 17, 2009

I created a movie clip which loops some text, i would like to populate the stage with instances of it but also with some in a different colour. When I copy frames from my clip and paste them into a new symbol(movie clip) the colour of the other instances changes as well.

View 1 Replies

AS3 :: Changing Stage Variables From Within A Movie Clip

Feb 2, 2012

I want to change variables on the main stage's code from within a movie clip.

Say for example, I want to change a variable called 'chair'

In AS2, this is how I would do it:

(on the main stage)

Code:
chair = 2;
(in the movie clip)

[Code].....

But all I get is a 1119 error saying 'Access of possibly undefined property chair through a reference with static type flash.displayisplayObject.'

View 3 Replies

Changing Movie Clip's Registration Point?

Jun 9, 2009

I've received an .fla file with a design and am trying to play with it using ActionScript. I've got a symbol of a star on stage (movie clip) that I want to animate with AS. The movie clip's registration point is set to bottom right corner.
 
How can I change the registration point in Flash?

View 2 Replies

ActionScript 2.0 :: Changing Alpha From A Different Movie Clip?

Apr 6, 2010

The thing should work like this: theres a movie clip in frame 10 of the timeline with two buttons inside, by clicking one of them the movie should jump to frame 15 and take the alpha of two Mc there (they are inside a different movie clip) to 0. This is what ie been trying (code on the button, btw):

on (release) {
McScene2.lettuce._alpha = 0;
McScene2.pumpkin._alpha = 0;

[code].....

View 9 Replies

ActionScript 3.0 :: Changing The Colour Of An Image?

Dec 10, 2008

I have a client that has a series of products that come indifferent colours and different textures. What I need to do is havepicture of the product. When the user runs a mouse over the colourpalette the product changes it's colour to represent the chose madeby the customer fro the various choose in a colour palette. FordCanada does this when I pick the colour of my car. I can run overred and the car will change colour to red.

View 3 Replies

ActionScript 3.0 :: Changing The Colour Of MovieClip?

Feb 9, 2010

Basically, I want to change the colour of a component in my fla file that is called 'EDL Arrow' using Actionscript
 
'EDL Arrow' is a Movieclip and is part of another movileclip called 'EDLClipDisplay' - which exports to my actionscript file: 'Export: CIS.FLVPlayer.EDLClipDisplay'
 
How can I change the colour of the component 'EDL Arrow' from the actionscript file 'EDLClipDisplay'
 
I understand how to do colorTransforms but I just don't understand how to connect this component 'EDL Arrow' with my Actionscript file.

View 1 Replies

Professional :: Colour Changing Upon Export?

Jul 27, 2010

I'm working on a game at the moment, and I'm running into a problem. I was testing the vector files that I export of the art I made, and upon re-importation to flash the colours have changed significantly. Then, when the game is running in a browser, it looks different again. It even looks different between different browsers.

View 2 Replies

ActionScript 3.0 :: Changing Text Colour Please?

Jul 15, 2011

I have a set of textfields created in a for loop and I want individual textfield text to change colour on mouse roll-over. I can't get it to work - it throws a 1009 null object reference error:

Code:
var textField = new TextField();
textField.x = 150;

[code]....

View 2 Replies

ActionScript 2.0 :: Changing Colour Of Text?

Sep 7, 2011

should be simple anyway . I'm using flash CS5 but have continued using AS2 because that is what I know how to use. Im trying to change the colour of a Dynamic text field in which the string is constantly changing. I am trying to use the code:

Code:
_root.textField1.textColor = 0xFF0000;to get change it from white to red, but it does not work. I am thinking it is maybe because in CS5 you have to embed fonts (I dont know how to do this!). If this is the case is there an easy way to embed a whole font with all colours etc?

View 7 Replies

ActionScript 2.0 :: Changing Colour Of Movieclip?

Apr 27, 2006

I have this piece of actionscript working

Code:

var my_color = new Color("mymc");
my_color.setRGB(0xFF0000);

This works when I call the actionscript say from a button on the same timeline as the movieclip. What I can't get my head round is how I change the colour of an object on a different timeline, say if the path to the movieclip was _root.mc1.mc2.mymc

View 1 Replies

ActionScript 3.0 :: Changing Outline Color Of A Movie Clip?

Oct 6, 2008

I have a movie clip representing the state of Missouri. I'm changing its fill color based on data from an xml file. I'd like its outline color to be black. I've tried applying a glow filter, but it doesn't seem to work.

View 12 Replies

ActionScript 2.0 :: Changing Navigation Options With Movie Clip?

Jan 15, 2010

I am trying to create a site where the menu section will expand with sub-sections when certain buttons are clicked. I have created a main page with navigation, and a movie clip which holds the content for each page. The navigation from buttons on the main page works fine and leads to correct sections [labelled frames] within the MC. I have placed an additional button on the movie clip, it is revealed when one of the main buttons is clicked. However when this button on the MC is clicked, nothing happens.

I want to be able to move some buttons down and slot additional ones in between the existing buttons so that sub-sections are only revealed when looking at the relevant main section. I have tried to do this using the movie clip, however buttons below are not blocked and those above do not work.Here is the code I have used for the buttons - I have tried putting the sub-button code on both the scene and the MC - neither has worked.

ActionScript Code:
btn_home.onRelease = function () {
content_mc.gotoAndStop ("home");

[code].....

View 1 Replies

ActionScript 3.0 :: Changing Frames Triggered By A Movie Clip?

Mar 14, 2011

I want to go to a specific frame after a movie clip finishes, how do I do this?

View 1 Replies

Changing Alpha Of Movie Clip On Button Rollover

May 15, 2009

how to increase the alpha of a movie clip when you rollover a button.

View 1 Replies

ActionScript 2.0 :: Changing A Movie Clip's Local Variables?

Mar 4, 2009

I'm working on a particle system, where each single particle is represented by a movie clip and has it's own behaviors, defined in the movie clip's code in a separate layer from the image. The particle creates local variables, such as it's gravity and color, in the first frame and then uses them to guide it's actions throughout it's lifetime (it fizzles out and dies, eventually).Frame 1 of particle_mc:

Code:
var gravity:Number = 0;
var color:Number = 2;

[code]....

View 2 Replies

ActionScript 2.0 :: Changing Color Of Movie Clip With Combo Box?

Mar 24, 2009

I have a combo box called "jcolor1". I have a Movie Clip called "main". In my combobox I have set all of the color names in the labels section, and all of their hex values in the values section. I am trying to be able to change the color of the movie clip using actionsctipt.My actionscript I have (attached to the combobox)

on (change) {
myColor = new Color(main);
myColor.setRGB(jcolor1);
}

Its not working, I think the link between the Movie Clip and the combobox is not right, maybe I am not declaring the variable correctly.I want the combo box to reference the hex value I put into the data section in the component inspector and change "main" to that color.

View 2 Replies

ActionScript 2.0 :: Changing Movie Clip Symbol Width?

Aug 13, 2010

I searched the forums, but couldn't really find anything that matched my specific needs. I have a movie clip symbol that is your character, I also have a movie clip symbol that is named fuel and it represents the fuel you have left. I tried this in your character:

if (Key.isDown(Key.UP)) {
yspeed -= ypower;
fuel._width -= 50;
}

as a little bit of code. fuel._width -= 50; is what I'm really interested in. yspeed-= ypower; is just my movement, which works. So why doesn't my fuel width change?

View 6 Replies

ActionScript 3.0 :: Flash Changing Movie Clip Text?

Oct 24, 2010

Hi, I'm trying to change the text within a movie clip and I can't work it out. My plan is to load the navigation from variables that will be passed from a php file.

This link is to a zip file containing the fla file, [URL]

View 5 Replies

ActionScript 2.0 :: Changing Cursor Color When Over Another Movie Clip?

Nov 16, 2002

this time, I have a crosshairs custom-cursor (instance name 'crosshairs') that is black, and I want it to turn red whenever it is moved over a target that the user can 'shoot' at.asically, I am figuring that I simply need to perform a hitTest on the 'target' instance and, if it is true, use setRGB to turn the 'crosshairs' instance red. However, as of right now, the crosshairs is always black, whether it is over the target or noP.S. Oh yeah, and is there any way to make the color change / onMouseDown shooting action occur only when the CENTER of the crosshairs is over the target? Y'know, for realism. Well, anyways, cheerio...

View 11 Replies

ActionScript 3.0 :: Changing Colour Of Checkbox Label?

Jan 22, 2010

I'm writing a section of code which displays a series of checkboxes on the screen, but as they are placed on a dark background the default label text colour of black is no use, as they can't been seen. When I initialise them I use the line:
 
checkboxArray[i].setStyle("textColor", 0xFFFFFF); to set the text colour to white, but this only seems to work when the checkboxes are disabled (checkboxArray[i].enabled = false) and reverts to black again once they are enabled. I have tried including the setStyle line of code again after they have been enabled, but this doesn't make any difference.

View 2 Replies







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