diff --git a/game/begin.coffee b/game/begin.coffee index 3c13543..5d678f1 100644 --- a/game/begin.coffee +++ b/game/begin.coffee @@ -116,7 +116,7 @@ updateverb = (unit, verb) -> pruneVerbs = () -> for verb in document.querySelectorAll(".verb") - text = verb.innerHTML.toLowerCase() + text = $(verb).data("verb") if $("##{text}list").html() == "" verb.style.cssText = "visibility: hidden" else @@ -187,9 +187,9 @@ croom = (name, spec) -> sysroom "inventory", text: () -> if salet.character.inventory.length == 0 - text = "You are carrying nothing." + text = "inventory_empty".l() else - text = "You are carrying:\n\n" + text = "inventory_contains".l()+"\n\n" for thing in salet.character.inventory text += "* #{salet.character.listinv(thing.name)}\n" diff --git a/game/story.coffee b/game/story.coffee index b814c7c..f17e5cb 100644 --- a/game/story.coffee +++ b/game/story.coffee @@ -22,6 +22,7 @@ cloak = unit "cloak", salet.character.drop('cloak') salet.here().take(cloak) return "hang_cloak".l() + invl: () -> "cloak_invl".l() wear: () -> if (salet.here().has('cloak')) cloak = null @@ -68,16 +69,18 @@ hook = unit "hook", list = "" for thing in salet.here().units if thing.name == "cloak" - list += "a " + thing.display().toLowerCase() - return "hook".l() + " " + "hook_full".l({ + list += thing.invl() + return "hook".l() + "hook_full".l({ "list": list }) else - return "hook".l() + " " + "hook_empty".l() + return "hook".l() + "hook_empty".l() hook.put("cloakroom") croom "entrance", title: () -> "entrance_title".l() + ways: ["foyer"] + dsc: () -> "entrance".l() croom "bar", before: () -> @@ -97,7 +100,12 @@ croom "bar", wear: () -> "wear_darkness".l() ] + this.actions = {} else + this.actions = { + message: () -> + salet.view.write salet.here().units[0].act() + } this.dsc = "bar".l() this.units = [ unit "message", @@ -112,13 +120,7 @@ croom "bar", else return "message_ruined".l() examine: () -> - $(".sidebar").hide() - $("#content").toggleClass("narrow") - $(".ways").hide() - if salet.here().chaos == 0 - return "message_x".l() - else - return "message_ruined".l() + salet.here().units[0].act() ] return "" title: () -> "bar_title".l() diff --git a/game/translations/en.cson b/game/translations/en.cson index 04f35e0..2d1dbcc 100644 --- a/game/translations/en.cson +++ b/game/translations/en.cson @@ -44,7 +44,7 @@ bar: """ """ message_disp: "Message" message: """ - There seems to be some sort of {{message}} scrawled in the sawdust on the floor. + There seems to be some sort of [message](./message) scrawled in the sawdust on the floor. """ message_x: """ The message, neatly marked in the sawdust, reads... @@ -62,10 +62,11 @@ cloak: """ Its blackness is so deep that it almost seems to suck light from the room. """ cloak_disp: "Cloak" +cloak_invl: "a cloak" hook: "It's just a small brass hook," hook_disp: "Small hook" -hook_empty: "screwed to the wall." -hook_full: "with {list} hanging on it." +hook_empty: " screwed to the wall." +hook_full: " with {list} hanging on it." bar_dark: "The room completely submerged in darkness." darkness: "Darkness" wear_darkness: "You are already wearing it, in a way." @@ -76,4 +77,8 @@ wear_cloak: "You take the cloak from the hook and wear it." take_cloak: "You take the cloak from the hook." night: "Night mode" multiplayer: "Multiplayer mode" -showall: "Filter list of objects" +entrance: """ + Oops. How did you get here? Are you a wizard or something? +""" +inventory_empty: "You are carrying nothing." +inventory_contains: "You are carrying:" diff --git a/game/translations/ru.cson b/game/translations/ru.cson index 7aa3a19..b21d776 100644 --- a/game/translations/ru.cson +++ b/game/translations/ru.cson @@ -1,19 +1,19 @@ -foyer_title: "Foyer of the Opera House" +foyer_title: "Фойе Оперного Театра" start: """ - Hurrying through the rainswept November night, you're glad to see the bright - lights of the Opera House. - It's surprising that there aren't more people about but, hey, what do you - expect in a cheap demo game...? + Торопливо пробираясь сквозь дождливую и холодную ноябрьскую ночь, + Вы радостно заметили неподалеку ярко горящие огни Оперного театра. + Конечно, очень странно, что рядом не заметно ни одной живой души... + но стоит ли ждать слишком много от простенькой демонстрационной игры?.. ### Плащ Тьмы #### Базовая демонстрация IF - ##### Roger Firth, пер. Андрея Гранкина, версия на Salet - Александр Яковлев + ##### Roger Firth, версия на Salet - Александр Яковлев """ foyer: """ - You are standing in a spacious hall, splendidly decorated in red - and gold, with glittering chandeliers overhead. - The entrance from the street is to the [north,](entrance) and there are doorways - [south](bar) and [west.](cloakroom) + Вы стоите в центре просторного холла, роскошно декорированного + красным и золотым. + Массивные люстры ярко сияют под потолком. + Вход с улицы смотрит на [север](entrance), две другие двери ведут в [южном](bar) и [западном](cloakroom) направлении. """ credits: """ Игра использует эти иконки с сайта [game-icons.net](http://www.game-icons.net): @@ -27,56 +27,63 @@ credits: """ Опять же, [оригинальная игра](http://www.firthworks.com/roger/cloak/) была написана Роджером Фиртом. - Данная версия опирается на перевод Андрея Гранкина. + Данная версия опирается на перевод Дениса Гаева. Исходный код этой версии доступен [здесь.](https://gitlab.com/Oreolek/cloak-salet) """ entrance: """ - You've only just arrived, and besides, the weather outside seems to be getting worse. + Вы только пришли сюда. К тому же, погода снаружи заметно ухудшается. """ cloakroom: """ - The walls of this small room were clearly once lined with hooks, - though now [only one](./verb_examine_hook) remains. The exit is a door to the [east.](foyer) + Когда-то на стенах этой комнаты было множество крючков, предназначенных для одежды, + но сохранился [только один.](./verb_examine_hook) + Единственный выход отсюда – [восточная дверь.](foyer) """ -cloakroom_title: "Cloakroom" -entrance_title: "Street entrance" -bar_title: "Foyer bar" +cloakroom_title: "Гардероб" +entrance_title: "Выход на улицу" +bar_title: "Буфет" bar: """ - The bar, much rougher than you'd have guessed after the opulence - of the foyer to the north, is completely empty. + Театральный буфет (намного более скромный, чем можно было предположить после роскоши фойе, расположенного к северу отсюда) совершенно пуст. """ -message_disp: "Message" +message_disp: "Сообщение" message: """ - There seems to be some sort of {{message}} scrawled in the sawdust on the floor. + Но похоже, что в пыли на полу написано [что-то важное.](./message) """ message_x: """ - The message, neatly marked in the sawdust, reads... + Начертанная в пыли надпись сообщает Вам, что... - ### You have won + ### Вы выиграли """ message_ruined: """ - The message has been carelessly trampled, making it difficult to read. - You can just distinguish the words... + Полустертую надпись разобрать очень трудно. + С трудом можно различить такие слова... - ### You have lost + ### Вы проиграли """ cloak: """ - A handsome cloak, of velvet trimmed with satin, and slightly spattered with raindrops. - Its blackness is so deep that it almost seems to suck light from the room. + Хороший плащ (из черного бархата с атласной прокладкой), немного промокший от дождя. + Его чернота настолько глубока, что возникает ощущение, словно он втягивает в себя + весь свет из окружающего мира. """ -cloak_disp: "Cloak" -hook: "It's just a small brass hook," -hook_disp: "Small hook" -hook_empty: "screwed to the wall." -hook_full: "with {list} hanging on it." -bar_dark: "The room completely submerged in darkness." -darkness: "Darkness" -wear_darkness: "You are already wearing it, in a way." -dark: "Blundering around in the dark isn't a good idea!" -drop_cloak: "This isn't the best place to leave a smart cloak lying around." -hang_cloak: "There's a hook here, so you hang the cloak on it." +cloak_disp: "Плащ" +cloak_invl: "плащ" +hook: "Всего лишь маленький бронзовый крючок для одежды" +hook_disp: "Крючок" +hook_empty: ", привинченный к стене." +hook_full: ", с которого свисает {list}." +bar_dark: "Комната полностью заполнена темнотой." +darkness: "Темнота" +wear_darkness: "Это уже надето на вас, между прочим." +dark: "Слоняться в кромешной тьме – не самая лучшая идея." +drop_cloak: "Это не самое лучшее место, чтобы оставлять на полу особенный плащ." +hang_cloak: "Вы оставляете свой вельветовый плащ на крючке." wear_cloak: "You take the cloak from the hook and wear it." -take_cloak: "You take the cloak from the hook." -night: "Night mode" -multiplayer: "Multiplayer mode" -showall: "Filter list of objects" +take_cloak: "Вы берёте плащ с крючка." +night: "Ночной режим" +multiplayer: "Режим мультиплеера" +erase_message: "Вы точно хотите стереть сохранение и начать игру заново?" +inventory_empty: "Вы ничего не носите с собой." +inventory_contains: "Вы носите с собой:" +entrance: """ + Ой. Как вы сюда попали? Вы какой-то маг или волшебник? +""" diff --git a/html/en.html b/html/en.html index c8c4246..debcd90 100644 --- a/html/en.html +++ b/html/en.html @@ -33,16 +33,16 @@
-
Examine
+
Examine
-
Take
+
Take
-
Drop
+
Drop
-
Wear
+
Wear
diff --git a/html/index.html b/html/index.html index 2c3dc16..749861f 100644 --- a/html/index.html +++ b/html/index.html @@ -2,7 +2,7 @@ - Инженер + Плащ Тьмы @@ -13,9 +13,6 @@
@@ -26,9 +23,9 @@ @@ -47,19 +51,18 @@
- - + + + + -