Page 1 of 1

Pretty neat canvas selection (Animated)

PostPosted: Wed Nov 17, 2010 4:50 am
by Hblade
I made a neat canvas selection tool, where you can use multiple canvas (AND COLORS :D) actors as selectors (or just 1 with different variables, bleh bleh). It's animated by having 4 white bars move across the selection area at your desired speed.

IMPORTANT
You will need to make an ACTOR variable called "VAR" in order for this to work.


Screenshots:
Screenshot-1.png


The screenshot makes it look buggy :P

Demo:
Scripts.zip
(51.65 KiB) Downloaded 84 times


Script:
Code: Select all
void selection(int R, int B, int G, int SPEED) {
    //Background Color
      erase(R, G, B, .64);
 
    //Set the color of lines
      setpen(255, 255, 255, 0, 1);

    //Make the 4 lines
    //LINE 1:
         moveto(VAR, 0);
         lineto(VAR, height);
 
    //LINE 2:
         moveto(VAR-16, 0);
         lineto(VAR-16, height);
 
    //LINE 3:
         moveto(VAR-32, 0);
         lineto(VAR-32, height);
 
    //LINE 4:
         moveto(VAR-48, 0);
         lineto(VAR-48, height);
 
 
 
   //ADD Variables
         VAR+=SPEED; if (VAR>=width+48) {
             VAR=0;
                                }


                                    }
}

The C file inside of the zip hasent been updated from the previous version so please use this script xD :3



Usage:
selection(R, G, B, Speed);

Example:
selection(14, 28, 255, 2);

Have fun ^^

Re: Pretty neat canvas selection (Animated)

PostPosted: Wed Nov 17, 2010 8:09 am
by lcl
Looks cool. :D
I'll try it. :D

Re: Pretty neat canvas selection (Animated)

PostPosted: Wed Nov 17, 2010 1:42 pm
by Hblade
thx ^^

Re: Pretty neat canvas selection (Animated)

PostPosted: Wed Nov 17, 2010 3:19 pm
by lcl
Nice. :D Good work! :D

Re: Pretty neat canvas selection (Animated)

PostPosted: Wed Nov 17, 2010 7:14 pm
by Hblade
ty ^^