This commit is contained in:
Scott Erickson 2014-04-03 18:43:36 -07:00
commit 978c84bc89
11 changed files with 170 additions and 54 deletions

View file

@ -38,7 +38,7 @@ module.exports = class Thang
publishNote: (channel, event) ->
event.thang = @
@world.publishNote channel, event
setGoalState: (goalID, status) ->
@world.setGoalState goalID, status

View file

@ -98,10 +98,14 @@ module.exports = class ThangState
storage = @trackedPropertyValues[propIndex]
value = @getStoredProp propIndex, type, storage
if prop is "pos"
@thang.pos = @thang.pos.copy()
@thang.pos.x = inverse * @thang.pos.x + ratio * value.x
@thang.pos.y = inverse * @thang.pos.y + ratio * value.y
@thang.pos.z = inverse * @thang.pos.z + ratio * value.z
if @thang.pos.distanceSquared(value) > 900
# Don't interpolate; it was probably a teleport. https://github.com/codecombat/codecombat/issues/738
@thang.pos = value
else
@thang.pos = @thang.pos.copy()
@thang.pos.x = inverse * @thang.pos.x + ratio * value.x
@thang.pos.y = inverse * @thang.pos.y + ratio * value.y
@thang.pos.z = inverse * @thang.pos.z + ratio * value.z
else if prop is "rotation"
@thang.rotation = inverse * @thang.rotation + ratio * value
@thang.partialState = true

View file

@ -5,7 +5,7 @@ module.exports = nativeDescription: "español (ES)", englishDescription: "Spanis
sending: "Enviando..."
cancel: "Cancelar"
save: "Guardar"
# create: "Create"
create: "Crear"
delay_1_sec: "1 segundo"
delay_3_sec: "3 segundos"
delay_5_sec: "5 segundos"
@ -13,13 +13,13 @@ module.exports = nativeDescription: "español (ES)", englishDescription: "Spanis
fork: "Bifurcar"
play: "Jugar"
# units:
# second: "second"
# seconds: "seconds"
# minute: "minute"
# minutes: "minutes"
# hour: "hour"
# hours: "hours"
units:
second: "segundo"
seconds: "segundos"
minute: "minuto"
minutes: "minutos"
hour: "hora"
hours: "horas"
modal:
close: "Cerrar"
@ -53,7 +53,7 @@ module.exports = nativeDescription: "español (ES)", englishDescription: "Spanis
login:
sign_up: "Crear una cuenta"
log_in: "Entrar"
# logging_in: "Logging In"
logging_in: "Entrando..."
log_out: "Salir"
recover: "recuperar cuenta"
@ -76,12 +76,12 @@ module.exports = nativeDescription: "español (ES)", englishDescription: "Spanis
no_ie: "CodeCombat no funciona en Internet Explorer 9 o anteriores. ¡Lo sentimos!"
no_mobile: "¡CodeCombat no fue diseñado para dispositivos móviles y puede que no funcione!"
play: "Jugar"
# old_browser: "Uh oh, your browser is too old to run CodeCombat. Sorry!"
# old_browser_suffix: "You can try anyway, but it probably won't work."
# campaign: "Campaign"
# for_beginners: "For Beginners"
# multiplayer: "Multiplayer"
# for_developers: "For Developers"
old_browser: "Ay, su navegador es demasiado viejo para ejecutar CodeCombat. ¡Lo sentimos!"
old_browser_suffix: "Puede tentar de todos modos, pero probablemente no va a funcionar."
campaign: "Campaña"
for_beginners: "Para principiantes"
multiplayer: "Multijugador"
for_developers: "Para programadores"
play:
choose_your_level: "Elige tu nivel"

View file

