Grant Skinner

The "g" in gskinner. Also the "skinner".

@gskinner

Completely Free Hosting

A friend of mine pointed me to 1and1.com, where they are giving away 3 years of free hosting to generate word of mouth promotion (like this) until Jan 21. I’ve read through some of their FAQs, and it seems legit: 500MB space, 5GB transfer, PHP, MySQL, etc – and their overflow bandwidth is cheap at 99cents/GB. They’ll even register domains for you for only $5.99/yr.

The only catch I’ve found is that you don’t receive phone support, but I don’t consider that much of a catch (who calls their host anyway?).

I haven’t signed on with them (my current host keeps me pretty happy – and supports FlashComm), but even so, I’m tempted to dream up a new domain to register with 1and1.

FF Film Festival Nominations Open

I haven’t seen anyone else blog this (though I’ve been negligent in my blog reading duties, so I probably just missed it), so I thought I should – nominations for the FlashForward 2004 San Francisco Flash Film Festival are now open. If you have any cool projects that you’ve developed recently, and would like to get your hands on a wicked-cool orange rubber arrow (I have two, brag, brag) be sure to visit the nominations page.

Class locations in AS2.0 run-time

I hadn’t really thought about where AS2.0 classes reside at run-time until I encountered a need to dynamically create instances of the classes I had made for one of my current projects. In AS1, it was really simple to dynamically create instances from a class name, because you specified where the class definition resided, for example:

// on _root
function MyClass() { };
// anywhere else:
className = "MyClass";
myInstance = new _root[className]();

However, in AS2.0, you never specify where the class definition sits – it’s really pretty obvious though, if you think about it for a moment. AS2.0 classes can be accessed by name from anywhere in the swf – they are accessible globally. This , of course, is because they reside inside of _global. For instance, if you defined a custom class called “MyClass” in AS2, you could access it at _global.MyClass, and could create instances of it dynamically with:

className = "MyClass";
myInstance = new _global[className]();

Simple, eh? So what about classes inside of packages? Well, the dot notation indicates an object hierarchy, and it turns out that’s all there is to it. The class definition for a class called “MyClass” inside the “com.gskinner.utilities” package can be found at _global.com.gskinner.utilities.MyClass. If you knew the package was always the same, you could create instances dynamically with:

myInstance = new _global.com.gskinner.utilities[className]();

If you want to create instances from full dynamic class names with varying packages, you can use this function I whipped up:

function getInstanceOf(p_fullName:String):Object {
var classPath:Array = p_fullName.split(".");
var package:Object = _global;
var l = classPath.length-1;
for (var i:Number=0;i<l;i++) {
package = package[classPath[i]];
}
var c:Function = package[classPath[classPath.length-1]];
var instance:Object = new c();
return instance;
}
// test it:
myInstance = getInstanceOf("com.gskinner.utilities.MyClass");

Unfortunately, I haven’t got it working with .apply yet, so you can’t pass arguments to the constructor (if anyone gets this to work, send it to me, and I’ll post it).

All of this raises an important consideration: Be careful of name conflicts with packages when adding items to the _global object (classes should be fairly safe due to their capitalization)! If you have a class “com.gskinner.utilites.MyClass”, and you then you define a _global.com variable, you will overwrite the entire “com” class package (Eek!). For example:

import com.gskinner.utilities.MyClass;
_global.com = 127;
myInstance = new com.gskinner.utilities.MyClass();
// myInstance is undefined!

Upcoming presos: FitC, FFSF, NAIT, UofA

I received confirmation today that I will be speaking at Flash In The Can 2004 (Toronto) in early April. I will be speaking on coding production-friendly ActionScript 2.0. Rather than rehash syntax, I will focus on how to actually apply AS2.0 to real projects in the most effective manner possible. I really feel it will be a phenomenal session, given the ramp-up I will have in the preceding speaking engagements, and the practical knowledge I am gaining from a number of projects that I have been working on.

