Ace snow: Create snow falling effect for Titanium apps

Recommend this page to a friend!
  Info   Example   Videos   View files Files   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 262 All time: 175 This week: 8Up
Version License JavaScript version Categories
ace-snow 1.0BSD License1.0Animation, Appcelerator Titanium
Description 

Author

This object can create snow falling effect for Titanium apps.

It creates animated flakes that fall on the application window starting from a random position at the top of the screen and disappear when they fall below the top of the screen.

The flakes animation can be paused and resumed any time.

The image, quantity and the speed of the snow flakes are configurable parameters.

Picture of Arturs Sosins
  Performance   Level  
Name: Arturs Sosins <contact>
Classes: 51 packages by
Country: United States United States
Age: 36
All time rank: 1
Week rank: 6 Down
Innovation award
Innovation award
Nominee: 8x

Winner: 6x

Example

/************************************************************* * This script is developed by Arturs Sosins aka ar2rsawseen, http://appcodingeasy.com * Feel free to distribute and modify code, but keep reference to its creator * * This Titanium object creates a falling snowflake effect for your application window. * It is possible to set quantity and speed of flakes, and also provide image of custom * snowflake. This object also provides methods to start or stop snowing and add flakes. * * For more information, examples and online documentation visit: * http://appcodingeasy.com/Titanium-Mobile/Snow-for-your-Titanium-app **************************************************************/ //create main windows var win = Titanium.UI.createWindow({ title:'Tab 1', backgroundColor:'#000' }); //create countdown var AceSnow = require('AceSnow'); //generate snow var snow = new AceSnow(win, { color: "white", fallingTime: 12000, flakeInterval: 800, flakeSize: 10, sizeDelta: 5, curve: Titanium.UI.ANIMATION_CURVE_EASE_IN_OUT, fadeOut: true, autoStart: true }); //for button generation var createButton = function(text, top, callback){ var button = Ti.UI.createButton({ height:50, width:"50%", color:'#fff', title: text, font: { fontSize:14, fontFamily:'Helvetica Neue', fontWeight:'bold' }, left:"25%", right:"25%", top:top }); button.addEventListener('click', callback); return button; }; //create button to start snow win.add(createButton("Start snow", 100, function(){ snow.start(); })); //create button to stop snow win.add(createButton("Stop snow", 150, function(){ snow.stop(); })); //create button to add flake win.add(createButton("Add Flake", 200, function(){ snow.addFlake(); })); win.open();

  Files folder image Files (2)  
File Role Description
Plain text file AceSnow.js Class Main class source
Accessible without login Plain text file app.js Example Example app

 Version Control Unique User Downloads Download Rankings  
 0%
Total:262
This week:0
All time:175
This week:8Up