Posts Tagged ‘Flash’

Revisiting Papervision3D

Sunday, March 9th, 2008

I subscribe to the Papervision3D RSS feed, and once in awhile something interesting comes along and gets me thinking. This recent entry was as such: a gallery of sites that utilise Papervision3D to create new, innovative graphical user interfaces for their users. Looking at them got me psyched up to start on my own (long overdue) site.

However, going through some of the sites raised a common issue, and that issue is one of userability.

History

As someone in the comments noted, History repeats itself. Looking back to the early days of gratuitous .gif animations, unusable Flash websites, and then to the more recent AJAX revolution of Web2.0. Whenever something innovative comes forward, people struggle to find “proper” use for it, and instead end up throwing it all at the user in the hope that they will be “shocked and awed” by it. Perhaps, in the Dark Ages of Web1.0, this strategy would have worked (and it did, for a time). However, people on the internet are now tech-savvy: they want their stuff, and they know how to get it. To prevent them from doing so in any way would be a death-sentence to any website. (more…)

Labs: Line-Of-Sight

Friday, November 23rd, 2007

Did a quick little experiment with Line-Of-Sight Calculations in AS3.0. I’m not too happy with it at the moment, and trying to find a balance between performance and accuracy, but you can see what I have done so far in the Labs.

Experiment Focus:

  • flash.geom.Point;
  • Line of Sight

View Experiment

My FlashDeveloping Tools

Wednesday, November 21st, 2007

Came across a post by Wayne Marsh today, documenting the tools he uses to develop in Actionscript 3.0 without his wallet being set back by a dollar. And it is exactly the same as how I do it as well, with the long awaited release of FlashDevelop 3 looming.

So be sure to go over for a look at how you can start developing in Actionscript 3.0 for less than a penny.

Abstracting Assets from Actionscript in AS3.0 - Asset Libraries

Friday, November 16th, 2007

Introduction

I write this article because it seems to me that quite a few people still have no idea how to duplicate external assets (such as duplicating MovieClips, for example). Thus, I decided to take this opportunity despite there being quite a few articles that document this. If I haven’t bored your by now, read on!

First, Some History

Assets in Flash are normally quite coupled with the SWF. This is probably a result of the long years of timeline scripting that has been burnt into our memories. In Actionscript 2.0, however, the process of abstracting Assets from Actionscript was slightly alleviated through the copious use of duplicateMovieClip(). I too, used to be an avid user of duplicateMovieClip(), until I made the transition to Actionscript 3.0, But before then, duplicateMovieClip() was my quick and dirty solution to many situations I came across in Flash.

Abstracting Assets from Actionscript in Actionscipt 2.0 was relatively simple. One need only separate his/her assets into separate swf files, and simply loadClip() them into the SWF, and employ the use of duplicateMovieClip(). In Actionscript 3.0, however, this situation has changed as Adobe saw fit to remove (or shall we say, omit) the duplicateMovieClip() method.

Now, Adobe recommends the use of the “new” keyword to instantiate multiple instances of a Class. From the Actionscript 2.0 Migration reference:

In ActionScript 3.0, use the new operator to create a new instance.

This doesn’t really help us abstract our Assets from Actionscript. Most of us who have played around enough in Actionscript 3.0 would know that this requires that the Class be part of the SWF calling it, and in facts forces us to embed our assets within the SWF. Using the Loader class to import external SWFs does not expose any classes that we may use to invoke the “new” operation. At least, not obviously, as we shall see later.

(more…)

Papervision3D Clipping Issues

Tuesday, July 17th, 2007

Gah! What is with all the clipping issues I get? The problem arises specifically at angles close to multiples of 90. I suppose these are problems arising mathematically due to some special trigonometric properties, and seriously hope they get fixed soon.

Again, of course, the library is still currently in Beta status. So it is probably not perfect. However these are the kind of things I’m hoping they will iron out as time goes along.

Unfortunately, I can’t seem to grasp 3D Rendering techniques, and I won’t be making my own engine anytime soon! There goes my Rubik’s Cube idea…

