# Tint Problems in Actionscript

**URL:** <https://forum.kirupa.com/t/tint-problems-in-actionscript/242347>\
**Category:** flash\
**Created:** [October 24, 2007, 10:28pm UTC](https://forum.kirupa.com/t/tint-problems-in-actionscript/242347 "2007-10-24T22:28:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mental](https://avatars.discourse-cdn.com/v4/letter/m/c77e96/32.png) [@Mental](https://forum.kirupa.com/u/Mental)\
**Post date:** [October 24, 2007, 10:28pm UTC](https://forum.kirupa.com/t/tint-problems-in-actionscript/242347/1 "2007-10-24T22:28:53Z")

</div>

Hi,  
I have recently been trying to create the necessary code in Actionscript to allow a movie clip to change Tint randomly and gradually. After looking at other similar posts I was able to work out how to make the Tint of an object change with code. However I have been using a switch statement (which isnt practical) and with the method I have used it is not possible to change the opacity value of the tint, so the object changes colour instantly rather than fading into it.

The method I am currently using is:

```
var colour = new Color(myMovieClip);
colour.setTransform({rb:100, aa:20});

```

Any help is appreciated.  
Thanks.
