mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-12-01 11:27:14 -05:00
Merge branch 'master' into production
This commit is contained in:
commit
2f1ed2f8b9
6 changed files with 25 additions and 10 deletions
|
@ -313,7 +313,7 @@ $itemSlotGridHeight: 70px
|
||||||
padding: 9px 0 9px 9px
|
padding: 9px 0 9px 9px
|
||||||
|
|
||||||
#double-click-hint
|
#double-click-hint
|
||||||
margin: 20px 0 70px
|
margin: 20px 50px 70px 0
|
||||||
|
|
||||||
h4
|
h4
|
||||||
clear: both
|
clear: both
|
||||||
|
|
|
@ -71,7 +71,7 @@
|
||||||
strong
|
strong
|
||||||
color: rgb(50,50,30)
|
color: rgb(50,50,30)
|
||||||
|
|
||||||
#selected-item-unlock-button
|
#selected-item-unlock-button, .unequippable
|
||||||
left: 856px
|
left: 856px
|
||||||
top: 594px
|
top: 594px
|
||||||
width: 337px
|
width: 337px
|
||||||
|
@ -80,3 +80,7 @@
|
||||||
|
|
||||||
img
|
img
|
||||||
height: 16px
|
height: 16px
|
||||||
|
|
||||||
|
.unequippable
|
||||||
|
position: absolute
|
||||||
|
|
||||||
|
|
|
@ -33,9 +33,14 @@
|
||||||
p Only admins will see it for now.
|
p Only admins will see it for now.
|
||||||
|
|
||||||
if item && !item.owned
|
if item && !item.owned
|
||||||
|
if item.equippable
|
||||||
button#selected-item-unlock-button.btn.big-font.unlock-button(disabled=!item.affordable, data-item-id=item.id)
|
button#selected-item-unlock-button.btn.big-font.unlock-button(disabled=!item.affordable, data-item-id=item.id)
|
||||||
span(data-i18n="play.unlock") Unlock
|
span(data-i18n="play.unlock") Unlock
|
||||||
span.spl= '('+item.get('gems')
|
span.spl= '('+item.get('gems')
|
||||||
img(src="/images/common/gem.png")
|
img(src="/images/common/gem.png")
|
||||||
span )
|
span )
|
||||||
|
else
|
||||||
|
// Temp, while we only have Warriors: prevent them from buying non-Warrior stuff
|
||||||
|
button.btn.big-font.disabled.unequippable #{item.get('heroClass')} Only
|
||||||
|
|
||||||
|
|
|
@ -422,7 +422,7 @@ module.exports = class InventoryModal extends ModalView
|
||||||
@toggleFullscreen()
|
@toggleFullscreen()
|
||||||
hasGoneFullScreenOnce = true
|
hasGoneFullScreenOnce = true
|
||||||
@updateConfig =>
|
@updateConfig =>
|
||||||
@trigger 'play-click'
|
@trigger? 'play-click'
|
||||||
window.tracker?.trackEvent 'Play Level Modal', Action: 'Play'
|
window.tracker?.trackEvent 'Play Level Modal', Action: 'Play'
|
||||||
|
|
||||||
updateConfig: (callback, skipSessionSave) ->
|
updateConfig: (callback, skipSessionSave) ->
|
||||||
|
|
|
@ -361,7 +361,7 @@ dungeon = [
|
||||||
y: 14
|
y: 14
|
||||||
nextLevels:
|
nextLevels:
|
||||||
#more_practice: 'crawlways-of-kithgard'
|
#more_practice: 'crawlways-of-kithgard'
|
||||||
continue: 'true-names'
|
continue: 'forgetful-gemsmith'
|
||||||
practice: true
|
practice: true
|
||||||
}
|
}
|
||||||
#{
|
#{
|
||||||
|
@ -385,7 +385,7 @@ dungeon = [
|
||||||
x: 63
|
x: 63
|
||||||
y: 13
|
y: 13
|
||||||
nextLevels:
|
nextLevels:
|
||||||
continue: 'shadow-guard'
|
continue: 'true-names'
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name: 'True Names'
|
name: 'True Names'
|
||||||
|
|
|
@ -106,6 +106,7 @@ module.exports = class SpellView extends CocoView
|
||||||
@toggleControls null, @writable
|
@toggleControls null, @writable
|
||||||
@aceSession.selection.on 'changeCursor', @onCursorActivity
|
@aceSession.selection.on 'changeCursor', @onCursorActivity
|
||||||
$(@ace.container).find('.ace_gutter').on 'click mouseenter', '.ace_error, .ace_warning, .ace_info', @onAnnotationClick
|
$(@ace.container).find('.ace_gutter').on 'click mouseenter', '.ace_error, .ace_warning, .ace_info', @onAnnotationClick
|
||||||
|
$(@ace.container).find('.ace_gutter').on 'click', @onGutterClick
|
||||||
@initAutocomplete aceConfig.liveCompletion ? true
|
@initAutocomplete aceConfig.liveCompletion ? true
|
||||||
|
|
||||||
createACEShortcuts: ->
|
createACEShortcuts: ->
|
||||||
|
@ -392,6 +393,7 @@ module.exports = class SpellView extends CocoView
|
||||||
return unless e.spell is @spell
|
return unless e.spell is @spell
|
||||||
@reloadCode true
|
@reloadCode true
|
||||||
@ace.clearSelection()
|
@ace.clearSelection()
|
||||||
|
_.delay (=> @ace?.clearSelection()), 500 # Make double sure this gets done (saw some timing issues?)
|
||||||
|
|
||||||
reloadCode: (cast=true) ->
|
reloadCode: (cast=true) ->
|
||||||
@updateACEText @spell.originalSource
|
@updateACEText @spell.originalSource
|
||||||
|
@ -795,6 +797,9 @@ module.exports = class SpellView extends CocoView
|
||||||
# @ is the gutter element
|
# @ is the gutter element
|
||||||
Backbone.Mediator.publish 'tome:jiggle-problem-alert', {}
|
Backbone.Mediator.publish 'tome:jiggle-problem-alert', {}
|
||||||
|
|
||||||
|
onGutterClick: =>
|
||||||
|
@ace.clearSelection()
|
||||||
|
|
||||||
onDisableControls: (e) -> @toggleControls e, false
|
onDisableControls: (e) -> @toggleControls e, false
|
||||||
onEnableControls: (e) -> @toggleControls e, @writable
|
onEnableControls: (e) -> @toggleControls e, @writable
|
||||||
toggleControls: (e, enabled) ->
|
toggleControls: (e, enabled) ->
|
||||||
|
@ -881,6 +886,7 @@ module.exports = class SpellView extends CocoView
|
||||||
|
|
||||||
destroy: ->
|
destroy: ->
|
||||||
$(@ace?.container).find('.ace_gutter').off 'click', '.ace_error, .ace_warning, .ace_info', @onAnnotationClick
|
$(@ace?.container).find('.ace_gutter').off 'click', '.ace_error, .ace_warning, .ace_info', @onAnnotationClick
|
||||||
|
$(@ace?.container).find('.ace_gutter').off 'click', @onGutterClick
|
||||||
@firepad?.dispose()
|
@firepad?.dispose()
|
||||||
@ace?.commands.removeCommand command for command in @aceCommands
|
@ace?.commands.removeCommand command for command in @aceCommands
|
||||||
@ace?.destroy()
|
@ace?.destroy()
|
||||||
|
|
Loading…
Reference in a new issue