Platforms... which is best?

So I'm making a game. Finally.

My first plan was to build it for the iPhone. But iPhone apps are written in Objective-C (I theoretically know C and C++, but haven't used either since college), written on the Mac (I've had mine for 2 years but rarely use it), and deployed out through the iTunes Store's processes (third thing to learn). All those new bits to learn aren't bad, but it's overwhelming to start. $300 later I abandoned the iPhone app idea.

But I've been playing MafiaWars a LOT on Facebook. It's an AJAX heavy PHP game. So I thought, "what if I target Facebook?" More users than the iPhone and I could write the app in ColdFusion and/or Flex. So I'm going down that road now. The security's built in, so easy to add an app, and easier to turn into money. Give the game for free, pay to enhance it. Versus the iPhone where you build the game, then strip it down for a free demo, then have add ons for bonus in game points or something.

ColdSpring, ColdBox, Illudium generated code... squee!

And though I don't have as much free time to code as I might like (see all the WoW posts), I'm liking CF front end programming more than Flex again. It's fast, you don't have to recompile the whole thing and drill back to what you were testing, very easy to push out partial updates (opposed to having the whole app in a few swfs). Before getting back into CF like I have lately, if forced to make the decision, I'd give up CF before Flex, but now it's the other way around. I'd forgotten why I love the language!

Resume woes

So my team wants a "Flex and AIR rawkstar". Someone to fly in, throw down an app or two, revolutionize our development mythologies*, but looking through these resumes, I wonder if such a person exists. This is my first chance to be a part of the hiring process from the other side. And if nothing else, I've learned some great tips for building my own resume. I skipped the list of "technologies and stuff I know". People are listing Flex 3, then in their experience they don't mention ever writing a line of code. Writing CFCs and business logic for a site with a Flex front end doesn't mean you can put Flex on your resume. So I skip right to the experience sections.

One resume says "Worked with CFQUERY, CFUPDATE, and CFSTORED PROC for database manipulation". What about CFSET and CFBEER? Yeah, we skipped that one. And yes, there's a space in cfstored proc, apparently. "Used CFTry CFCatch to trap errors..." more tags in the resume. Say that you wrote in explicit error handling, don't say how you did it.

"Wrote modules for header and footer templates and called them all over the site using CFInclude". Okay, for real, stop capitalizing tags like that. Including a header/footer is sooooo trivial. Reading this in the resume makes me think "they think that's impressive? buh bye"

How many years of experience do you say you have for each bit of technology? I worked on Oracle for 9 months, but haven't touched it in 3 years. I've been using CF primarily just to talk between Flex and SQL Server for two years, but have been using it in some fashion for almost 7 years.

The CONSTANT misspellings are killer. It's "ColdFusion", it hasn't been "Cold Fusion" since version 2 and was never "Coldfusion" nor "Cold fusion". 4 years ago I went through a contract house and my agent went through my resume highlighting things and messed up a lot of my technical terms like this. I'll blame those agent-types, but they need to stop, they're making their client look like they don't know what they're working with.

Another resume lists off a half dozen sites s/he** worked on, that's good. But they're all extranets that require login to do or see anything. Don't include links to those.

References to internal systems...? If I said on my resume "Streamlined interfaces to VIDS", would you hire me? Now if I say "Streamlined interfaces to company's internal chargeback and budgeting system", maybe.

DO NOT MENTION FRONT PAGE!!! If you're a real web developer, you don't use Front Page. You never used Front Page. You hate Front Page and are glad it's dead. You can't say "Front Page" without spitting on the ground. Do you design web applications in Word, too? Saying "Designed and developed user interfaces with Front Page" is like "Preformed brain surgery with Playskool's Little Doctor tools". Maybe you can remove the tumor, but imagine the gory mess you'll make.

Include a web site link to your example work. And if it's a locked down site, take screen shots of what you can. I was really impressed with one resume that included a link to the guy's site. But then I go to the site and it's basically a slide show of index pages of, I would guess, site's he's touched. I don't know, it's just the slide show. No other links or text.

*That was a typo, but it works, I'll keep it

**Only one of the 10 resumes here have Anglo-Saxon names. I can't pronounce them, much less know if it's male or female. Nothing at all against Indian developers, but I'm already imagining a strong language barrier.

Comparing two custom ActionScript classes