@ -5,7 +5,7 @@ module.exports = nativeDescription: "limba română", englishDescription: "Roman
sending: "Se trimite..."
cancel: "Anulează"
save: "Salvează"
# create: "Create"
create: "Crează"
delay_1_sec: "1 secundă"
delay_3_sec: "3 secunde"
delay_5_sec: "5 secunde"
@ -13,13 +13,13 @@ module.exports = nativeDescription: "limba română", englishDescription: "Roman
fork: "Fork"
play: "Joacă"
# units:
# second: "second"
# seconds: "seconds"
# minute: "minute"
# minutes: "minutes"
# hour: "hour"
# hours: "hours"
units:
second: "secundă"
seconds: "secunde"
minute: "minut"
minutes: "minute"
hour: "oră"
hours: "ore"
modal:
close: "Inchide"
@ -53,7 +53,7 @@ module.exports = nativeDescription: "limba română", englishDescription: "Roman
login:
sign_up: "Crează cont"
log_in: "Log In"
# logging_in: "Logging In"
logging_in: "Se conectează"
log_out: "Log Out"
recover: "recuperează cont"
@ -226,8 +226,8 @@ module.exports = nativeDescription: "limba română", englishDescription: "Roman
skip_tutorial: "Sari peste (esc)"
editor_config: "Editor Config"
editor_config_title: "Configurare Editor"
# editor_config_language_label: "Programming Language"
# editor_config_language_description: "Define the programming language you want to code in."
editor_config_language_label: "Limbaj de Programare"
editor_config_language_description: "Definește limbajul de programare în care vrei să codezi."
editor_config_keybindings_label: "Mapare taste"
editor_config_keybindings_default: "Default (Ace)"
editor_config_keybindings_description: "Adaugă comenzi rapide suplimentare cunoscute din editoarele obisnuite."
@ -246,17 +246,17 @@ module.exports = nativeDescription: "limba română", englishDescription: "Roman
tip_beta_launch: "CodeCombat a fost lansat beta in Octombrie 2013."
tip_js_beginning: "JavaScript este doar începutul."
tip_autocast_setting: "Ajutează setările de autocast apăsând pe rotița de pe buton."
# think_solution: "Think of the solution, not the problem."
# tip_theory_practice: "In theory, there is no difference between theory and practice. But in practice, there is. - Yogi Berra"
# tip_error_free: "There are two ways to write error-free programs; only the third one works. - Alan Perlis"
# tip_debugging_program: "If debugging is the process of removing bugs, then programming must be the process of putting them in. - Edsger W. Dijkstra"
# tip_forums: "Head over to the forums and tell us what you think!"
think_solution: "Gândește-te la soluție, nu la problemă."
tip_theory_practice: "Teoretic nu este nici o diferență înte teorie și practică. Dar practic este. - Yogi Berra"
tip_error_free: "Există doar două metode de a scrie un program fără erori; numai a treia funcționează. - Alan Perlis"
tip_debugging_program: "Dacă a face debuggin este procesul de a scoate bug-uri, atunci a programa este procesul de a introduce bug-uri. - Edsger W. Dijkstra"
tip_forums: "Intră pe forum și spune-ți părerea!"
tip_baby_coders: "În vitor până și bebelușii vor fi Archmage."
tip_morale_improves: "Se va încărca până până când va crește moralul."
tip_all_species: "Noi credem în șanse egale de a învăța programare pentru toate speciile."
# tip_reticulating: "Reticulating spines."
tip_reticulating: "Reticulating spines."
tip_harry: "Ha un Wizard, "
# tip_great_responsibility: "With great coding skill comes great debug responsibility."
tip_great_responsibility: "With great coding skill comes great debug responsibility."
# tip_munchkin: "If you don't eat your vegetables, a munchkin will come after you while you're asleep."
# tip_binary: "There are only 10 types of people in the world: those who understand binary, and those who don't."
# tip_commitment_yoda: "A programmer must have the deepest commitment, the most serious mind. ~ Yoda"
@ -587,16 +587,16 @@ module.exports = nativeDescription: "limba română", englishDescription: "Roman
warmup: "Încălzire"
vs: "VS"
# multiplayer_launch:
# introducing_dungeon_arena: "Introducing Dungeon Arena"
# new_way: "The new way to compete with code."
# to_battle: "To Battle, Developers!"
# modern_day_sorcerer: "You know how to code? That's badass. You're a modern-day sorcerer! Isn't about time that you used your magic coding powers to command your minions in epic combat? And we're not talking robots here."
# arenas_are_here: "CodeCombat head-to-head multiplayer arenas are here."
# ladder_explanation: "Choose your heroes, enchant your human or ogre armies, and climb your way over defeated fellow Wizards to reach the top of the laddersthen challenge your friends in our glorious, asynchronous multiplayer coding arenas. If you're feeling creative, you can even"
# fork_our_arenas: "fork our arenas"
# create_worlds: "and create your own worlds."
# javascript_rusty: "JavaScript a bit rusty? Don't worry; there's a"
# tutorial: "tutorial"
# new_to_programming: ". New to programming? Hit our beginner campaign to skill up."
# so_ready: "I Am So Ready for This"
multiplayer_launch:
introducing_dungeon_arena: "Prezentăm Dungeon Arena"
new_way: "Noul mod de a concura prin linii de cod."
to_battle: "La luptă, Developers!"
modern_day_sorcerer: "Știi să programezie? Tare. Ești un vrăjitor al noii ere! Nu crezi ca este timpul să îți folosești puterile de programare pentru a conduce în lupte epice minionii tăi? Și nu vorbim despre roboți aici."
arenas_are_here: "Arenele CodeCombat multiplayer 1v1 sunt aici."
ladder_explanation: "Alegeți eroii,vrăjește armatele de orci sau oameni, și croiește-ți drumul luptând și învingând alți Vrăjitori pentru a ajunge în topul clasamentului. Dacă te simți creativ poți chiar să"
fork_our_arenas: "să dai fork la arenele noastre"
create_worlds: "și să îți creezi propriile lumi."
javascript_rusty: "N-ai mai pus mâna pe JavaScript? Nicio problemă; există un"
tutorial: "tutorial"
new_to_programming: ". Nou in tainele programării? Încearcă campania de începători pentru ați dezolvata abilitățile."
so_ready: "Sunt atât de pregătit pentru asta!"

