Keeping Model State in Components

Here’s a problem that occurs often in UI development; You have a model and you want to do changes that can be ‘cancelled’ or reverted back to it’s original. You don’t want to modify the model directly because those are normally the values that the server gives you and you wouldn’t want to be off-sync with the server if you’re doing polling or pushing data retrieval.

What’s the solution? Since it’s the actual components doing a change, you want them to keep state because the components know when to update or reset. How you implement this solution is up to you, but here’s a utility that might help; ObjectUtil.

Read more…



Dabbling in Papervision

A few months ago, I was approached by the president of the company I’m currently working for.

He needed a game; more precisely, one of our clients needed a game.  The president approached me for two reasons:  I’m the flash guru in this joint and he knew I wanted to work in games.  We sat down with the client and talked more about the game, how it’ll play and more importantly, how it’ll look.

Without a doubt, I pitched the idea that we use Papervision 3D to render the game.  It’ll add the extra wow factor to the project when combining it with a proper 2D physics engine to create something that should look and feel like the real thing.  After showing a few examples of what Papervision 3D can do, they were both sold that we should use this technology.  Only problem was, I never used it before and I needed to learn it quickly to get a working prototype up.

Read more…