mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-28 01:55:38 -05:00
Merge branch 'master' of https://github.com/codecombat/codecombat
This commit is contained in:
commit
d3111f545d
3 changed files with 7 additions and 6 deletions
|
@ -28,8 +28,11 @@
|
|||
if playableTeams.length > 1
|
||||
#multiplayer-team-selection
|
||||
for team in playableTeams
|
||||
label(for="multiplayer_team_"+team)= team
|
||||
input(id="multiplayer_team_"+team, type="radio", name="multiplayer", value=team)
|
||||
h4
|
||||
if team == me.team
|
||||
em= "Playing as " + team
|
||||
else
|
||||
a(href=joinLink + "&skip_protect_api=true&team=" + team)= "Play as " + team
|
||||
|
||||
.modal-footer
|
||||
a(href='#', data-dismiss="modal", aria-hidden="true", data-i18n="modal.close").btn.btn-primary Close
|
||||
|
|
|
@ -28,9 +28,6 @@ module.exports = class MultiplayerModal extends View
|
|||
afterRender: ->
|
||||
super()
|
||||
@updateLinkSection()
|
||||
@$el.find('#multiplayer-team-selection input')
|
||||
.prop('checked', -> $(@).val() is me.team)
|
||||
.bind('change', -> Backbone.Mediator.publish 'level:set-team', team: $(@).val())
|
||||
|
||||
onClickLink: (e) ->
|
||||
e.target.select()
|
||||
|
|
|
@ -123,7 +123,8 @@ module.exports = class PlayLevelView extends View
|
|||
@levelLoader.destroy()
|
||||
@levelLoader = null
|
||||
@loadingScreen.destroy()
|
||||
@setTeam @world.teamForPlayer _.size @session.get 'players' # TODO: players aren't initialized yet?
|
||||
#@setTeam @world.teamForPlayer _.size @session.get 'players' # TODO: players aren't initialized yet?
|
||||
@setTeam @getQueryVariable("team") ? @world.teamForPlayer(0)
|
||||
@initSurface()
|
||||
@initGod()
|
||||
@initGoalManager()
|
||||
|
|
Loading…
Reference in a new issue