mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-23 23:58:02 -05:00
Merge branch 'master' of https://github.com/codecombat/codecombat
This commit is contained in:
commit
d48f5256a7
5 changed files with 34 additions and 25 deletions
|
@ -67,8 +67,10 @@ module.exports = class CoordinateDisplay extends createjs.Container
|
|||
radius = 2.5
|
||||
width = @label.getMeasuredWidth() + 2 * margin
|
||||
height = @label.getMeasuredHeight() + 2 * margin
|
||||
@label.regX = @background.regX = width / 2 - margin
|
||||
@label.regY = @background.regY = height / 2 - margin
|
||||
@label.regX = @background.regX = width / 2
|
||||
@label.regY = @background.regY = height / 2
|
||||
@label.regX -= margin
|
||||
@label.regY -= margin
|
||||
@background.graphics
|
||||
.clear()
|
||||
.beginFill('rgba(0,0,0,0.4)')
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
module.exports = nativeDescription: "ไทย", englishDescription: "Thai", translation:
|
||||
common:
|
||||
loading: "รอสักครู่..."
|
||||
# saving: "Saving..."
|
||||
saving: "กำลังบันทึก..."
|
||||
# sending: "Sending..."
|
||||
# send: "Send"
|
||||
cancel: "ยกเลิก"
|
||||
# save: "Save"
|
||||
save: "บันทึก"
|
||||
# publish: "Publish"
|
||||
# create: "Create"
|
||||
delay_1_sec: "1 วินาที"
|
||||
|
@ -19,21 +19,21 @@ module.exports = nativeDescription: "ไทย", englishDescription: "Thai", tra
|
|||
# unwatch: "Unwatch"
|
||||
# submit_patch: "Submit Patch"
|
||||
|
||||
# units:
|
||||
# second: "second"
|
||||
# seconds: "seconds"
|
||||
# minute: "minute"
|
||||
# minutes: "minutes"
|
||||
# hour: "hour"
|
||||
# hours: "hours"
|
||||
# day: "day"
|
||||
# days: "days"
|
||||
# week: "week"
|
||||
# weeks: "weeks"
|
||||
# month: "month"
|
||||
# months: "months"
|
||||
# year: "year"
|
||||
# years: "years"
|
||||
units:
|
||||
second: "วินาที"
|
||||
seconds: "วินาที"
|
||||
minute: "นาที"
|
||||
minutes: "นาที"
|
||||
hour: "ชั่วโมง"
|
||||
hours: "ชั่วโมง"
|
||||
day: "วัน"
|
||||
days: "วัน"
|
||||
week: "สัปดาห์"
|
||||
weeks: "สัปดาห์"
|
||||
month: "เดือน"
|
||||
months: "เดือน"
|
||||
year: "ปี"
|
||||
years: "ปี"
|
||||
|
||||
modal:
|
||||
close: "ปิด"
|
||||
|
@ -69,8 +69,8 @@ module.exports = nativeDescription: "ไทย", englishDescription: "Thai", tra
|
|||
login:
|
||||
sign_up: "ลงทะเบียนใหม่"
|
||||
log_in: "ลงชื่อเข้าใช้"
|
||||
# logging_in: "Logging In"
|
||||
log_out: "ลงชื่ื่อออก"
|
||||
logging_in: "กำลังเข้าสู่ระบบ"
|
||||
log_out: "ลงชื่อออก"
|
||||
recover: "กู้บัญชีการใช้งาน"
|
||||
|
||||
# recover:
|
||||
|
@ -78,12 +78,12 @@ module.exports = nativeDescription: "ไทย", englishDescription: "Thai", tra
|
|||
# send_password: "Send Recovery Password"
|
||||
|
||||
signup:
|
||||
# create_account_title: "Create Account to Save Progress"
|
||||
create_account_title: "สร้างบัญชีใหม่เพื่อบันทึกความก้าวหน้า"
|
||||
# description: "It's free. Just need a couple things and you'll be good to go:"
|
||||
email_announcements: "รับข่าวสารผ่านทางอีเมลล์"
|
||||
# coppa: "13+ or non-USA "
|
||||
coppa_why: "(ทำไม?)"
|
||||
# creating: "Creating Account..."
|
||||
creating: "กำลังสร้างบัญชีใหม่..."
|
||||
sign_up: "สมัคร"
|
||||
log_in: "เข้าสู่ระบบด้วยรหัสผ่าน"
|
||||
# social_signup: "Or, you can sign up through Facebook or G+:"
|
||||
|
|
|
@ -237,7 +237,7 @@ class CocoModel extends Backbone.Model
|
|||
data ?= $.extend true, {}, @attributes
|
||||
schema ?= @schema() or {}
|
||||
if schema.properties?.i18n and _.isPlainObject(data) and not data.i18n?
|
||||
data.i18n = {}
|
||||
data.i18n = {'-':'-'} # mongoose doesn't work with empty objects
|
||||
sum += 1
|
||||
|
||||
if _.isPlainObject data
|
||||
|
|
|
@ -248,7 +248,14 @@ class JavaScriptTreema extends CodeTreema
|
|||
|
||||
class InternationalizationNode extends TreemaNode.nodeMap.object
|
||||
findLanguageName: (languageCode) ->
|
||||
# to get around mongoose emtpy object bug, there's a prop in the object which needs to be ignored
|
||||
return '' if languageCode is '-'
|
||||
locale[languageCode]?.nativeDescription or "#{languageCode} Not Found"
|
||||
|
||||
getChildren: ->
|
||||
res = super(arguments...)
|
||||
res = (r for r in res when r[0] isnt '-')
|
||||
res
|
||||
|
||||
getChildSchema: (key) ->
|
||||
#construct the child schema here
|
||||
|
|
|
@ -46,7 +46,7 @@ db.users.find({anonymous:false}, params).sort({_id:1}).forEach(function (user) {
|
|||
}
|
||||
update.slug = slug;
|
||||
slugs[slug] = user.name;
|
||||
if(user.slug) return;
|
||||
if(user.slug === slug) return;
|
||||
print(_.str.sprintf('Setting user %s (%s) to slug %s with update %s', user.name, user.dateCreated, slug, JSON.stringify({$set:update})));
|
||||
var res = db.users.update({_id:user._id}, {$set:update});
|
||||
if(res.hasWriteError()) {
|
||||
|
|
Loading…
Reference in a new issue