 
   lockDefaultCode: (force=false) ->
     # TODO: Lock default indent for an empty line?
-    return unless @options.level.get('lockDefaultCode')
+    if me.level() > @max_expected_player_levels[@options.level.get 'name'] or @options.level.get('lockDefaultCode') is false
+      return
     return unless @spell.source is @spell.originalSource or force
 
     console.info 'Locking down default code.'


  events:
    'mouseout': 'onMouseOut'

  constructor: (options) ->
    super options

      name: 'disable-spaces'
      bindKey: 'Space'
      exec: =>
        if me.level() > @max_expected_player_levels[@options.level.get 'name'] or @options.level.get('disableSpaces') is false
          return @ace.execCommand 'insertstring', ' '
        line = @aceDoc.getLine @ace.getCursorPosition().row
        return @ace.execCommand 'insertstring', ' ' if @singleLineCommentRegex().test line

