setRGB: Set up the RGB colour - SWiSHMax Tutorials
 
  Buy Ebooks, Video Games, DVDs, Electronics and more !
Home | Help Forums | Web Design Tutorials | Free Swishmax Downloads Make Money Online Blog . Free Image and Photo Sharing and Hosting

 

 

Company

Home

Nework Details

Tutorials

SWiSH 2

SWiSHMax

Flash MX

PHP & MySQL

HTML / JScript

Adobe Photoshop

Corel Draw

Gimp

Miscellaneous

Downloads

Templates

Plugins

Fonts

Wallpapers

Free Images

Scripts and Codes

Products

E-Books

SWiSH BB

SWiSH Templates

SWiSH-DB Newsletter
Subscribe to our newsletter : GO
  Partners / Affiliates

   Free image hosting
   Web Design Pakistan
   Swish Templates
   SWiSH Climax
   Talkfreelance Community
   Template Desire
   Lite boards
   Script Sector
   GimpTalk
   13dots
   Idea Designs
   PHP Cafe
   Sposatoettore
   Free swishmax templates
   Swishzone

Manage your site with Flax Article Content Management System
setRGB: Set up the RGB colour
Category : SWiSHMax | Level : Beginner | Language : English
Ask Question | Read Comments | Post tutorial | Previous | Next

Web www.swish-db.com

Download exampleTo reply to some requests arrived to me:
(I hope to be enough clear with my English)

setRGB: Set up the RGB colour

For the mean of the object "Color" is possible to plan a color RGB to a Target of
a movie. A common example of use is the possibility to choose the color of the
background of the movie:
On the background of the movie, there is a sprite with drawn a rectangle (white in
the beginning). When the user chooses the type of color to assign, the sprite
background recolor itself with the choice color comes.
We see like..
Before all we have to set the color RGB using the syntax "0xRRGGBB",
and during the creation is necessary to specify the Target to that the object does reference:

new Color(Target)

Then, it comes used the method setRGB to plan the color wanted.
For RED, for example is "FF0000" that becomes (0xFF0000) (as we can see on the sintax above)

Here how it appears the script of the button "red" :

on (release) {
colore = new Color(sfondo);
colore.setRGB(0xFF0000);
}


and so on for the colours that we want to use.
Our object must have the mask that allow the change of colours and so we have to select for the sprite
"Use bottom object as mask" (how we can see in the example below)

VIEW



© 2002-2005 Flaxweb Network | Article Manager | Gimp Tutorials Library | RAD C++ Library | Free C/C++ Sourcecode |
Sites of interest : Web Design Blog | Swish Templates | Swishmax Ebook | Photoshop Templates | Gimp Tutorials | Text Forum | Make Money Online