In January and February, I will be instructing “FlashMX 2004 Enterprise-level Development” at the Northern Alberta Institute of Technology. This is a 36 hour course, spread over 4 weeks, covering advanced Flash development.

At the end of January, I will doing a guest lecture to fourth year Arts students at the University of Alberta (topic to be finalized), which I’m pretty psyched about.

In early March, I will be doing an Ask The Experts session at FlashForward San Francisco, dealing with basically the same topic as my FitC session. I will begin with a short session discussing my development techniques, best practices, and look at some real world examples; then provide attendees with an opportunity to ask questions about implementing AS2.0 in their projects. This should help provide a great foundation of really relevant material for my FitC session.

Hope to see some of you at these events. Be sure to say “hi” if you see me!

FLAws: Forms

Need I say any more? j/k 😉

Quick disclaimer: There’s a good chance I’m wrong about some of how this all works, so please feel free to correct me, I do not want to spread incorrect information or FUD.

Forms in Flash are a little like the apple in the garden of Eden – tempting and nice to look at, but all hell breaks loose when you try to eat ’em. It doesn’t help that the whole time this little snake called Macromedia is whispering in your ear, telling you to take a big bite.

Adding Forms to Flash was a great idea – it provides a nice, structured development environment for state based applications, it makes implementing MVC clean and simple, and it makes the technology far more accessible to programmers familiar with environments like Visual Basic.

Unfortunately, the implementation is – hmm, how to put this politely – substantially sub-par.

Continue reading →

Gadget inspector.

Christmas is around the corner, and its time to start looking up some killer swag. Last year I got a crap load of household stuff (I bought a loft 2 years ago, and everyone thinks I still need tea kettles and towels, blech), so my loving girlfriend decided that this year I should get some fun stuff. Here’s some of the toys she found waiting in cyber space (and don’t worry, there’s no hidden referral links) (or adult content, for that matter) :)…

Continue reading →

The Internet is sh!t

Via gijs nijholt

I don’t usually link to people’s opinion pieces, but I thought this post on why the Internet is shit was a good read, and the last paragraph reflected a feeling that plagues me.

When I first got into web design (a whopping 9 years ago), everything was new, everyone was excited, and I was kept in a constant state of awe as the modern “rich” internet emerged from the primordial soup of HTML 1.0. Maybe I’m just getting old and jaded, but lately that awe has receeded – I rarely see web work anymore that really excites me. There have been a few pieces that really caught my attention as good examples of what can be done (really, what should be done), but nothing that makes me really feel that the pea-brained dinosaurs of the present-day web will be replaced with smarter, more adaptable successors.

I’m left in a constant state of anticipation – I feel like something has to happen, some new concept has to begin defining what the web is going to be 5 years from now. This serves to define much of my professional life, I’m fortunate in that I can usually pick and choose the clients I work with, and I typically do so on the basis of how progressive or interesting the project (or the client) is. It also drives me to tackle monolithic projects with little hope of recompense, just to prove to myself and the community that things can (and should) move forwards (see: FlashOS, FlashOS2, gModeler, etc).

I think the most exciting thing I’ve seen recently is the involvement of talented writers, with a firm understanding of the medium, in the development of websites. A good writer goes beyond copy-writing to help define the narrative of a site, establish a repoire with the user, effectively (and engagingly) communicate the core messages of the site, and work with the designer to develop the user experience.

Now don’t get me wrong – I love my job, and I think the Flash community is phenomenal, I’m just left wondering if there isn’t more that we could do to evolve this medium to the benefit of our clients before the meteor (longhorn?) hits.

PS. If you’ve built a Flash intro in the past 3 months, without discussing with your client why its a waste of their money and what their alternatives are, kindly raise your hand and exit the blog – you’re holding us all back, mate.

[EDIT:] Wow, I really must be getting old and cranky… too many complaining posts in the last few days… must… post… something… positive. 🙂