User login

AS3 SnowStorm Class

The SnowStorm class extends Sprite. It produces the appearance of a snowy blizzard within its boundaries, and can be layered over other display objects to create the appearance of the blizzard against any backdrop. This class is designed to be easily instantiated, deployed, and fully configured at run-time, within the context of an object-oriented Flash or Flex application. It is efficient and lightweight; it requires no external libraries or assets and utilizes the lowest level display class possible: Sprite. An extensive API allows you to tweak the density, timing, and other properties of the blizzard.

Features:

  • Pure AS3
  • Nicely blackboxed class
  • Make adjustments to speed, diameter, and color of snow at runtime
  • Methods to create and destroy snow over timespan at runtime
  • Flash/Flex compatible
Creative Commons License
This work is licensed under a Creative Commons Attribution 3.0 Unported License.

These classes are provided freely to use as you wish. Credit attribution is optional when used in a product, but I do ask that you credit me in the source files if you decide to redistribute them.

Credit goes to Pixelfumes for the beautiful snow algorithms.

Package:

  • The core package consists of two classes: SnowStorm.as and SnowFlake.as.
  • Also included as a download are the flex project files used for the live demo below.

You are missing some Flash content that should appear here! Perhaps your browser cannot display it, or maybe it did not initialize correctly.

AttachmentSize
snowstorm.v1.0.zip (Class Files)3.53 KB
SnowStormFlexProject.zip (Flex Project Source)1.51 KB
DonaldHarper's picture

This class is designed to be easily instantiated, deployed, and fully configured at run-time, within the context of an object-oriented Flash or Flex application. It is efficient and lightweight; it requires no external libraries or assets and utilizes the lowest level display class possible: Sprite. An extensive API allows you to tweak the density, timing, and other properties of the blizzard. Great blog! I appreciate the hard work every body is putting in to maintain the website and all the visitors to it, thanks again to all the good people......

Free Credit Score.com

pandawill44's picture

Your article was a good read, and I like the way you write. By the way, let me recommend you an air swimmer as an awesome X-mas gift. Hope you'll like it.

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong>
  • Lines and paragraphs break automatically.
  • You can enable syntax highlighting of source code with the following tags: <code>, <actionscript3>, <css>, <html>, <javascript>, <php>, <xml>.

More information about formatting options

Powered by Drupal, an open source content management system