Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Changing color of objects

Posted on 2002-05-01
1
172 Views
Last Modified: 2010-04-03
I have tried to figure out a couple of different examples that I have found on flashkit.com about changing colors of objects but can't seem to figure out what I'm doing wrong.  If you download the following fla

http://www.flashkit.com/movies/Utilities/Other/Color_Pi-Kumar_K-5422/index.shtml

as an example and when you take the "box" movie out of the scene and then place it back into the scene again from the library it looses its functionality.  If I could figure out why this is happening I could probably figure out how to make it change colors.  If you create an object and make it a particular color, will you be able to change it in actionscript or do you need to tell the objects color in actionscript from the beginning?  I hope I have made this understandable.  I have even checked the actions of the box movie before deleting it from the scene to test it and there are no actions.  Am I not looking in the right place?

0
Comment
Question by:Zantis
1 Comment
 
LVL 6

Accepted Solution

by:
rootdir earned 100 total points
ID: 6984353
Simple when you are taking the "box" movie out of the scene and then place it back into the scene. You are not giving "Mc" instance name to placed back "box" movie. If you give that, you can see it will change color again.

No you donot need to tell perticular color from bigning. You can assign color to movie at runtime like this

    MCColor = new Color("Mc");

this line creates new color for moive "box" having instace name "Mc".

    MCColor.setRGB(0xFFFFCC);

Here you can assign color by setRGB function.

I think this will help you out

Cheers
RootDir
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Recently, I was asked to recommend a tracking system to be implemented on a clients website. As the entire site was built on flash, my first thought was to suggest custom built tracking system. However, our company at that point of time didn't h…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
In this tutorial viewers will learn how to create a basic motion tween animation in Flash Open a new document in Flash: Draw/import an image: Press CTRL + F8 to convert it into a graphic symbol: Select a frame (how long you want the tween to last): …
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question