Tagged with KitchenSync

KitchenSync Version 2.0 is now available!

by

I’m very proud to announce that the second version of KitchenSync has arrived! What started as a labour of love about 3 years ago has finally gotten its first much needed upgrade. Just about everything in this version is newer and more streamlined. The entire system for greater simplicity and practical functionality.

This version will not be backwards compatible, however, there’s finally some Decent Documentation!!! There’s also a new blog devoted to KS.

GO GET IT NOW!

Here’s some of the new features. You can view all of them by checking out the change log.

  • Usability
    • REFACTORED all classes with usability and stability in mind.
    • UPDATED all ASDocs
    • ADDED several new methods in the TweenFactory for easy tween creation.
  • Synchronizer and Time
    • REFACTORED The way time is handled throughout.
    • ADDED ISynchronizerCore and example core classes. This allows advanced users to switch between different methods of timing (e.g. enterframe or timer based)
    • ADDED FrameRateUtil for getting instantaneous and averaged framerates of the system. The FrameRateView now makes use of this class and has more options.
  • Action Architecture
    • REFACTORED action classes and extracted several interfaces from them.
    • ADDED jumpToTime and jumpByTime functionality to actions.
    • ADDED Looping via a new group called KSLooper.
    • REMOVED complicated and rarely used action triggers from AbstractAction.
    • ADDED togglePause() method and progress variable to AbstractAction (for getting percentage complete of an action).
  • Tweens
    • CHANGED constructors in KSTween. Emphasis is now on using TweenFactory.
    • IMPROVED Object parser in TweenFactory
  • Action Groups
    • ADDED Syntactic sugar to the group constructors. using an array in the constructor for a parallel group adds a sequence and vice versa.
    • ADDED totalDuration to groups to show the duration of all child actions in a group.
    • ADDED KSRandomGroup.
    • REMOVED KSSteppedSequenceGroup because it seemed kinda useless.
  • Loading Actions
    • REFACTORED Loading actions. Now they’re much easier to use and more powerful.
    • ADDED KSLoadQueue for quickly creating a class to load files from the network in a batch.
    • ADDED the resultList property to the ILoaderAction interface so that you can quickly access the loaded files in a batch.
  • Misc
    • RENAMED several classes and reworked package structure
    • ADDED KSAsynchronousIteration for running processor-intensive for loops spaced out over a period of time so that they are essentially asynchronous.
    • FIXED several minor and major bugs.
Tagged , , , ,

Tip: Adding version checking to your external code library

by

Since version 1.0 of a code library that I’m sure you’re tired of me talking about came out, I have been making steady updates, some of which break legacy code. I was also having trouble keeping track of which version of the library a particular demo was written for. In order to make sure that the new code library doesn’t cause unpredictable results for the old implementations I added a version check to the main class.

This version check is very simple. It checks a version number in the client code against a version number of the library (or external classes) when the main class of the library is initialized. It is also completely optional (so average users don’t need to mark up their code with version numbers).

Here’s an example:

Say you normally initialize your library using:

MyLibrary.initialize();

Which calls the initialize method:

public static function initialize():void {
   // initialize library here
}

If the external code changes unexpectedly (say through an SVN update) this could cause problems that are difficult to trace. The solution is to modify the initializer to match the client code version with the initializer version.

public static const VERSION:String = "1.6";
public static function initialize(versionCheck:String = VERSION):void {
   if (versionCheck != VERSION) {
       throw new Error ("The version check failed! This library is version " + VERSION + ". Update your code or GTFO!");
   }
   // initialize library here
}

And when you run the initializer, use the version number you’re expecting.

MyLibrary.initialize("1.6");

Some things to notice with this approach:

  • I used a string instead of a number for the version number so that it would allow for sub-sub version numbers and other markers, e.g. “1.6.24 beta r545″
  • Because there is a default value for versionCheck in the initializer, providing a version number is optional. Using MyLibrary.initialize() will still work and throw no errors.
  • Unfortunately, there is not much you can do if the version numbers don’t match except to warn the client that the external code has changed. Still, I’ve found this to be very useful.

The code for my initializer in its entirety after the jump…
Continue reading

Tagged , , ,

KitchenSync version 1.6 released!

by

KitchenSync version 1.6 is released! Guess what feature it doesn’t have yet… That’s right! There is STILL NO Color Tweening (unless you count ColorMatrixFilter tweens which it does have). However, I hope I can crank out and release version 2.0 over the next two weeks which would have it.

Here are some of the features that 1.6 DOES have:

  • Added a TweenFactory which provides an easy to use interface for creating new tweens including an object parser similar to FuseKit’s interface. You can now use something like:
    var tween:ITween = TweenFactory.newTween({target:foo, properties:"x:0~100, y:500~200", duration:"3seconds", scale:1~5});
  • Altered KSTween to use multiple tween targets. Now includes methods like addTweenTarget(). This allows you to tween multiple properties with a single KSTween object!
  • Added an optimized implementation of IAction called KSSimpleTween. This class showed a 25% performance increase over KSTween!
  • Added SoundTransformTarget for changing volume or panning of a sound.
  • Added new action groups including:
    • KSSimultaneousEndGroup which causes all children to end simultaneously. This is like a parallel group in reverse.
    • KSSteppedSequenceGroup for sequencing PowerPoint-like applications. This automatically pauses the group after each child is completed. Instant slideshow!
  • Finished adding IAction interface. This allows more flexible and customized use of the synchronizer by allowing you to create actions without using the AbstractAction superclass.
  • Also added ITween and ISynchronizerClient interfaces
  • Changed the license from LGPL to MIT license.
  • For a complete list, check out the ChangeLog!

To get the latest version, go to the Google Code project page. Thanks and enjoy!

Tagged , , , ,

KitchenSync demo contest deadline extended

by

The KitchenSync demo contest’s deadline has been extended from today to next Monday, October 20. Get submittin’!

Tagged , , ,

Interviewed about KitchenSync on Inside RIA blog

by

Oh my goodness gracious sakes alive!* I have been interviewed about KitchenSync for InsideRIA blog by RJ Owen of EffectiveUI. RJ is a very swell guy. Mercy me!*

Read!

*My dear grandmother is prone to use expressions like this.

Tagged , ,