Create Text Link Actionscript 3.0

This post about creating text links in flash. Text links are used as navigation buttons to a web address.
Here's the script of making text link:

     var tekslink: TeksField = new TextField ();
     tekslink.htmlText = "visit" <a href='http://nandanami.blogspot.com'> nandanami.blogspot.com </a>! ";
     addChild (tekslink);


If the writing of the above is correct, press Ctrl + Enter to see the results.

Creat HitTestObject Actionscript 3.0

Okay, this time on the basis of using hitTest Object. HitTestObject script is a script to detect the collision of an incident in which two objects touch each other. For more details see the following script:
1. Make two objects with a movie clip instance name "mc_box" and "mc_oval".
2. Later in the frame 1 press F9 to activate the actionscript window.
3. Then type the following script:
addEventListener (Event.ENTER_FRAME, collision);
function collision (event: Event): void {
     if (mc_box.hitTestObject (mc_oval)) {
           trace ("ouchh"); // <- Displays the message "ouchh"}
     }
}
4. Run the program (Ctrl + Enter).

Create HitTestObject

In addition hitTestObject script, there is also a script hitTestPoint used to detect the point of registration points on the object.

Following
the writing of the script:

1. Suppose that in the previous post Basics Using HitTestObject, there are two movie clip object is "mc_box" and "mc_oval".
2. Type the following script in frame 1.

addEventListener (Event.ENTER_FRAME, collision);
collision function (event: Event): void {
       if (mc_box.hitTestPoint (mc_oval.x, mc_oval.y)) {// detect any collision
             trace ("collision successfully");
       }
}
3. Running the program by pressing Ctrl + Enter.

Create Looping "For" in Actionscript 3.0

Here's an example of looping that you will be typing in Adobe Flash Actionscript 3.0 :

  for (var i :int = 1; i<=5; i++){
      trace(“hello gamer”);

  }

And result :

   hello gamer

   hello gamer
   hello gamer
   hello gamer
   hello gamerexplain :
 - And i++ will print the phrase "hello gamer" repeated 5 times

~ Good luck

Create Tween with Actionscript 3.0

Ok, I just explained about this tutorial.
  1. On frame 1, press F9 to open Action-Frame.
  2. And typing following script :

 - coordinate x

    import fl.transitions.Tween;
    import fl.transitions.easing.*;

    var myTween:Tween = new Tween(mc_box,”x”,Strong.easeOut,-300,250,1,true);

      3. Running program.

Create Hello World in Class Actionscript 3.0

Hello blogger. I want explain about "Create Hello World in Class Actionscript 3.0". Let's see structure writing actionscript :

package
{
     // class
     public class name_class{
          // contructor
           public class name_function(){

            //program
           }
      }
}

Drag & Drop Using Adobe Flash : The First Method: startDrag

The First Method: startDrag
Here is an overview of what we want to achieve :
 
1. When a displayObject is clicked, started having the object move around with the mouse with a corresponding offset position.

2. When the user lets go of the mouse button, stop dragging the object.

When you convert the above logic to code, you will see that it's actually very simple. Create a movieclip in flash, and instance name is something. I'm going to draw Circle and name mine circle_mc.

Free Flash TemplatesRiad In FezFree joomla templatesAgence Web MarocMusic Videos OnlineFree Website templateswww.seodesign.usFree Wordpress Themeswww.freethemes4all.comFree Blog TemplatesLast NewsFree CMS TemplatesFree CSS TemplatesSoccer Videos OnlineFree Wordpress ThemesFree CSS Templates Dreamweaver