I have a custom employee class in my Flex that has name, badge number, phone number, etc, etc. In the form to update it, I want to only actually do to the database if the record was changed. The save function takes the existing record and the new record with changes and shoves it to ColdFusion, who generates an email with the before and after states.

I could have disabled the "save" button if the record isn't changed, only giving the user a "close" button. But there are a lot of fields on the form and more are being added in the future. I don't want some giant function that determines if the before and after employee objects are different, comparing one attribute at a time.

So I went to the kitchen cabinet and got some serial.

[More]

AS getters and setters, hope this doesn't make me a n00b

I swear I do Flex for a living. For 20 months now it's just Flex, Flex, and Flex. Yet it was just last week that I first used a setter function in an MXML component.

[More]

Flex howto: DataGrid sorting and labeling

First, the data going into my DataGrid. I have three objects

Discipline ... Employee ... Step

The Discipline object has an EmployeeID and StepID. Discipline also has EmployeeObject and StepObject, which are the full Employee and Step objects that match the IDs in the Discipline object. It's a lot simpler than it might sound.

[More]

Flex selectComboBox(), mkII

At the suggestion of a coworker, I've made a tiny change to my selectComboBox() function. The purpose of this function is to automatically select something in a ComboBox, such as if you're editing a form. But what if the function ends up doing nothing because no matches were found? Now it'll return false in that case. Also I properly capitalized it.

[More]

Flex modules == win

Those using FlexBuilder3 will have noticed a new option in File>New. MXML Module! They're badass. I tried to explain what a module is yesterday, and failed terribly. So I'll copy/paste from the livedocs...

LiveDocs link


Modules are SWF files that can be loaded and unloaded by an application. They cannot be run independently of an application, but any number of applications can share the modules.

Modules let you split your application into several pieces, or modules. The main application, or shell, can dynamically load other modules that it requires, when it needs them. It does not have to load all modules when it starts, nor does it have to load any modules if the user does not interact with them. When the application no longer needs a module, it can unload the module to free up memory and resources.

Modular applications have the following benefits:

  • Smaller initial download size of the SWF file.
  • Shorter load time due to smaller SWF file size.
  • Better encapsulation of related aspects of an application. For example, a "reporting" feature can be separated into a module that you can then work on independently.


Drop in a ModuleLoader. Search livedocs for the CustomModuleLoader component, it's nice

<mx:ModuleLoader id="modLoad"/>

Load a module into it. Pass this function the URL to the module's swf

private function switchApps(module:String):void{
   modLoad.url = module;   
}

Call a public function within the module. Note I type cast the loaded module here

private function treeClicked(evt:Event):void{
   (modLoad.child as disciplineModule).treeClicked(evt);
}

Benefit to using CFC Gateways with Flex, #127

If you follow the OO methodology of making a employee.cfc, employeeDAO.cfc, employeeGateway.cfc, and employee.as to interface with your employee database table, you're doing the right thing in Flex! But this leaves you with a ton of gateway CFCs, which will be a ton of RemoteObject tags in your mxml. So make a GenericGateway.cfc and only have Flex talk to that. Within this, make a function called employee_getAll, with the same return type as the getAll() function in your employeeGateway.cfc. As you need them, add more functions that call the corresponding functions in employeeGateway. Now you have a single RemoteObject tag, calling functions like employee_getAll, department_save, etc, very clear what it's affecting.

Bundled Flex requests

I have a Flex app that does a bunch of remoting calls to ColdFusion for data to populate some graphs. Even though the RemoteObject tags are in different components and get called separately by sequential lines of code, I noticed that they all returned at the same time, though I know some of them should have returned a lot faster. According to Service Capture, Flex 3 combines all the remoting calls into a single bundle. This makes me curious how Flex decides to combine the calls into a single bundle and more importantly, how do I tell Flex to NOT add a remoting call to a bundle.

Next game idea: Dungeonmancer

The other day at work, I was messing with drag and drop in Flex for the first time and was surprised at how easy it is. As always, my mind starting thinking "how can I make a game out of this?" And the answer was obvious: Make a dungeon!! I played Dungeon Maker: Hunting Ground for PSP a LOT. Way too long, far past when the game is interesting and fun and deep into the terrain of "this game sucks, but how does it end?"

[More]

More Entries

BlogCFC was created by Raymond Camden. This blog is running version 5.9.002. Contact Blog Owner