         @visualFrameRate = 17
     @currentGame.finishGame() if @currentGame
 
-    gamediv = $(@UIcont)
+    gamediv = $(root.UIcont)
     gamediv.empty()
     #Todo FADE IN
 

"use strict"
# things assigned to root will be available outside this module
root = exports ? this.codeland = {}
@UIcont = null

root.initialize = (@UIcont) ->
    player = root.getPlayer()
    root.drawGameMap(player)


 # FRONTEND UI
root.drawGameMap = (player) ->
    descriptions = root.getGameDescriptions()
    mapDiv = $(root.UIcont)
    mapDiv.empty()
    gameSequence = root.getGameSequence()
    sel = new gameSelector(mapDiv,false)
