Loading pre-animation program design

Related Tags:

  We have said that the production of the Flash multimedia web site is the essence of Flash animation, Flash animation is the most widely used.    Flash appeared in the past, the website design is static and Gif animation of the world.    Of course, JavaApplet and JavaScript, and other technologies.    However, the scope of the application of these technologies is not widespread.    Network bandwidth also affect the development of a multi-media network bottles Drive.    But Flash emerged.    It brings new meaning network, the network brought interactive media, interactive multimedia network as possible, become a reality.    Three years ago, when we visit the website list of foreign commentary, also mainly stay on some graphic design work, but now the list of foreign commentary already has a lot of interactive multimedia animation site.    Flash So the speed of development.    IE browser version 6.0 has built-in Flash Player player, it seems that the website预示produced in the path of development.    Let us together interactive experience the charm. 

  Loading pre-animation program design 

  Web Pre-Loading procedures contained in the Web animation is a key, because even Flash documents generated by small, but large-scale animation produced for the use of speed modem users still need to be resolved.    If there is no pre-set process, I am afraid not to watch the animation is very fluid.    Especially in the animation add a great deal of sound and image animation no Loading will not fluent displayed before our eyes. 
  In this study prior to this chapter will be in the attributes and functions.    If, as in the case of the use of the lack of contact with the functions and attributes, as usual, post production, such as in subsequent chapters of the study and other related function after come back to look at, they would fully understand the role of examples. 

  ◆ _framesloaded 

  _framesloaded Attributes of the film clips, used to obtain the film clip has been downloaded churn, of course, most of the film clips used in the attributes can be applied to the entire animation.    This property can only be used to access. 
  If (_root.mc._framesloaded> 100) ( 
  _root.gotoandplay (1) 
  ) 
  Examples of this in ordinary mode input will be: 
  If (getproperty ( "_root.mc" _framesloaded)> 100) ( 
  Gotoandplay (1) 
  ) 
  Common mode of access to property will be used getproperty function, but this function in the new. Grammar is not the best use of the following examples will no longer invoked.    In the case of film clips to download to churn has been more than 100, began to return to re-scenes player.    This is also the site produced a more typical example, a lot of volume because of the film clips, in the "flow" of players in the process will not be smooth.    And the cases would be a mistake example. 
  _root.mc._framesloaded = 100; 
  _root.gotoandplay (1); 
  Programming will be allowed in _ framesloaded attributes of the assignment, if you want to be downloaded to churn at the root directory of 100 start playback, please press the case of the production. 
  If (_root.mc._framesloaded = 100) ( 
  _root.gotoandplay (1); 
  ) 

  ◆ _totalframes 

  _totalframes Attribute is used to obtain the total film clips entities churn.    Animals also can be used to obtain the total churn.    The next will be seen in the case of the use of it. 
  I = _root.mc._totalframes; 
  If (_root.cuttentframes = i); 
  _root.stop (); 
  ) 
  Film editing procedures entities will total churn assignment given the variables i, and when the scene broadcast pointer animation film clips to play in the total churn the same number, animation, stop broadcasting.    This attribute the same attribute of non-assignment. 

  ◆ ifFramesloaded 

  IfFramesloaded function is used to obtain the churn has already been downloaded, and _ framesloaded different is it for a simple act to describe downloaded churn.    But this function seems to be designed specifically for Loading, which is located in Basic Actions instruction set, known as the Directive If Frames Is Loaded.    The following examples will constitute one of the most simple Loading. 
  IfFrameLoaded (_totalframes) ( 
  Gotoandplay (3); 
  Else () 
  Gotoandplay (1); 
  ) 
  Videos in this program and the second frame, the animation can be used for all pre-technology.    Meaning when loaded churn total churn for the third frame when the players, if not, play the first frame.    Flash5 after the start of the function and use of more properties, so this function is not recommended. 

  ◆ getBytesLoaded () 

  GetBytesLoaded () for access to film clips entities have downloaded bytes, if it is external animation will return to the animation of the total number of bytes.    GetBytesLoaded Loading for more accurate design, because it is not like _ framesloaded attribute is the total churn access to the film, but as a unit in bytes access.    If it is said that a final animation will be a major role of the image or sound, which Mody _ framesloaded by the percentage would not be accurate, getBytesLoaded effective remedy the deficiencies in this regard.    Example: 
  I = _root.getBytesTotal (); 
  If (_root.getBytesLoaded ()> = 1000000) ( 
  N = _root.getBytesLoaded (); 
  If (n <= i / 4) ( 
  _root.stop (); 
  Trace ( "downloaded 1 M, which is less than a quarter, animation, too, will be very long download time, whether or not to continue?") 
  ) 
  ) 
  When the meaning of the sentence animation download 1 MB, comparisons are already downloaded a quarter of animation, and if so, to stop animation player in the debug window Display the "M ,..." downloaded, such as a string, according to Animation determine whether other acts continue to broadcast.    Another characteristic of this case is that if there are places to stop inserted film clips, film clips will not stop broadcasting.    Dynamic text can also download the text has been revealed that the number of the main assumptions in the animation scene in the text of a variable called dynamic variable text, which Mody cases: 
  _root.text = _root.getBytesLoaded (); 
  If (_root.getBytesLoaded ()>=_ root.getBytesTotal ()) ( 
  Gotoandplay (3); 
  Else () 
  Gotoandplay (1); 
  ) 
  Dynamic text box dynamically displays the number of bytes downloaded services to the audience.    Animation in the audience will understand the dynamic process of downloading the progress. 

  ◆ getBytesTotal () 

  GetBytesTotal () function is used to obtain animation film clips or the total number of bytes, of course, we can be the size of the document to observe the total number of bytes animation, but the use of the Internet browser audience, Dynamic Display File size is necessary.    Also, if you want to observe the animation film clips only on the size of getBytesTotal () function has. 
  If (_root.getBytesTotal ()> = 1000000) ( 
  _root.stop (); 
  ) 
  This procedure means that the total animation when more than 1 M byte halt animation player. 

  ◆ gettimer () 

  Gettimer () function used to obtain film clips or animation has been broadcast time, this function is not only used in the production of Loading, in the learning process in the future will come into contact with it.    In Flash5 animation playback time on the control will be gettimer () function sets the stage.    But gettimer () function is millisecond access time as a unit of measure to the general procedures in the process of making it will be divided by 1,000 to obtain second, more in line with this time player for the show.    Assume that there is a text animation in the text box dynamic variables.    Example: 
  Text = gettimer () / 1000; 
  Cycle through the frame or other detractors such as OnClipEvent (enterframe) will control the dynamic behaviour of the players show that the time course of animation.    Another example: 
  Text = gettimer () / 1000; 
  If (text> = 10) ( 
  Gotoandstop (3); 
  Else () 
  Gotoandplay (1); 
  ) 
  Assume that this procedure at the main animation scene of the second frame.    Then when the play started only 10 seconds after the official start playing, or only in the first frame and the frame between the second cycle. 

Related articles:

Using Web standards establishment of the first seven days: CSS entry
  XHTML code norms in the understanding, we will be carried out in CSS layout.    First to introduce some introductory knowledge of CSS.    If you are already familiar with, you can skip this section, directly to the next section    CSS is Cascading Style Sheets ...
The Web links in the transfer of documents
  In the current Web page hyperlink use of a large number of links, the use of means to <a href = "designated document"> display text </ a>.    In addition accordance with the different pages and several papers at the following links call:    First, at...
The date of importation of a good controls
  The date of importation of a good controls, you want useful    Date of support, and comes with a variety of interfaces. Skin in the form of themes directory    Download: Click here to download this control  ...
Showing the client implementation of the code pages
  Joined in the pages:  <script>   Var now1 = new Date ()    Now1.getTime StarTime_S = ()    </ Script>    Join before the end of the page:    Client: <script>    Var now1 = new Date ()    Now1.getT...
Flash effects of the current production of realistic animation
  Through a rectangular restrictions x-axis, y-axis movement, continuous replication, the formation of a current simulation effects.    Concrete steps    1, running flash mx, setting attributes for files black background, size 200 * 200 pixels.    2, a new vide...