How to become a Flash Lite developer)

Source: Internet
Author: User

Author: luar

Link: http://www.luar.com.hk/flashbook/archives/001228.php

To develop the Flash Lite content, most people suffer from the flash 4 attack method. For those who are developing the flash 4, the beauty of programming is the same requirement. There are many different programming methods,Always changes. On the contrary, when running on a mobile phone, performance and memory usage are the biggest difficulty, which is often the cause for developers.Use intelligence to overcome Performance. Therefore, the flash 4 compression method is a problem that people outside the Community think, to overcome the efficiency is the goal of the daily Flash Lite development.

Okay, let's talk about it. How is Flash Lite ActionScript? It is the flash 4 ActionScript and memory generator that helps with some Flash 5 commands, mobile terminal features, and fscommand2.

Flash 4 ActionScript

Contains the following things:

  • Video (play, gotoandstop, loadmovie, etc)
  • Variable definition set ("varname", varvalue)
  • While and if
  • Movie clip controls getproperty and setproperty
  • Some string sort operations (length, substring), etc.
  • Routing Algorithm (telltarget ,/,../,
  • Loadmovie, loadvariable

Note: startdrag, stopdrag, _ droptarget, soundbuftime, _ URL, and string () parameter values are not supported.

 

Flash 5 object

With the help of compiler, some Flash 5 commands can be used. They are regarded as the flash 4 coding method during peak hours, including:

  • More sentence-based sentence handling (for, do while, switch)
  • _ Root, _ parent
  • Movieclip. Attention = n. Pay attention to the movie clip encoding method. It is only applicable to the screenshot fetch and modification. To control movieclip playback or skip, telltarget is still used.
  • Variable definitions can be directly used with varname = varvalue

 

Mobile phones and fscommand2

These are some commands for obtaining the mobile device information and controlling the mobile device (such as earthquake and SMS). If Flash Lite is usually used to develop the mobile device, the following are common examples:

  • Earthquake: fscommand2 ("startvibrate", time_on, time_off, repeat), fscommand2 ("stopvibrate"); (some mobile phones do not support earthquake, such as Nokia 7610, n-gage)
  • Full screen capture: fscommand2 ("fullscreen", true); (only supported by standalone Flash Lite player, for example, Nokia mobile phone; not supported by seeking in browser, for example, Sony Ericsson mobile phones)
  • Function compute name: fscommand2 ("setsoftkeys", "Start game", "quit, only visible when the screen is not full)

 

From Flash 4 port to Flash Lite

When Flash Lite was started, it often started from the previous flash 4 things, for example, changing the previous things to the Flash Lite version, note:

  • There is no mouse on the phone, so all the things that rely on the click operation should be changed to the click operation method.
  • The Flash Lite auto-support option is directed to the next hop and then to the next hop. At the same time, it is very convenient to display the cursor over the next hop. It is usually used during development. For example, the main hosts include "Start Operation", "Incoming operation", and "starting operation". You can use the direction to configure the upstream and downstream control. Note 1: Some mobile phones do not support four way navigation with wraparound, that is, you cannot directly jump to start navigation when you press "off 」, the Flash Lite emulator in Flash Pro 8 will prompt whether the mobile phone is supported. NOTE 2: Generally, on the master plane, you want to set "Start sequence" to "over sequence". However, if you only rely on the auto-Scaling Method of Flash Lite, I can't do it. In addition, I want to make a choice that can be wraparound. I still use movie clip and self-capturing direction to make the decisions.
  • The size of the video. Generally, the 60-inch Symbian size is tested first, that is, the full screen size is 176x208.
  • Generally, the performance of a mobile phone is only 8-10 FPS. When there is Alpha gain, it will be a little slower.
  • The text must use pixel font to be clear. The position X and Y of the text must be an integer.
  • The SwF limit is within kb.
  • Flash Lite emulator of Flash Pro 8 can basically simulate most of the operations on mobile phones, except for controlling the hardware of mobile phones with fscommand2, note that emulator cannot model performance, so it is more difficult than a mobile machine to run and does not know the problems that consume the memory. Therefore, emulator consumes both performance and memory, be sure to go back to your phone
  • Adding _ focusrect = 0 to frame 1 can eliminate the hidden color frame when controlling the focal point.
  • No Delete can be used to divide the change data, so we have to change it to Var = ""
  • You must use add for string links. You cannot use +
  • Using bitmap watermark, first compile the watermark in Photoshop. For example, if the watermark color is less than 8/16/64, the file size can be greatly reduced to avoid the occurrence of problem with content: 6 Gbit/s bytes (Bad JPEG data, JPEG encoded bytes are too large)
  • Fscommand2 ("setsoftkeys") can be used in the frame because of the operator or different operator types. This means that the function variable name can be changed without interruption.
  • Some mobile phones do not support manual compaction (that is, the press is not allowed), for example: sonyericssion z800i
  • Generally, orientation, enter, Pageup, and Pagedown are commonly used. I will make a flash template, and there will be seven transparent la s outside the stage (only hit frame is defined ), added on (keypress "... "){...}
  • I found that many Flash Lite examples do not have audio. This is very different from the usual flash method. So there are fewer people involved than others? I will renew it later in the next article.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.