Papervision3D is impressive, but…

Friday, July 13th, 2007

I’ve been playing abit with Papervision3D recently, and I’m seriously impressed with their work. However, there were some parts I had trouble with, but I’m willing to let it pass, as it is still in Beta status. Seemingly trivial things like “changing the textures of each side of a cube” seems to require some subclass. And in some cases, I still found evidence of bad clipping. Though that is probably my fault.

Over the next few days, look out for my wonderous journey in learning Papervision3D.

Flash on iPhone?

Thursday, July 12th, 2007

Recent speculation suggests that the Adobe Flash Player plugin would be coming sooner for Apple iPhone’s Safari sooner than we’d thought/dreamed.

I can’t even begin to speculate the amount of possibility this opens up to flash developers. This is perhaps far more revolutionary than WiiFlash! Imagine the touchscreen capability of the Nintendo DS, opening up to the Flash platform, allowing for a whole new slew of creative works for Flash. One thing I’d definitely want to see, if the above does turn out to be true, is a port of Ouendan!.

That aside, though, there will be a number of things to think about. Firstly, public adoption of the iPhone seems rather low at the moment to me, due to price and also network restriction. Not to mention its only only available in the US. The other interesting thing I’d like to see being taken advantaged of would be the iPhone’s Multi-Touch technology. Most “WiiFlash” games that take advantage of the WiiMote are no more than glorified Flash games using the mouse. How would Flash developers be able to take advantage of the different Multi-Touch capabilities?

Although this may never come, its still something worth keeping a tab on.

Removing Children of Containers

Saturday, July 7th, 2007

As everybody knows, not keeping track of referenced objects is BAD. And the one thing worse than not keeping track of referenced objects is dead references.

For example, if you had an instance of an object, you must dereference everything associated with it before it is garbage collected. This may seem like child’s play to most veterans; things like event listeners are easily removed. However, it is important to note that in the case of DisplayObjects, your DisplayObject may have children that are also referencing it (through the ‘parent’ property). Removing the DisplayObject at this stage will therefore result in dead references to its children and itself! You’ll end up with massive amounts of memory leak as time goes along.

Luckily, there is a handy Event you can use. The Event.REMOVED Event fires when an object is removed from the display list! So with a bit of code, one can easily remove all children when it is removed from the display list.

this.addEventListener(Event.REMOVED, iveBeenRemoved, false, 0 , false);
private function iveBeenRemoved(e:void):void
{
   while (this.numChildren != 0)
   {
      this.removeChildAt(0);
   }
   this.removeEventListener(Event.REMOVED, iveBeenRemoved, false);
}

Simply one of the things we might overlook in our coding practices. I myself will try to remember about child objects.

Freedom of Flash Games

Monday, July 2nd, 2007

Recently a flash game was published on a site which I frequent, and as a result it riled up a few members of the community. Now, flash games of all varieties have existed for many years. Gory and violent games that could rival Manhunt can be commonly found. But this particular SATIRE touched on a topic of controversial nature, and after a series of events, the game was eventually taken off voluntarily by the developer, although it can still be found on other sites.

A few issues come to mind. Why is it that Flash Games seem to be free of the regulation constraints that plague our mainstream games? Similarly, why aren’t websites that distribute these games required to moderate their content, especially since Flash Games can reach a much wider audience, far wider than your mainstream game, and is distributed faster and to an enormous demography of internet users?

Another big issue is that of opinions. Who could be responsible for rating these games? Efforts in this area such as TIGRS depend on the developer, and do not enforce this. Some of them are simply tedious and require too much effort on the developer’s part to even bother. And just because a developer does not find his game offensive, does not mean that everyone else will think the same.

Thus, the question in the end is “what does the future hold in store for us developers”? How long more will we be able to enjoy this freedom on the internet? And what can we do to ensure developers can enjoy this luxury?

AMFWP - AMFPHP + Wordpress Integration

Tuesday, January 30th, 2007

The site for my work on AMFPHP and Wordpress Integration can now be found at

http://darylteo.com/amfWP/

<<<<<<< .mine