     state.initialized = true
     that = @
     
-    # we want to be certain that 'done' is only called once
-    asyncDone = false
     done = () ->
-      return if asyncDone
       state.isReady = asyncDone = true
       that.events.trigger "state:ready"
+      
+    state.init.call(state, if state.async then done else null)
     
-    state.init.call(state, done)
     # synchronous version
-    done() unless asyncDone
+    done() if not state.async
+    
     
     
   "step": (params...) ->

      @events.trigger "state:init"
      
    if state.isReady
      @events.trigger "state:enter"
  else
    console.warn "A GameState with a name of '#{name}' doesn't exist yet"
  return @

# The state object, created with StateManager::add
#
State = (aghs, @state, options = {}) ->
  @name = options.name
  @isReady = if options.isReady then options.isReady else false
  @async = false
  config = {
    "fullscreen": options.fullscreen
    "width":      options.width
