• home
  • forum
  • my
  • kt
  • download
  • Basic button actions

    Author: 2008-10-29 10:14:55 From:

    Ok, so maybe I’m fobbing you off with some old tutorials whilst I’m doing my exams, but hey, it’s content isn’t it? Here’s another old tutorial following on from the last one showing you how to add some simple actionscript to your buttons to perform the most called for commands.

    FrozenHaddock Tutorials: Buttons 2

    In this tutorial, I’m going to cover differant pieces of Actionscript you can put on
    buttons. Things such as differant frames, and hyperlinks.

    Code 1- Moving to a differant frame
    If you put the following code into the actions panel on your button, if will take
    you to a differant frame in your movie.

    1. on(release){
    2. gotoAndStop(2);
    3. }

    This piece of code will send you to frame 2, you can change the bolded script
    and it will take you to that frame number instead.

    1. on(release){
    2. gotoAndStop("frame");
    3. }

    This code will take you to the frame labelled ‘frame’, you can change the bolded
    script to change which frame you are going to.

    Code 2- Hyperlinks
    If you put the following code into the actions panel on your button, it will take
    you to an internet page or a local file.

    1. on(release){
    2. getURL("http://www.frozenhaddock.co.uk");
    3. }

    This code will take you to frozenhaddock.co.uk, you can change the bolded
    script to change where the hyperlink sends you.

    discuss this topic to forum

    relation tutorial

    No relevant information

    Category

      3D (20)
      Math Physics (14)
      3rd Party (5)
      Navigation (63)
      Actionscripting (158)
      Optimization (17)
      Animation (108)
      Projector (11)
      Audio (52)
      Special Effects (152)
      Backend (26)
      Text Effects (82)
      Drawing (32)
      Tips and Techniques (47)
      Dynamic Content (31)
      Tricks (8)
      Games (97)
      Utilities (21)
      Getting Started (91)
      Video (24)
      Interactivity (43)
      Web Design (29)

    New

    Hot