View file

@ -218,3 +218,18 @@ body[lang='ru'], body[lang|='zh'], body[lang='ja'], body[lang='pl'], body[lang='
text-transform: uppercase
letter-spacing: -1px !important
@media only screen and (max-width: 800px)
.main-content-area
width: 100%
.content
width: 100%
.footer-link-text a
font-size: 17px
margin-left: 3px
margin-right: 3px
.share-buttons
margin-bottom: 20px
.partner-badges
display: none

View file

@ -95,3 +95,33 @@
li
color: #ebebeb
padding: 8px 20px
#mobile-nav
display: none
@media only screen and (max-width: 800px)
#top-nav
display: none
#mobile-nav
display: inline
a.navbar-brand
padding: 4px 20px 0px 20px
button.navbar-toggle
background: #483a2d
border: 2px solid #2f261d
span.icon-bar
background: #F9E612
ul li
font-family: 'Bangers', cursive
font-weight: normal
color: #fff
font-size: 25px
margin-top: 5px
margin-bottom: 5px
.header-font
color: #fff
.footer-link-text
width: 100%
display: ineline

View file

@ -92,3 +92,38 @@
width: 660px
height: 382px
pointer-events: none
#mobile-trailer-wrapper
display: none
@media only screen and (max-width: 800px)
#home-view
#site-slogan
font-size: 30px
#trailer-wrapper
display: none
#mobile-trailer-wrapper
display: inline-block
width: 100%
iframe
display: block
margin: 0 auto
.game-mode-wrapper
width: 100%
img
width: 100%
.play-text
position: absolute
right: 45px
bottom: 0px
color: $yellow
font-size: 50px
font-family: Bangers
@include transition(color .10s linear)
h1
text-align: center
margin-top: 0

View file

@ -70,3 +70,8 @@
#must-log-in button
margin-right: 10px
@media only screen and (max-width: 800px)
#ladder-view
#level-column img
width: 100%

View file

@ -1,6 +1,28 @@
body
#fb-root
block header
.nav.navbar.navbar-fixed-top#mobile-nav
.content.clearfix
.navbar-header
button.navbar-toggle(type="button" data-toggle="collapse" data-target="#collapsible-navbar")
span.sr-only Toggle navigation
span.icon-bar
span.icon-bar
span.icon-bar
a.navbar-brand(href='/')
img(src="/images/pages/base/logo.png", title="CodeCombat - Learn how to code by playing a game", alt="CodeCombat")
.collapse.navbar-collapse#collapsible-navbar
ul.nav.navbar-nav
li.play
a.header-font(href='/play', data-i18n="nav.play") Levels
li.editor
a.header-font(href='/editor', data-i18n="nav.editor") Editor
li.blog
a.header-font(href='http://blog.codecombat.com/', data-i18n="nav.blog") Blog
li.forum
a.header-font(href='http://discourse.codecombat.com/', data-i18n="nav.forum") Forum
.nav.navbar.navbar-fixed-top#top-nav
.content.clearfix
.navbar-header
@ -32,6 +54,10 @@ body
if me.isAdmin()
li.admin
a.header-font(href='/admin', data-i18n="nav.admin") Admin
block outer_content
#outer-content-wrapper

View file

@ -7,7 +7,8 @@ block content
#trailer-wrapper
<iframe width="920" height="518" src="//www.youtube.com/embed/1zjaA13k-dA?rel=0&controls=0&modestbranding=1&showinfo=0&iv_load_policy=3&vq=hd720&wmode=transparent" frameborder="0" wmode="opaque" allowfullscreen></iframe>
img(src="/images/pages/home/video_border.png")
#mobile-trailer-wrapper
<iframe src="//www.youtube.com/embed/1zjaA13k-dA" frameborder="0" width="280" height="158"></iframe>
hr
.alert.alert-danger.lt-ie10
@ -21,7 +22,7 @@ block content
strong(data-i18n="home.old_browser") Uh oh, your browser is too old to run CodeCombat. Sorry!
br
span(data-i18n="home.old_browser_suffix") You can try anyway, but it probably won't work.
a#beginner-campaign(href="/play/level/rescue-mission")
div.game-mode-wrapper
if isEnglish

View file

@ -78,7 +78,7 @@ module.exports = class VictoryModal extends View
c = super()
c.body = @body
c.me = me
c.hasNextLevel = _.isObject(@level.get('nextLevel')) and (@level.get('name') isnt "Mobile Artillery")
c.hasNextLevel = _.isObject(@level.get('nextLevel'))
c.levelName = utils.i18n @level.attributes, 'name'
c.level = @level
if c.level.get('type') is 'ladder'