gettextize and some rough translations
authorStas Sergeev <stsp@aknet.ru>
Sat, 16 Sep 2006 18:47:55 +0000 (18:47 +0000)
committerStas Sergeev <stsp@aknet.ru>
Sat, 16 Sep 2006 18:47:55 +0000 (18:47 +0000)
12 files changed:
po/LINGUAS [new file with mode: 0644]
po/POTFILES.in
po/ru.po [new file with mode: 0644]
src/Makefile.am
src/Makefile.in
src/ai.c
src/battle.c
src/events.c
src/finish.c
src/io.c
src/setup.c
src/sst.h

diff --git a/po/LINGUAS b/po/LINGUAS
new file mode 100644 (file)
index 0000000..adc719b
--- /dev/null
@@ -0,0 +1 @@
+ru
\ No newline at end of file
index 667e27c3cbc0d137d9e2e0ec2a6b29522c596fe9..f05dba1001314690fe41c20955165f2c4f3729ee 100644 (file)
@@ -1 +1,5 @@
 # List of source files which contain translatable strings.
+src/ai.c
+src/battle.c
+src/events.c
+src/finish.c
diff --git a/po/ru.po b/po/ru.po
new file mode 100644 (file)
index 0000000..29e06e0
--- /dev/null
+++ b/po/ru.po
@@ -0,0 +1,1301 @@
+# Russian translations for sst package
+# Английские переводы для пакета sst.
+# Copyright (C) 2006 Free Software Foundation, Inc.
+# This file is distributed under the same license as the sst package.
+# Stas Sergeev <stsp@aknet.ru>, 2006.
+#
+# Извините если что не так. Я ведь программист, а не переводчик. :)
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: sst 2.0\n"
+"Report-Msgid-Bugs-To: stsp\n"
+"POT-Creation-Date: 2006-09-15 18:55+0400\n"
+"PO-Revision-Date: 2006-09-15 11:01+0400\n"
+"Last-Translator: Stas Sergeev <stsp@aknet.ru>\n"
+"Language-Team: Russian <ru@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%"
+"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
+
+#: src/ai.c:30
+#, c-format
+msgid " escapes to %s (and regains strength)."
+msgstr " удирает в %s (и восстанавливает энергию)"
+
+#: src/ai.c:258
+#, c-format
+msgid " from %s"
+msgstr " из %s"
+
+#: src/ai.c:259
+msgid " advances to "
+msgstr " наступает к "
+
+#: src/ai.c:260
+msgid " retreats to "
+msgstr " отступает к "
+
+#: src/ai.c:358 src/ai.c:545
+msgid "Lt. Uhura-  \"Captain, Starfleet Intelligence reports"
+msgstr "Лт. Ухура- \"Капитан, разведка звёздного флота докладывает"
+
+#: src/ai.c:359
+msgid "   a planet in "
+msgstr "   планета в "
+
+#: src/ai.c:361
+msgid " has been destroyed"
+msgstr " уничтожена"
+
+#: src/ai.c:362
+msgid "   by the Super-commander.\""
+msgstr "   Глав-комом."
+
+#: src/ai.c:520 src/events.c:209
+msgid "Lt. Uhura-  \"Captain, the starbase in "
+msgstr "Лт. Ухура- \"Капитан, база в "
+
+#: src/ai.c:523
+msgid "   reports that it is under attack from the Klingon Super-commander."
+msgstr "   сообщает, что она атакована Глав-комом Клингонов."
+
+#: src/ai.c:524
+#, c-format
+msgid "   It can survive until stardate %d.\""
+msgstr "   Она сможет продержаться до даты %d.\""
+
+#: src/ai.c:527 src/events.c:217
+msgid "Mr. Spock-  \"Captain, shall we cancel the rest period?\""
+msgstr "Мистер Спок- \"Капитан, нам прервать отдых?\""
+
+#: src/ai.c:546
+msgid "   the Super-commander is in "
+msgstr "   Глав-ком находится в "
+
+#: src/ai.c:611
+msgid " completes web."
+msgstr " доделал сеть."
+
+#: src/battle.c:19 src/battle.c:35
+msgid "Shields damaged and down."
+msgstr "Защита сломана и отключена."
+
+#: src/battle.c:29
+msgid "Do you wish to change shield energy? "
+msgstr "Вы хотите изменить энергию защиты? "
+
+#: src/battle.c:31 src/battle.c:87
+msgid "Energy to transfer to shields- "
+msgstr "Энергия для защитного поля- "
+
+#: src/battle.c:39
+msgid "Shields are up. Do you want them down? "
+msgstr "Защита включена. Вы хотите её отключить? "
+
+#: src/battle.c:47
+msgid "Shields are down. Do you want them up? "
+msgstr "Защита отключена. Вы хотите её включить? "
+
+#: src/battle.c:59
+msgid "Shields already up."
+msgstr "Защита и так уже включена."
+
+#: src/battle.c:65 src/battle.c:1170
+msgid "Shields raised."
+msgstr "Защита поднята."
+
+#: src/battle.c:68
+msgid "Shields raising uses up last of energy."
+msgstr "Поднятие защиты расходует весь остаток энергии."
+
+#: src/battle.c:76
+msgid "Shields already down."
+msgstr "Защита и так уже отключена."
+
+#: src/battle.c:81 src/battle.c:851
+msgid "Shields lowered."
+msgstr "Защита опущена."
+
+#: src/battle.c:92
+msgid "Insufficient ship energy."
+msgstr "Энергии корабля недостаточно."
+
+#: src/battle.c:97
+msgid "Shield energy maximized."
+msgstr "Энергия защиты достигла максимума."
+
+#: src/battle.c:99
+msgid "Excess energy requested returned to ship energy"
+msgstr "Лишняя энергия вернулась кораблю"
+
+#: src/battle.c:108
+msgid "Engineering to bridge--"
+msgstr "Инженерный отсек мостику--"
+
+#: src/battle.c:109
+msgid "  Scott here. Power circuit problem, Captain."
+msgstr "  Это Скотт. Тут проблемы с энергетическим контуром, Капитан."
+
+#: src/battle.c:110
+msgid "  I can't drain the shields."
+msgstr "  Я не могу откачать энергию из защитных полей."
+
+#: src/battle.c:115
+msgid "All shield energy transferred to ship."
+msgstr "Вся энергия защиты переправлена на корабль."
+
+#: src/battle.c:120
+msgid "Scotty- \""
+msgstr "Скотти- \""
+
+#: src/battle.c:122
+msgid "Transferring energy to shields.\""
+msgstr "Перевожу энергию на защиту.\""
+
+#: src/battle.c:124
+msgid "Draining energy from shields.\""
+msgstr "Перевожу энергию из защиты.\""
+
+#: src/battle.c:137 src/battle.c:855 src/events.c:667
+msgid "***RED ALERT!  RED ALERT!"
+msgstr "***ТРЕВОГА!  ТРЕВОГА!"
+
+#: src/battle.c:139
+msgid "***COLLISION IMMINENT."
+msgstr "***ОПАСНОСТЬ СТОЛКНОВЕНИЯ."
+
+#: src/battle.c:150
+msgid " rammed by "
+msgstr " протаранен "
+
+#: src/battle.c:150
+msgid " rams "
+msgstr " протаранил "
+
+#: src/battle.c:152
+msgid " (original position)"
+msgstr " (первоначальное положение)"
+
+#: src/battle.c:157
+msgid " heavily damaged."
+msgstr " серьёзно повреждён."
+
+#: src/battle.c:159
+#, c-format
+msgid "***Sickbay reports %d casualties"
+msgstr "***Из лазарета докладывают о %d пострадавших"
+
+#: src/battle.c:213
+msgid "Torpedo hits "
+msgstr "Торпеда попала в цель: "
+
+#: src/battle.c:249
+msgid " uses anti-photon device;"
+msgstr " использует противофотонную установку;"
+
+#: src/battle.c:250
+msgid "   torpedo neutralized."
+msgstr "   торпеда нейтрализована."
+
+#: src/battle.c:279 src/battle.c:289
+msgid " damaged but not destroyed."
+msgstr " повреждён, но не уничтожен."
+
+#: src/battle.c:283
+msgid " buffeted into black hole."
+msgstr " отлетел в чёрную дыру."
+
+#: src/battle.c:292
+msgid " damaged--"
+msgstr " повреждён--"
+
+#: src/battle.c:299
+msgid "***STARBASE DESTROYED.."
+msgstr "***БАЗА УНИЧТОЖЕНА.."
+
+#: src/battle.c:317 src/battle.c:654 src/events.c:472 src/events.c:493
+msgid " destroyed."
+msgstr " уничтожен."
+
+#: src/battle.c:335
+msgid " unaffected by photon blast."
+msgstr " не повреждён фотонным зарядом."
+
+#: src/battle.c:340
+msgid "AAAAIIIIEEEEEEEEAAAAAAAAUUUUUGGGGGHHHHHHHHHHHH!!!"
+msgstr "ВВВВППППЕЕЕЕРРРЁЁЁЁДДДЗЗЗЗААААРРРРООООДДДДИИИННННУУУУ!!!"
+
+#: src/battle.c:342
+msgid "    HACK!     HACK!    HACK!        *CHOKE!*  "
+msgstr ""
+
+#: src/battle.c:344
+msgid "Mr. Spock-"
+msgstr "Мистер Спок-"
+
+#: src/battle.c:345
+msgid "  \"Fascinating!\""
+msgstr "  \"Грандиозно!\""
+
+#: src/battle.c:361
+msgid " swallows torpedo."
+msgstr " поглотила торпеду."
+
+#: src/battle.c:365
+msgid "***Torpedo absorbed by Tholian web."
+msgstr "***Толианская сеть поглотила торпеду."
+
+#: src/battle.c:382
+msgid " survives photon blast."
+msgstr " выдержал фотонный взрыв."
+
+#: src/battle.c:385
+msgid " disappears."
+msgstr " исчез."
+
+#: src/battle.c:410
+#, c-format
+msgid " displaced by blast to %s "
+msgstr " перемещён взрывом на %s "
+
+#: src/battle.c:417
+msgid "Torpedo missed."
+msgstr "Торпеда промазала."
+
+#: src/battle.c:430
+msgid "***CRITICAL HIT--"
+msgstr "***КРИТИЧЕСКИЙ УДАР--"
+
+#: src/battle.c:446
+msgid " and "
+msgstr " и "
+
+#: src/battle.c:450
+msgid " damaged."
+msgstr " поврежден."
+
+#: src/battle.c:452
+msgid "***Shields knocked down."
+msgstr "***Защита сбита."
+
+#: src/battle.c:510
+msgid "***TORPEDO INCOMING"
+msgstr "***ТОРПЕДА ПРИБЛИЖАЕТСЯ"
+
+#: src/battle.c:512
+msgid " From "
+msgstr " От "
+
+#: src/battle.c:544
+#, c-format
+msgid "%d unit hit"
+msgstr "удар на %d единиц"
+
+#: src/battle.c:546
+msgid " on the "
+msgstr " по "
+
+#: src/battle.c:550
+msgid " from "
+msgstr " от "
+
+#: src/battle.c:568
+msgid "***Enemies decide against attacking your ship."
+msgstr "***Враги решили не атаковать ваш корабль."
+
+#: src/battle.c:573
+msgid "Enemy attack reduces shield strength to "
+msgstr "Вражеская атака уменьшает силу защиты до "
+
+#: src/battle.c:578
+#, c-format
+msgid "Energy left %2d    shields "
+msgstr "Остаток энергии: %2d    защита "
+
+#: src/battle.c:579
+msgid "up "
+msgstr "включена "
+
+#: src/battle.c:580
+msgid "down "
+msgstr "отключена "
+
+#: src/battle.c:581
+msgid "damaged, "
+msgstr "сломана, "
+
+#: src/battle.c:583
+#, c-format
+msgid "%d%%,   torpedoes left %d"
+msgstr "%d%%,   осталось %d торпед"
+
+#: src/battle.c:589
+#, c-format
+msgid "Mc Coy-  \"Sickbay to bridge.  We suffered %d casualties"
+msgstr "МакКой- \"Лазарет мостику.  К нам поступили %d пострадавших"
+
+#: src/battle.c:590
+msgid "   in that last attack.\""
+msgstr "   от последней атаки.\""
+
+#: src/battle.c:694
+msgid "Spock-  \"Bridge to sickbay.  Dr. McCoy,"
+msgstr "Спок- \"Мостик лазарету.  Доктор МакКой,"
+
+#: src/battle.c:695
+msgid "  I recommend an immediate review of"
+msgstr "  рекомендую немедленно проверить"
+
+#: src/battle.c:696
+msgid "  the Captain's psychological profile.\""
+msgstr "  психологическое состояние Капитана.\""
+
+#: src/battle.c:713
+msgid "Photon tubes damaged."
+msgstr "Фотонные трубы сломаны."
+
+#: src/battle.c:718
+msgid "No torpedoes left."
+msgstr "Торпед совсем не осталось."
+
+#: src/battle.c:729
+#, c-format
+msgid "%d torpedoes left."
+msgstr "Осталось %d торпед."
+
+#: src/battle.c:730
+msgid "Number of torpedoes to fire- "
+msgstr "Число торпед на отстрел- "
+
+#: src/battle.c:741
+msgid "Maximum of 3 torpedoes per burst."
+msgstr "Максимум 3 торпеды за залп."
+
+#: src/battle.c:782
+#, c-format
+msgid "Target sector for torpedo number %d- "
+msgstr "Сектор назначения для торпеды номер %d- "
+
+#: src/battle.c:809
+#, c-format
+msgid "***TORPEDO NUMBER %d MISFIRES"
+msgstr "***ТОРПЕДА НОМЕР %d НЕ СОШЛА"
+
+#: src/battle.c:811
+msgid "***TORPEDO MISFIRES."
+msgstr "***ТОРПЕДА НЕ СОШЛА."
+
+#: src/battle.c:814
+msgid "  Remainder of burst aborted."
+msgstr "  Остаток залпа отменён."
+
+#: src/battle.c:817
+msgid "***Photon tubes damaged by misfire."
+msgstr "***Фотонные трубы сломались при осечке."
+
+#: src/battle.c:838
+msgid "Weapons officer Sulu-  \"Phasers overheated, sir.\""
+msgstr "Наводчик Сулу- \"Фазеры перегорели, сэр.\""
+
+#: src/battle.c:861
+msgid "Sulu-  \"Captain! Shield malf***********************\""
+msgstr "Сулу- \"Капитан! Защита не сраб*********************\""
+
+#: src/battle.c:867
+msgid "Sulu-  \"Captain! Shield malfunction! Phaser fire contained!\""
+msgstr ""
+"Сулу- \"Капитан! Защита не сработала! Энергия фазеров скопилась внутри!\""
+
+#: src/battle.c:869
+msgid "Lt. Uhura-  \"Sir, all decks reporting damage.\""
+msgstr "Лт. Ухура- \"Сэр, все палубы сообщают о повреждении.\""
+
+#: src/battle.c:875
+msgid "McCoy to bridge- \"Severe radiation burns, Jim."
+msgstr "МакКой мостику- \"Сильнейшие радиационные ожоги, Джим."
+
+#: src/battle.c:876
+#, c-format
+msgid "  %d casualties so far.\""
+msgstr "  пока-что %d пострадавших.\""
+
+#: src/battle.c:880
+msgid "Phaser energy dispersed by shields."
+msgstr "Энергия фазеров рассеяна защитным полем."
+
+#: src/battle.c:881
+msgid "Enemy unaffected."
+msgstr "Враг не пострадал."
+
+#: src/battle.c:899
+msgid "Phasers can't be fired through base shields."
+msgstr "Фазеры не могут стрелять через защиту базы."
+
+#: src/battle.c:904
+msgid "Phaser control damaged."
+msgstr "Управление фазерами не работает."
+
+#: src/battle.c:910
+msgid "High speed shield control damaged."
+msgstr "Высокоскоростное управление защитой не работает."
+
+#: src/battle.c:915
+msgid "Insufficient energy to activate high-speed shield control."
+msgstr "Недостаточно энергии для высокоскоростного управления защитой."
+
+#: src/battle.c:919
+msgid "Weapons Officer Sulu-  \"High-speed shield control enabled, sir.\""
+msgstr "Наводчик Сулу- \"Высокоскоростное управление защитой включено, сэр.\""
+
+#: src/battle.c:929
+msgid "There is no enemy present to select."
+msgstr "Здесь нет врагов."
+
+#: src/battle.c:945 src/battle.c:960 src/battle.c:971
+msgid "Energy will be expended into space."
+msgstr "Энергия уйдёт в пустоту."
+
+#: src/battle.c:977
+msgid "Manual or automatic? "
+msgstr "Ручной или автоматический?"
+
+#: src/battle.c:988
+#, c-format
+msgid "Phasers locked on target. Energy available: %.2f"
+msgstr "Фазеры наведены на цель. Доступная энергия: %.2f"
+
+#: src/battle.c:998
+#, c-format
+msgid "(%d) units required. "
+msgstr ""
+
+#: src/battle.c:1000
+msgid "Units to fire= "
+msgstr "Энергия на выстрел= "
+
+#: src/battle.c:1005 src/battle.c:1076
+#, c-format
+msgid "Energy available= %.2f"
+msgstr "Доступная энергия= %.2f"
+
+#: src/battle.c:1046
+msgid "*** Tholian web absorbs "
+msgstr "*** Толианская сеть поглощает "
+
+#: src/battle.c:1047
+msgid "excess "
+msgstr "избыточную "
+
+#: src/battle.c:1048
+msgid "phaser energy."
+msgstr "энергию фазеров."
+
+#: src/battle.c:1051
+#, c-format
+msgid "%d expended on empty space."
+msgstr "%d ушло в пустоту."
+
+#: src/battle.c:1060
+msgid "Battle comuter damaged, manual file only."
+msgstr "Бортовой компьютер сломан, используйте ручное управление."
+
+#: src/battle.c:1063 src/finish.c:13
+msgid "---WORKING---"
+msgstr "---РАБОТА---"
+
+#: src/battle.c:1065
+msgid "Short-range-sensors-damaged"
+msgstr "Сенсоры-ближнего-обзора-сломаны"
+
+#: src/battle.c:1066
+msgid "Insufficient-data-for-automatic-phaser-fire"
+msgstr "Недостаточно-данных-для-автоматического-наведения-фазеров"
+
+#: src/battle.c:1067
+msgid "Manual-fire-must-be-used"
+msgstr "Используйте-ручное-наведение"
+
+#: src/battle.c:1085
+msgid " can't be located without short range scan."
+msgstr " не может быть обнаружен без ближнего сканирования."
+
+#: src/battle.c:1102
+msgid "units to fire at "
+msgstr "энергии на выстрел по "
+
+#: src/battle.c:1132
+msgid "Available energy exceeded -- try again."
+msgstr "Имеющейся энергии не хватает -- попробуйте снова."
+
+#: src/battle.c:1164
+msgid "Sulu-  \"Sir, the high-speed shield control has malfunctioned . . ."
+msgstr "Сулу- \"Сэр, высокоскоростное управление защитой не сработало . . ."
+
+#: src/battle.c:1165
+msgid "         CLICK   CLICK   POP  . . ."
+msgstr "         ЩЁЛК   ЩЁЛК   ЧЁРТ  . . ."
+
+#: src/battle.c:1166
+msgid " No response, sir!"
+msgstr " Нет ответа, сэр!"
+
+#: src/battle.c:1199
+#, c-format
+msgid "%d unit hit on "
+msgstr "%d единиц энергии ударили по "
+
+#: src/battle.c:1202
+msgid "Very small hit on "
+msgstr "Очень слабый удар по "
+
+#: src/battle.c:1216
+msgid "***Mr. Spock-  \"Captain, the vessel at "
+msgstr "***Мистер Спок- \"Капитан, корабль на "
+
+#: src/battle.c:1218
+msgid "   has just lost its firepower.\""
+msgstr "   потерял боеспособность.\""
+
+#: src/events.c:53
+msgid "Lt. Uhura- \"Captain, the sub-space radio is working and"
+msgstr "Лт. Ухура- \"Капитан, космическая рация работает и"
+
+#: src/events.c:54
+msgid "   surveillance reports are coming in."
+msgstr "   принимает информацию из центра наблюдения."
+
+#: src/events.c:61
+msgid "   The star chart is now up to date.\""
+msgstr "   Звёздная карта обновлена."
+
+#: src/events.c:114
+msgid " caught in long range tractor beam--"
+msgstr " пойман дальнобойным буксирным лучём--"
+
+#: src/events.c:126
+msgid "Galileo, left on the planet surface, is captured"
+msgstr "Галилей, оставшийся на планете, схвачен"
+
+#: src/events.c:127
+msgid "by aliens and made into a flying McDonald's."
+msgstr "инопланетянами и превращён в летательный МакДональдс."
+
+#: src/events.c:132
+msgid "Galileo, left on the planet surface, is well hidden."
+msgstr "Галилей, оставшийся на планете, хорошо спрятан."
+
+#: src/events.c:145
+msgid " is pulled to "
+msgstr " затянут в "
+
+#: src/events.c:150
+msgid "(Remainder of rest/repair period cancelled.)"
+msgstr "(Остаток периода отдыха/ремонта отменён.)"
+
+#: src/events.c:158
+msgid "(Shields not currently useable.)"
+msgstr "(Защита в нерабочем состоянии.)"
+
+#: src/events.c:211
+msgid "   reports that it is under attack and that it can"
+msgstr "   сообщает, что она атакована и сможет"
+
+#: src/events.c:212
+#, c-format
+msgid "   hold out only until stardate %d"
+msgstr "   продержаться до даты %d.\""
+
+#: src/events.c:257
+msgid "Spock-  \"Captain, I believe the starbase has been destroyed.\""
+msgstr "Спок- \"Капитан, я чувствую, что база уничтожена.\""
+
+#: src/events.c:265
+msgid "Lt. Uhura-  \"Captain, Starfleet Command reports that"
+msgstr "Лт. Ухура- \"Капитан, штаб звёздного флота сообщает"
+
+#: src/events.c:266
+msgid "   the starbase in "
+msgstr "   база в "
+
+#: src/events.c:268
+msgid " has been destroyed by"
+msgstr " уничтожена"
+
+#: src/events.c:269
+msgid "the Klingon Super-Commander"
+msgstr "Глав-комом Клингонов"
+
+#: src/events.c:270
+msgid "a Klingon Commander"
+msgstr "Командиром Клингонов"
+
+#: src/events.c:313
+msgid "Lt. Uhura-  \"The deep space probe "
+msgstr "Лт. Ухура- \"Дальнобойная космическая ракета "
+
+#: src/events.c:315
+msgid "has left the galaxy"
+msgstr "покинула галактику"
+
+#: src/events.c:317
+msgid "is no longer transmitting"
+msgstr "больше не передаёт"
+
+#: src/events.c:327
+msgid "Lt. Uhura-  \"The deep space probe is now in "
+msgstr "Лт. Ухура- \"Дальнобойная космическая ракета сейчас в "
+
+#: src/events.c:364
+msgid "How long? "
+msgstr "Какой срок? "
+
+#: src/events.c:374
+msgid "Are you sure? "
+msgstr "Вы уверены? "
+
+#: src/events.c:384
+#, c-format
+msgid "%d stardates left."
+msgstr "Осталось %d дней."
+
+#: src/events.c:426 src/events.c:465
+msgid " novas."
+msgstr " взорвалась."
+
+#: src/events.c:498
+msgid "***Starship buffeted by nova."
+msgstr "***Звездолёт отбросило взрывом звезды."
+
+#: src/events.c:506
+msgid "***Shields knocked out."
+msgstr "***Защита разбита."
+
+#: src/events.c:536
+msgid " damaged"
+msgstr " повреждён"
+
+#: src/events.c:544
+msgid ", blasted into "
+msgstr ", долбанулся в "
+
+#: src/events.c:555
+msgid ", buffeted to "
+msgstr " отлетел в чёрную дыру."
+
+#: src/events.c:584
+msgid "Force of nova displaces starship."
+msgstr "Взрыв звезды смещает звездолёт."
+
+#: src/events.c:641
+#, c-format
+msgid "Message from Starfleet Command       Stardate %.2f"
+msgstr "Сообщение от штаба Звёздного Флота       Дата %.2f"
+
+#: src/events.c:642
+#, c-format
+msgid "     Supernova in %s; caution advised."
+msgstr "     Взрыв сверхновой в %s; соблюдайте осторожность."
+
+#: src/events.c:669
+msgid "***Incipient supernova detected at "
+msgstr "***Зарегистрировано появление сверхновой в "
+
+#: src/events.c:673
+msgid "Emergency override attempts t"
+msgstr "Автопилот пытается в"
+
+#: src/events.c:744
+msgid "Lucky you!"
+msgstr "Повезло!"
+
+#: src/events.c:745
+#, c-format
+msgid "A supernova in %s has just destroyed the last Klingons."
+msgstr "Сверхновая в %s как раз уничтожила последних Клингонов."
+
+#: src/finish.c:10
+msgid "Computer damaged; cannot execute destruct sequence."
+msgstr "Компьютер сломан; невозможно запустить программу самоуничтожения."
+
+#: src/finish.c:14
+msgid "SELF-DESTRUCT-SEQUENCE-ACTIVATED"
+msgstr "ПРОГРАММА-САМОУНИЧТОЖЕНИЯ-ЗАПУЩЕНА"
+
+#: src/finish.c:21
+msgid "ENTER-CORRECT-PASSWORD-TO-CONTINUE-"
+msgstr "ВВЕДИТЕ-ПАРОЛЬ-ДЛЯ-ПРОДОЛЖЕНИЯ-"
+
+#: src/finish.c:23
+msgid "SELF-DESTRUCT-SEQUENCE-OTHERWISE-"
+msgstr "САМОУНИЧТОЖЕНИЯ-А-ИНАЧЕ-"
+
+#: src/finish.c:25
+msgid "SELF-DESTRUCT-SEQUENCE-WILL-BE-ABORTED"
+msgstr "САМОУНИЧТОЖЕНИЕ-БУДЕТ-ПРЕРВАНО"
+
+#: src/finish.c:30
+msgid "PASSWORD-REJECTED;"
+msgstr "ПАРОЛЬ-НЕ-ПРИНЯТ"
+
+#: src/finish.c:32
+msgid "CONTINUITY-EFFECTED"
+msgstr "ПРОДОЛЖАЕМ-ЖИТЬ"
+
+#: src/finish.c:36
+msgid "PASSWORD-ACCEPTED"
+msgstr "ПАРОЛЬ-ПРИНЯТ"
+
+#: src/finish.c:43
+msgid "GOODBYE-CRUEL-WORLD"
+msgstr "ПРОЩАЙ-ЖЕСТОКИЙ-МИР"
+
+#: src/finish.c:53
+msgid "********* Entropy of "
+msgstr "********* Ентропия корабля "
+
+#: src/finish.c:55
+msgid " maximized *********"
+msgstr " возрасла *********"
+
+#: src/finish.c:77
+#, c-format
+msgid "It is stardate %.1f."
+msgstr "Сегодня %.1f число."
+
+#: src/finish.c:82
+#, c-format
+msgid "The remaining %d Romulans surrender to Starfleet Command."
+msgstr "Оставшиеся %d Ромулан сдались Звёздному Флоту."
+
+#: src/finish.c:85
+msgid "You have smashed the Klingon invasion fleet and saved"
+msgstr "Вы сокрушили флот Клингоновских захватчиков и спасли"
+
+#: src/finish.c:86
+msgid "the Federation."
+msgstr "Федерацию."
+
+#: src/finish.c:100
+msgid "In fact, you have done so well that Starfleet Command"
+msgstr "По правде говоря, вы действовали так умело, что штаб Звёздного Флота"
+
+#: src/finish.c:103
+msgid "promotes you one step in rank from \"Novice\" to \"Fair\"."
+msgstr "повышает ваш ранг от Новичка до Середнячка."
+
+#: src/finish.c:106
+msgid "promotes you one step in rank from \"Fair\" to \"Good\"."
+msgstr "повышает ваш ранг от Середнячка до Умелого."
+
+#: src/finish.c:109
+msgid "promotes you one step in rank from \"Good\" to \"Expert\"."
+msgstr "повышает ваш ранг от Умелого до Специалиста."
+
+#: src/finish.c:112
+msgid "promotes you to Commodore Emeritus."
+msgstr "возводит вас на должность Отставного Капитана."
+
+#: src/finish.c:114
+msgid "Now that you think you're really good, try playing"
+msgstr "Теперь, когда вы считаете себя хорошим игроком, попытайтесь сыграть"
+
+#: src/finish.c:115
+msgid "the \"Emeritus\" game. It will splatter your ego."
+msgstr "за \"Emeritus\". Это охладит ваш пыл."
+
+#: src/finish.c:119
+msgid "Computer-  "
+msgstr "Компьютер-  "
+
+#: src/finish.c:120
+msgid "ERROR-ERROR-ERROR-ERROR"
+msgstr "СБОЙ-СБОЙ-СБОЙ-ОШИБКА"
+
+#: src/finish.c:122
+msgid "  YOUR-SKILL-HAS-EXCEEDED-THE-CAPACITY-OF-THIS-PROGRAM"
+msgstr "  ВАШЕ-МАСТЕРСТВО-НЕПОДВЛАСТНО-ЭТОЙ-ПРОГРАММЕ"
+
+#: src/finish.c:124 src/finish.c:126 src/finish.c:128
+msgid "  THIS-PROGRAM-MUST-SURVIVE"
+msgstr ""
+
+#: src/finish.c:130
+msgid "  THIS-PROGRAM-MUST?- MUST ? - SUR? ? -?  VI"
+msgstr ""
+
+#: src/finish.c:132
+msgid "Now you can retire and write your own Star Trek game!"
+msgstr "Теперь вы можете уйти на пенсию и написать свою игру Star Trek!"
+
+#: src/finish.c:142
+msgid "You cannot get a citation, so..."
+msgstr "Вам не положена грамота, так что..."
+
+#: src/finish.c:144
+msgid "Do you want your Commodore Emeritus Citation printed? "
+msgstr "Хотите распечатать вашу грамоту Отставного Капитана? "
+
+#: src/finish.c:154 src/finish.c:167
+msgid "LIVE LONG AND PROSPER."
+msgstr "ЖИВИТЕ ДОЛГО И СЧАСТЛИВО."
+
+#: src/finish.c:160
+msgid "Your time has run out and the Federation has been"
+msgstr "Ваше время истекло и Федерация была"
+
+#: src/finish.c:161
+msgid "conquered.  Your starship is now Klingon property,"
+msgstr "захвачена.  Ваш звездолёт стал собственностью Клингонов,"
+
+#: src/finish.c:162
+msgid "and you are put on trial as a war criminal.  On the"
+msgstr "а вы попали на скамью подсудимых как военный преступник.  Рассмотрев"
+
+#: src/finish.c:163
+msgid "basis of your record, you are "
+msgstr "содеянное вами, вас "
+
+#: src/finish.c:165
+msgid "acquitted."
+msgstr "освободили."
+
+#: src/finish.c:170
+msgid "found guilty and"
+msgstr "признали виновным и"
+
+#: src/finish.c:171
+msgid "sentenced to death by slow torture."
+msgstr "приговорили к смерти на медленном огне."
+
+#: src/finish.c:177
+msgid "Your life support reserves have run out, and"
+msgstr "Резервы жизнеобеспечения иссякли и"
+
+#: src/finish.c:178
+msgid "you die of thirst, starvation, and asphyxiation."
+msgstr "вы погибли от жажды, голода и удушья."
+
+#: src/finish.c:179 src/finish.c:184 src/finish.c:279
+msgid "Your starship is a derelict in space."
+msgstr "Ваш звездолёт стал космическим мусором."
+
+#: src/finish.c:182
+msgid "Your energy supply is exhausted."
+msgstr "Источники энергии иссякли."
+
+#: src/finish.c:187 src/finish.c:206 src/finish.c:225
+msgid "The "
+msgstr " "
+
+#: src/finish.c:189
+msgid "has been destroyed in battle."
+msgstr " был уничтожен в бою."
+
+#: src/finish.c:191
+msgid "Dulce et decorum est pro patria mori."
+msgstr ""
+
+#: src/finish.c:194
+msgid "You have made three attempts to cross the negative energy"
+msgstr "Вы три раза пытались пересечь негативный энергетический"
+
+#: src/finish.c:195
+msgid "barrier which surrounds the galaxy."
+msgstr "барьер, окружающий галактику."
+
+#: src/finish.c:197
+msgid "Your navigation is abominable."
+msgstr "Вы не умеете управлять кораблём."
+
+#: src/finish.c:201
+msgid "Your starship has been destroyed by a nova."
+msgstr "Ваш звездолёт уничтожен взрывом звезды."
+
+#: src/finish.c:202 src/finish.c:246
+msgid "That was a great shot."
+msgstr "Это был отличный выстрел."
+
+#: src/finish.c:208
+msgid " has been fried by a supernova."
+msgstr " был поджарен взрывом сверхновой."
+
+#: src/finish.c:209
+msgid "...Not even cinders remain..."
+msgstr "...И мокрого места не осталось..."
+
+#: src/finish.c:212
+msgid "You have been captured by the Klingons. If you still"
+msgstr "Вас захватили Клингоны. Будь у вас"
+
+#: src/finish.c:213
+msgid "had a starbase to be returned to, you would have been"
+msgstr "хотя бы база, вас бы могли"
+
+#: src/finish.c:214
+msgid "repatriated and given another chance. Since you have"
+msgstr "спасти и дать ещё шанс. А так -"
+
+#: src/finish.c:215
+msgid "no starbases, you will be mercilessly tortured to death."
+msgstr "вас безжалостно замучают и казнят."
+
+#: src/finish.c:218
+msgid "Your starship is now an expanding cloud of subatomic particles"
+msgstr "Ваш звездолёт стал облаком субатомных частиц"
+
+#: src/finish.c:221
+msgid "Starbase was unable to re-materialize your starship."
+msgstr "База не смогла материализовать ваш звездолёт."
+
+#: src/finish.c:222
+msgid "Sic transit gloria muntdi"
+msgstr ""
+
+#: src/finish.c:227
+msgid " has been cremated by its own phasers."
+msgstr " сожжён собственными фазерами."
+
+#: src/finish.c:230
+msgid "You and your landing party have been"
+msgstr "Вы и ваш отряд"
+
+#: src/finish.c:231
+msgid "converted to energy, disipating through space."
+msgstr "превратились в энергию, рассеевшуюся в пространстве."
+
+#: src/finish.c:234
+msgid "You are left with your landing party on"
+msgstr "Вы с отрядом остались на"
+
+#: src/finish.c:235
+msgid "a wild jungle planet inhabited by primitive cannibals."
+msgstr "планете диких джунглей, населённых дикими каннибалами."
+
+#: src/finish.c:237
+msgid "They are very fond of \"Captain Kirk\" soup."
+msgstr "Они очень любят \"Капитанский\" суп."
+
+#: src/finish.c:239 src/finish.c:265
+msgid "Without your leadership, the "
+msgstr "Без вашего руководства, "
+
+#: src/finish.c:241 src/finish.c:267
+msgid " is destroyed."
+msgstr " уничтожен."
+
+#: src/finish.c:244
+msgid "You and your mining party perish."
+msgstr "Вы и ваш отряд умерли."
+
+#: src/finish.c:250
+msgid "The Galileo is instantly annihilated by the supernova."
+msgstr "Галилей мгновенно испарился от взрыва сверхновой."
+
+#: src/finish.c:253
+msgid "You and your mining party are atomized."
+msgstr "Вы с вашим отрядом распались на атомы."
+
+#: src/finish.c:255
+msgid "Mr. Spock takes command of the "
+msgstr "Мистер Спок принимает командование "
+
+#: src/finish.c:257
+msgid " and"
+msgstr " и "
+
+#: src/finish.c:258
+msgid "joins the Romulans, reigning terror on the Federation."
+msgstr "присоединяется к Ромуланам и начинается террор Федерации."
+
+#: src/finish.c:261
+msgid "The shuttle craft Galileo is also caught,"
+msgstr "Челнок Галилей тоже попался"
+
+#: src/finish.c:262
+msgid "and breaks up under the strain."
+msgstr "и разломался от давления."
+
+#: src/finish.c:264
+msgid "Your debris is scattered for millions of miles."
+msgstr "Ваши кости разлетелись на миллионы миль."
+
+#: src/finish.c:270
+msgid "The mutants attack and kill Spock."
+msgstr "Мутанты напали первыми и убили Спока."
+
+#: src/finish.c:271
+msgid "Your ship is captured by Klingons, and"
+msgstr "Ваш звездолёт пойман клингонами и"
+
+#: src/finish.c:272
+msgid "your crew is put on display in a Klingon zoo."
+msgstr "ваш экипаж выставлен на показ в зоопарке."
+
+#: src/finish.c:275
+msgid "Tribbles consume all remaining water,"
+msgstr "Чёртики извели всю оставшуюся воду,"
+
+#: src/finish.c:276
+msgid "food, and oxygen on your ship."
+msgstr "пищу и кислород на корабле."
+
+#: src/finish.c:278
+msgid "You die of thirst, starvation, and asphyxiation."
+msgstr "Вы умерли от жажды, голода и удушья."
+
+#: src/finish.c:282
+msgid "Your ship is drawn to the center of the black hole."
+msgstr "Ваш корабль занесло прямо в центр чёрной дыры."
+
+#: src/finish.c:283
+msgid "You are crushed into extremely dense matter."
+msgstr "Вас расплющило до состояния сверхтвёрдого вещества."
+
+#: src/finish.c:293
+msgid "As a result of your actions, a treaty with the Klingon"
+msgstr "В результате ваших действий, с империей Клингонов"
+
+#: src/finish.c:294
+msgid "Empire has been signed. The terms of the treaty are"
+msgstr "удалось подписать договор. Условия этого договора"
+
+#: src/finish.c:296
+msgid "favorable to the Federation."
+msgstr "выгодны для Федерации."
+
+#: src/finish.c:298
+msgid "Congratulations!"
+msgstr "Поздравляем!"
+
+#: src/finish.c:301
+msgid "highly unfavorable to the Federation."
+msgstr "крайне не выгодны для Федерации."
+
+#: src/finish.c:304
+msgid "The Federation will be destroyed."
+msgstr "Федерация погибнет."
+
+#: src/finish.c:307
+msgid "Since you took the last Klingon with you, you are a"
+msgstr "Поскольку вы забрали на тот свет последнего Клингона, вы теперь"
+
+#: src/finish.c:308
+msgid "martyr and a hero. Someday maybe they'll erect a"
+msgstr "мученик и герой. Возможно однажды даже поставят"
+
+#: src/finish.c:309
+msgid "statue in your memory. Rest in peace, and try not"
+msgstr "статую в вашу честь. Покойтесь с миром и постарайтесь не"
+
+#: src/finish.c:310
+msgid "to think about pigeons."
+msgstr "думать о голубях."
+
+#: src/finish.c:336
+msgid "Your score --"
+msgstr "Ваши очки --"
+
+#: src/finish.c:338
+#, c-format
+msgid "%6d Romulans destroyed                 %5d"
+msgstr "%6d Ромулан уничтожено                 %5d"
+
+#: src/finish.c:341
+#, c-format
+msgid "%6d Romulans captured                  %5d"
+msgstr "%6d Ромулан захвачено                  %5d"
+
+#: src/finish.c:344
+#, c-format
+msgid "%6d ordinary Klingons destroyed        %5d"
+msgstr "%6d рядовых Клингонов уничтожено        %5d"
+
+#: src/finish.c:347
+#, c-format
+msgid "%6d Klingon commanders destroyed       %5d"
+msgstr "%6d Клингоновских командиров уничтожено       %5d"
+
+#: src/finish.c:350
+#, c-format
+msgid "%6d Super-Commander destroyed          %5d"
+msgstr "%6d Глав-комов уничтожено          %5d"
+
+#: src/finish.c:353
+#, c-format
+msgid "%6.2f Klingons per stardate              %5d"
+msgstr "%6.2f Клингонов в день              %5d"
+
+#: src/finish.c:356
+#, c-format
+msgid "%6d stars destroyed by your action     %5d"
+msgstr "%6d звёзд уничтожено     %5d"
+
+#: src/finish.c:359
+#, c-format
+msgid "%6d planets destroyed by your action   %5d"
+msgstr "%6d планет уничтожено   %5d"
+
+#: src/finish.c:362
+#, c-format
+msgid "%6d bases destroyed by your action     %5d"
+msgstr "%6d баз уничтожено     %5d"
+
+#: src/finish.c:365
+#, c-format
+msgid "%6d calls for help from starbase       %5d"
+msgstr "%6d обращений за помощью к базе       %5d"
+
+#: src/finish.c:368
+#, c-format
+msgid "%6d casualties incurred                %5d"
+msgstr "%6d человек пострадали                %5d"
+
+#: src/finish.c:371
+#, c-format
+msgid "%6d ship(s) lost or destroyed          %5d"
+msgstr "%6d корабль(ей) потеряно          %5d"
+
+#: src/finish.c:374
+msgid "Penalty for getting yourself killed        -200"
+msgstr "Расплата за собственную гибель        -200"
+
+#: src/finish.c:376
+msgid "Bonus for winning "
+msgstr "Доплата за победу в "
+
+#: src/finish.c:378
+msgid "Novice game  "
+msgstr "игре Новичка  "
+
+#: src/finish.c:379
+msgid "Fair game    "
+msgstr "игре Середнячка    "
+
+#: src/finish.c:380
+msgid "Good game    "
+msgstr "игре Умелого    "
+
+#: src/finish.c:381
+msgid "Expert game  "
+msgstr "игре Специалиста  "
+
+#: src/finish.c:382
+msgid "Emeritus game"
+msgstr "игре Отставного Капитана"
+
+#: src/finish.c:387
+#, c-format
+msgid "TOTAL SCORE                               %5d"
+msgstr "ОБЩИЙ СЧЁТ                               %5d"
+
+#: src/finish.c:400
+msgid "File or device name for your plaque: "
+msgstr "Имя файла или устройства для грамоты: "
+
+#: src/finish.c:404
+msgid "Invalid name."
+msgstr "Неправельное имя."
+
+#: src/finish.c:408
+msgid "Enter name to go on plaque (up to 30 characters): "
+msgstr "Введите своё имя для грамоты (до 30 знаков): "
+
+#: src/finish.c:432
+#, c-format
+msgid ""
+"                                                       U. S. S. ENTERPRISE\n"
+msgstr "                                                       ЭНТЕРПРАЙЗ\n"
+
+#: src/finish.c:434
+#, c-format
+msgid ""
+"                                  For demonstrating outstanding ability as a "
+"starship captain\n"
+msgstr "                                  За проявленный героизм\n"
+
+#: src/finish.c:436
+#, c-format
+msgid ""
+"                                                Starfleet Command bestows to "
+"you\n"
+msgstr ""
+"                                                Штаб Звёздного Флота "
+"присваивает вам\n"
+
+#: src/finish.c:439
+#, c-format
+msgid ""
+"                                                           the rank of\n"
+"\n"
+msgstr ""
+"                                                           звание\n"
+"\n"
+
+#: src/finish.c:440
+#, c-format
+msgid ""
+"                                                       \"Commodore Emeritus"
+"\"\n"
+"\n"
+msgstr ""
+"                                                       \"Отставного Капитана"
+"\"\n"
+"\n"
+
+#: src/finish.c:443
+#, c-format
+msgid ""
+" Expert level\n"
+"\n"
+msgstr ""
+" Уровень Специалиста\n"
+"\n"
+
+#: src/finish.c:444
+#, c-format
+msgid ""
+"Emeritus level\n"
+"\n"
+msgstr ""
+"Уровень Отставника\n"
+"\n"
+
+#: src/finish.c:445
+#, c-format
+msgid ""
+" Cheat level\n"
+"\n"
+msgstr ""
+" Уровень Мошенника\n"
+"\n"
+
+#: src/finish.c:449
+#, c-format
+msgid ""
+"                                                 This day of %.6s %.4s, "
+"%.8s\n"
+"\n"
+msgstr ""
+"                                                 Сегодня у нас %.6s %.4s, "
+"%.8s\n"
+"\n"
+
+#: src/finish.c:451
+#, c-format
+msgid ""
+"                                                        Your score:  %d\n"
+"\n"
+msgstr ""
+"                                                        Ваш счёт:  %d\n"
+"\n"
+
+#: src/finish.c:452
+#, c-format
+msgid ""
+"                                                    Klingons per stardate:  "
+"%.2f\n"
+msgstr ""
+"                                                    Клингонов в день:  %.2f\n"
index 2959ff1a97ead4080c384c73018e7ad3ef801200..cbc2dfaa2b78d4f9cbf3fd99af4b5d718aedc74e 100644 (file)
@@ -1,5 +1,7 @@
 AM_CFLAGS = -Wall -Wimplicit -Wunused -Wmissing-prototypes \
-    -Wuninitialized -fno-inline -O1 -DDATA_DIR=\"$(pkgdatadir)\" @CFLAGS@
+    -Wuninitialized -fno-inline -O1 -DDATA_DIR=\"$(pkgdatadir)\" \
+    -DLOCALEDIR=\"$(datadir)/locale\" \
+    @CFLAGS@
 
 bin_PROGRAMS = sst
 
index 2d5b8aeae59d78a1f3e8b9a921cd874c0f064b68..4d655d65fee6ca6e6c1213054b5313f2030b32df 100644 (file)
@@ -170,7 +170,9 @@ sharedstatedir = @sharedstatedir@
 sysconfdir = @sysconfdir@
 target_alias = @target_alias@
 AM_CFLAGS = -Wall -Wimplicit -Wunused -Wmissing-prototypes \
-    -Wuninitialized -fno-inline -O1 -DDATA_DIR=\"$(pkgdatadir)\" @CFLAGS@
+    -Wuninitialized -fno-inline -O1 -DDATA_DIR=\"$(pkgdatadir)\" \
+    -DLOCALEDIR=\"$(datadir)/locale\" \
+    @CFLAGS@
 
 sst_SOURCES = \
        ai.c \
index 4b1aa23b274ef783850492f21d3c50ea78b1ee2d..660f32828e48f54cecef5bd5650e2b8987a216f1 100644 (file)
--- a/src/ai.c
+++ b/src/ai.c
@@ -27,7 +27,7 @@ static int tryexit(int lookx, int looky, int ienm, int loccom, int irun)
     if (game.damage[DSRSENS] == 0.0 || game.damage[DLRSENS] == 0.0 ||
        game.condit == IHDOCKED) {
        crmena(1, ienm, 2, game.kx[loccom], game.ky[loccom]);
-       prout(" escapes to %s (and regains strength).",
+       prout(_(" escapes to %s (and regains strength)."),
              cramlc(quadrant, iqx, iqy));
     }
     /* handle local matters related to escape */
@@ -157,7 +157,7 @@ static void movebaddy(int comx, int comy, int loccom, int ienm)
 #ifdef DEBUG
        if (game.idebug) {
            proutn("MOTION = %1.2f", motion);
-           proutn("  FORCES = %1,2f", forces);
+           proutn("  FORCES = %1.2f", forces);
        }
 #endif
        /* don't move if no motion */
@@ -255,9 +255,9 @@ static void movebaddy(int comx, int comy, int loccom, int ienm)
        if (game.damage[DSRSENS] == 0 || game.condit == IHDOCKED) {
            proutn("***");
            cramen(ienm);
-           proutn(" from %s", cramlc(2, comx, comy));
-           if (game.kdist[loccom] < dist1) proutn(" advances to ");
-           else proutn(" retreats to ");
+           proutn(_(" from %s"), cramlc(2, comx, comy));
+           if (game.kdist[loccom] < dist1) proutn(_(" advances to "));
+           else proutn(_(" retreats to "));
            prout(cramlc(sector, nextx, nexty));
        }
     }
@@ -355,11 +355,11 @@ static int movescom(int iqx, int iqy, int flag, int *ipage)
            if (game.damage[DRADIO] == 0.0 || game.condit == IHDOCKED) {
                if (*ipage==0) pause_game(1);
                *ipage = 1;
-               prout("Lt. Uhura-  \"Captain, Starfleet Intelligence reports");
-               proutn("   a planet in ");
+               prout(_("Lt. Uhura-  \"Captain, Starfleet Intelligence reports"));
+               proutn(_("   a planet in "));
                proutn(cramlc(quadrant, game.state.isx, game.state.isy));
-               prout(" has been destroyed");
-               prout("   by the Super-commander.\"");
+               prout(_(" has been destroyed"));
+               prout(_("   by the Super-commander.\""));
            }
            break;
        }
@@ -517,14 +517,14 @@ void scom(int *ipage)
            game.iseenit = 1;
            if (*ipage == 0)  pause_game(1);
            *ipage=1;
-           proutn("Lt. Uhura-  \"Captain, the starbase in ");
+           proutn(_("Lt. Uhura-  \"Captain, the starbase in "));
            proutn(cramlc(quadrant, game.state.isx, game.state.isy));
            skip(1);
-           prout("   reports that it is under attack from the Klingon Super-commander.");
-           proutn("   It can survive until stardate %d.\"",
+           prout(_("   reports that it is under attack from the Klingon Super-commander."));
+           proutn(_("   It can survive until stardate %d.\""),
                   (int)game.future[FSCDBAS]);
            if (game.resting==0) return;
-           prout("Mr. Spock-  \"Captain, shall we cancel the rest period?\"");
+           prout(_("Mr. Spock-  \"Captain, shall we cancel the rest period?\""));
            if (ja()==0) return;
            game.resting = 0;
            game.optime = 0.0; /* actually finished */
@@ -542,8 +542,8 @@ void scom(int *ipage)
        return;
     if (*ipage==0) pause_game(1);
     *ipage = 1;
-    prout("Lt. Uhura-  \"Captain, Starfleet Intelligence reports");
-    proutn("   the Super-commander is in ");
+    prout(_("Lt. Uhura-  \"Captain, Starfleet Intelligence reports"));
+    proutn(_("   the Super-commander is in "));
     proutn(cramlc(quadrant, game.state.isx, game.state. isy));
     prout(".\"");
     return;
@@ -608,7 +608,7 @@ void movetho(void)
     game.quad[game.ithx][game.ithy]=IHWEB;
     dropin(IHBLANK, &dum, &my);
     crmena(1,IHT, 2, game.ithx, game.ithy);
-    prout(" completes web.");
+    prout(_(" completes web."));
     game.ithere = game.ithx = game.ithy = 0;
     game.nenhere--;
     return;
index 58ed4c2b997edf0541c16b281d40b3db4212144d..834e106df826091db8cc6cb5a6c198680f3b6dac 100644 (file)
@@ -16,7 +16,7 @@ void doshield(int i)
            else {
                chew();
                if (game.damage[DSHIELD]) {
-                   prout("Shields damaged and down.");
+                   prout(_("Shields damaged and down."));
                    return;
                }
                if (isit("up"))
@@ -26,17 +26,17 @@ void doshield(int i)
            }
        }
        if (action==NONE) {
-           proutn("Do you wish to change shield energy? ");
+           proutn(_("Do you wish to change shield energy? "));
            if (ja()) {
-               proutn("Energy to transfer to shields- ");
+               proutn(_("Energy to transfer to shields- "));
                action = NRG;
            }
            else if (game.damage[DSHIELD]) {
-               prout("Shields damaged and down.");
+               prout(_("Shields damaged and down."));
                return;
            }
            else if (game.shldup) {
-               proutn("Shields are up. Do you want them down? ");
+               proutn(_("Shields are up. Do you want them down? "));
                if (ja()) action = SHDN;
                else {
                    chew();
@@ -44,7 +44,7 @@ void doshield(int i)
                }
            }
            else {
-               proutn("Shields are down. Do you want them up? ");
+               proutn(_("Shields are down. Do you want them up? "));
                if (ja()) action = SHUP;
                else {
                    chew();
@@ -56,16 +56,16 @@ void doshield(int i)
     switch (action) {
     case SHUP: /* raise shields */
        if (game.shldup) {
-           prout("Shields already up.");
+           prout(_("Shields already up."));
            return;
        }
        game.shldup = 1;
        game.shldchg = 1;
        if (game.condit != IHDOCKED) game.energy -= 50.0;
-       prout("Shields raised.");
+       prout(_("Shields raised."));
        if (game.energy <= 0) {
            skip(1);
-           prout("Shields raising uses up last of energy.");
+           prout(_("Shields raising uses up last of energy."));
            finish(FNRG);
            return;
        }
@@ -73,30 +73,30 @@ void doshield(int i)
        return;
     case SHDN:
        if (game.shldup==0) {
-           prout("Shields already down.");
+           prout(_("Shields already down."));
            return;
        }
        game.shldup=0;
        game.shldchg=1;
-       prout("Shields lowered.");
+       prout(_("Shields lowered."));
        game.ididit=1;
        return;
     case NRG:
        while (scan() != IHREAL) {
            chew();
-           proutn("Energy to transfer to shields- ");
+           proutn(_("Energy to transfer to shields- "));
        }
        chew();
        if (aaitem==0) return;
        if (aaitem > game.energy) {
-           prout("Insufficient ship energy.");
+           prout(_("Insufficient ship energy."));
            return;
        }
        game.ididit = 1;
        if (game.shield+aaitem >= game.inshld) {
-           prout("Shield energy maximized.");
+           prout(_("Shield energy maximized."));
            if (game.shield+aaitem > game.inshld) {
-               prout("Excess energy requested returned to ship energy");
+               prout(_("Excess energy requested returned to ship energy"));
            }
            game.energy -= game.inshld-game.shield;
            game.shield = game.inshld;
@@ -105,23 +105,23 @@ void doshield(int i)
        if (aaitem < 0.0 && game.energy-aaitem > game.inenrg) {
            /* Prevent shield drain loophole */
            skip(1);
-           prout("Engineering to bridge--");
-           prout("  Scott here. Power circuit problem, Captain.");
-           prout("  I can't drain the shields.");
+           prout(_("Engineering to bridge--"));
+           prout(_("  Scott here. Power circuit problem, Captain."));
+           prout(_("  I can't drain the shields."));
            game.ididit = 0;
            return;
        }
        if (game.shield+aaitem < 0) {
-           prout("All shield energy transferred to ship.");
+           prout(_("All shield energy transferred to ship."));
            game.energy += game.shield;
            game.shield = 0.0;
            return;
        }
-       proutn("Scotty- \"");
+       proutn(_("Scotty- \""));
        if (aaitem > 0)
-           prout("Transferring energy to shields.\"");
+           prout(_("Transferring energy to shields.\""));
        else
-           prout("Draining energy from shields.\"");
+           prout(_("Draining energy from shields.\""));
        game.shield += aaitem;
        game.energy -= aaitem;
        return;
@@ -134,9 +134,9 @@ void ram(int ibumpd, int ienm, int ix, int iy)
     double type = 1.0, extradm;
     int icas, l;
        
-    prouts("***RED ALERT!  RED ALERT!");
+    prouts(_("***RED ALERT!  RED ALERT!"));
     skip(1);
-    prout("***COLLISION IMMINENT.");
+    prout(_("***COLLISION IMMINENT."));
     skip(2);
     proutn("***");
     crmshp();
@@ -147,16 +147,16 @@ void ram(int ibumpd, int ienm, int ix, int iy)
     case IHT: type = 0.5; break;
     case IHQUEST: type = 4.0; break;
     }
-    proutn(ibumpd ? " rammed by " : " rams ");
+    proutn(ibumpd ? _(" rammed by ") : _(" rams "));
     crmena(0, ienm, 2, ix, iy);
-    if (ibumpd) proutn(" (original position)");
+    if (ibumpd) proutn(_(" (original position)"));
     skip(1);
     deadkl(ix, iy, ienm, game.sectx, game.secty);
     proutn("***");
     crmshp();
-    prout(" heavily damaged.");
+    prout(_(" heavily damaged."));
     icas = 10.0+20.0*Rand();
-    prout("***Sickbay reports %d casualties", icas);
+    prout(_("***Sickbay reports %d casualties"), icas);
     game.casual += icas;
     for (l=0; l < NDEVICES; l++) {
        if (l == DDRAY) 
@@ -210,7 +210,7 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
        case IHE: /* Hit our ship */
        case IHF:
            skip(1);
-           proutn("Torpedo hits ");
+           proutn(_("Torpedo hits "));
            crmshp();
            prout(".");
            *hit = 700.0 + 100.0*Rand() -
@@ -246,8 +246,8 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
        case IHS:
            if (Rand() <= 0.05) {
                crmena(1, iquad, 2, ix, iy);
-               prout(" uses anti-photon device;");
-               prout("   torpedo neutralized.");
+               prout(_(" uses anti-photon device;"));
+               prout(_("   torpedo neutralized."));
                return;
            }
        case IHR: /* Hit a regular enemy */
@@ -276,27 +276,27 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
            jx=ix+xx+0.5;
            jy=iy+yy+0.5;
            if (!VALID_SECTOR(jx, jy)) {
-               prout(" damaged but not destroyed.");
+               prout(_(" damaged but not destroyed."));
                return;
            }
            if (game.quad[jx][jy]==IHBLANK) {
-               prout(" buffeted into black hole.");
+               prout(_(" buffeted into black hole."));
                deadkl(ix, iy, iquad, jx, jy);
                return;
            }
            if (game.quad[jx][jy]!=IHDOT) {
                /* can't move into object */
-               prout(" damaged but not destroyed.");
+               prout(_(" damaged but not destroyed."));
                return;
            }
-           proutn(" damaged--");
+           proutn(_(" damaged--"));
            game.kx[ll] = jx;
            game.ky[ll] = jy;
            shoved = 1;
            break;
        case IHB: /* Hit a base */
            skip(1);
-           prout("***STARBASE DESTROYED..");
+           prout(_("***STARBASE DESTROYED.."));
            for_starbases(ll) {
                if (game.state.baseqx[ll]==game.quadx && game.state.baseqy[ll]==game.quady) {
                    game.state.baseqx[ll]=game.state.baseqx[game.state.rembase];
@@ -314,7 +314,7 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
            return;
        case IHP: /* Hit a planet */
            crmena(1, iquad, 2, ix, iy);
-           prout(" destroyed.");
+           prout(_(" destroyed."));
            game.state.nplankl++;
            game.state.galaxy[game.quadx][game.quady].planet = NULL;
            DESTROY(&game.state.plnets[game.iplnet]);
@@ -332,17 +332,17 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
                return;
            }
            crmena(1, IHSTAR, 2, ix, iy);
-           prout(" unaffected by photon blast.");
+           prout(_(" unaffected by photon blast."));
            return;
        case IHQUEST: /* Hit a thingy */
            if (!(game.options & OPTION_THINGY) || Rand()>0.7) {
                skip(1);
-               prouts("AAAAIIIIEEEEEEEEAAAAAAAAUUUUUGGGGGHHHHHHHHHHHH!!!");
+               prouts(_("AAAAIIIIEEEEEEEEAAAAAAAAUUUUUGGGGGHHHHHHHHHHHH!!!"));
                skip(1);
-               prouts("    HACK!     HACK!    HACK!        *CHOKE!*  ");
+               prouts(_("    HACK!     HACK!    HACK!        *CHOKE!*  "));
                skip(1);
-               proutn("Mr. Spock-");
-               prouts("  \"Fascinating!\"");
+               proutn(_("Mr. Spock-"));
+               prouts(_("  \"Fascinating!\""));
                skip(1);
                deadkl(ix, iy, iquad, ix, iy);
            } else {
@@ -358,11 +358,11 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
        case IHBLANK: /* Black hole */
            skip(1);
            crmena(1, IHBLANK, 2, ix, iy);
-           prout(" swallows torpedo.");
+           prout(_(" swallows torpedo."));
            return;
        case IHWEB: /* hit the web */
            skip(1);
-           prout("***Torpedo absorbed by Tholian web.");
+           prout(_("***Torpedo absorbed by Tholian web."));
            return;
        case IHT:  /* Hit a Tholian */
            h1 = 700.0 + 100.0*Rand() -
@@ -379,10 +379,10 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
            skip(1);
            crmena(1, IHT, 2, ix, iy);
            if (Rand() > 0.05) {
-               prout(" survives photon blast.");
+               prout(_(" survives photon blast."));
                return;
            }
-           prout(" disappears.");
+           prout(_(" disappears."));
            game.quad[ix][iy] = IHWEB;
            game.ithere = game.ithx = game.ithy = 0;
            game.nenhere--;
@@ -407,14 +407,14 @@ void torpedo(double course, double r, int inx, int iny, double *hit, int i, int
     if (shoved) {
        game.quad[jx][jy]=iquad;
        game.quad[ix][iy]=IHDOT;
-       prout(" displaced by blast to %s ", cramlc(sector, jx, jy));
+       prout(_(" displaced by blast to %s "), cramlc(sector, jx, jy));
        for_local_enemies(ll)
            game.kdist[ll] = game.kavgd[ll] = sqrt(square(game.sectx-game.kx[ll])+square(game.secty-game.ky[ll]));
        sortkl();
        return;
     }
     skip(1);
-    prout("Torpedo missed.");
+    prout(_("Torpedo missed."));
     return;
 }
 
@@ -427,7 +427,7 @@ static void fry(double hit)
     if (hit < (275.0-25.0*game.skill)*(1.0+0.5*Rand())) return;
 
     ncrit = 1.0 + hit/(500.0+100.0*Rand());
-    proutn("***CRITICAL HIT--");
+    proutn(_("***CRITICAL HIT--"));
     /* Select devices and cause damage */
     for (l = 0; l < ncrit && 0 < NDEVICES; l++) {
        do {
@@ -443,13 +443,13 @@ static void fry(double hit)
            if (ll<=l) continue;
            ktr += 1;
            if (ktr==3) skip(1);
-           proutn(" and ");
+           proutn(_(" and "));
        }
        proutn(device[j]);
     }
-    prout(" damaged.");
+    prout(_(" damaged."));
     if (game.damage[DSHIELD] && game.shldup) {
-       prout("***Shields knocked down.");
+       prout(_("***Shields knocked down."));
        game.shldup=0;
     }
 }
@@ -507,9 +507,9 @@ void attack(int torps_ok)
        else { /* Enemy used photon torpedo */
            double course = 1.90985*atan2((double)game.secty-jy, (double)jx-game.sectx);
            hit = 0;
-           proutn("***TORPEDO INCOMING");
+           proutn(_("***TORPEDO INCOMING"));
            if (game.damage[DSRSENS] <= 0.0) {
-               proutn(" From ");
+               proutn(_(" From "));
                crmena(0, iquad, i, jx, jy);
            }
            attempt = 1;
@@ -541,13 +541,13 @@ void attack(int torps_ok)
                       shields were down for some strange reason. This
                       doesn't make any sense, so I've fixed it */
        ihurt = 1;
-       proutn("%d unit hit", (int)hit);
+       proutn(_("%d unit hit"), (int)hit);
        if ((game.damage[DSRSENS] > 0 && itflag) || game.skill<=SKILL_FAIR) {
-           proutn(" on the ");
+           proutn(_(" on the "));
            crmshp();
        }
        if (game.damage[DSRSENS] <= 0.0 && itflag) {
-           proutn(" from ");
+           proutn(_(" from "));
            crmena(0, iquad, i, jx, jy);
        }
        skip(1);
@@ -555,7 +555,6 @@ void attack(int torps_ok)
        if (hit > hitmax) hitmax = hit;
        hittot += hit;
        fry(hit);
-       prout("Hit %g energy %g", hit, game.energy);
        game.energy -= hit;
        if (game.condit==IHDOCKED) 
            dock(0);
@@ -566,29 +565,29 @@ void attack(int torps_ok)
        return;
     }
     if (attempt == 0 && game.condit == IHDOCKED)
-       prout("***Enemies decide against attacking your ship.");
+       prout(_("***Enemies decide against attacking your ship."));
     if (atackd == 0) return;
     percent = 100.0*pfac*game.shield+0.5;
     if (ihurt==0) {
        /* Shields fully protect ship */
-       proutn("Enemy attack reduces shield strength to ");
+       proutn(_("Enemy attack reduces shield strength to "));
     }
     else {
        /* Print message if starship suffered hit(s) */
        skip(1);
-       proutn("Energy left %2d    shields ", (int)game.energy);
-       if (game.shldup) proutn("up ");
-       else if (game.damage[DSHIELD] == 0) proutn("down ");
-       else proutn("damaged, ");
+       proutn(_("Energy left %2d    shields "), (int)game.energy);
+       if (game.shldup) proutn(_("up "));
+       else if (game.damage[DSHIELD] == 0) proutn(_("down "));
+       else proutn(_("damaged, "));
     }
-    prout("%d%%,   torpedoes left %d", percent, game.torps);
+    prout(_("%d%%,   torpedoes left %d"), percent, game.torps);
     /* Check if anyone was hurt */
     if (hitmax >= 200 || hittot >= 500) {
        int icas= hittot*Rand()*0.015;
        if (icas >= 2) {
            skip(1);
-           prout("Mc Coy-  \"Sickbay to bridge.  We suffered %d casualties", icas);
-           prout("   in that last attack.\"");
+           prout(_("Mc Coy-  \"Sickbay to bridge.  We suffered %d casualties"), icas);
+           prout(_("   in that last attack.\""));
            game.casual += icas;
        }
     }
@@ -652,7 +651,7 @@ void deadkl(int ix, int iy, int type, int ixx, int iyy)
     }
 
     /* For each kind of enemy, finish message to player */
-    prout(" destroyed.");
+    prout(_(" destroyed."));
     game.quad[ix][iy] = IHDOT;
     if (KLINGREM==0) return;
 
@@ -692,9 +691,9 @@ static int targetcheck(double x, double y, double *course)
     delty = 0.1*(game.sectx - x);
     if (deltx==0 && delty== 0) {
        skip(1);
-       prout("Spock-  \"Bridge to sickbay.  Dr. McCoy,");
-       prout("  I recommend an immediate review of");
-       prout("  the Captain's psychological profile.\"");
+       prout(_("Spock-  \"Bridge to sickbay.  Dr. McCoy,"));
+       prout(_("  I recommend an immediate review of"));
+       prout(_("  the Captain's psychological profile.\""));
        chew();
        return 1;
     }
@@ -711,12 +710,12 @@ void photon(void)
     game.ididit = 0;
 
     if (game.damage[DPHOTON]) {
-       prout("Photon tubes damaged.");
+       prout(_("Photon tubes damaged."));
        chew();
        return;
     }
     if (game.torps == 0) {
-       prout("No torpedoes left.");
+       prout(_("No torpedoes left."));
        chew();
        return;
     }
@@ -727,8 +726,8 @@ void photon(void)
            return;
        }
        else if (key == IHEOL) {
-           prout("%d torpedoes left.", game.torps);
-           proutn("Number of torpedoes to fire- ");
+           prout(_("%d torpedoes left."), game.torps);
+           proutn(_("Number of torpedoes to fire- "));
            key = scan();
        }
        else /* key == IHREAL */ {
@@ -739,7 +738,7 @@ void photon(void)
            }
            if (n > 3) {
                chew();
-               prout("Maximum of 3 torpedoes per burst.");
+               prout(_("Maximum of 3 torpedoes per burst."));
                key = IHEOL;
                return;
            }
@@ -780,7 +779,7 @@ void photon(void)
     if (i == 1 && key == IHEOL) {
        /* prompt for each one */
        for (i = 1; i <= n; i++) {
-           proutn("Target sector for torpedo number %d- ", i);
+           proutn(_("Target sector for torpedo number %d- "), i);
            key = scan();
            if (key != IHREAL) {
                huh();
@@ -807,15 +806,15 @@ void photon(void)
            /* misfire! */
            r = (Rand()+1.2) * r;
            if (n>1) {
-               prouts("***TORPEDO NUMBER %d MISFIRES", i);
+               prouts(_("***TORPEDO NUMBER %d MISFIRES"), i);
            }
-           else prouts("***TORPEDO MISFIRES.");
+           else prouts(_("***TORPEDO MISFIRES."));
            skip(1);
            if (i < n)
-               prout("  Remainder of burst aborted.");
+               prout(_("  Remainder of burst aborted."));
            osuabor=1;
            if (Rand() <= 0.2) {
-               prout("***Photon tubes damaged by misfire.");
+               prout(_("***Photon tubes damaged by misfire."));
                game.damage[DPHOTON] = game.damfac*(1.0+2.0*Rand());
                break;
            }
@@ -836,7 +835,7 @@ static void overheat(double rpow)
     if (rpow > 1500) {
        double chekbrn = (rpow-1500.)*0.00038;
        if (Rand() <= chekbrn) {
-           prout("Weapons officer Sulu-  \"Phasers overheated, sir.\"");
+           prout(_("Weapons officer Sulu-  \"Phasers overheated, sir.\""));
            game.damage[DPHASER] = game.damfac*(1.0 + Rand()) * (1.0+chekbrn);
        }
     }
@@ -849,37 +848,37 @@ static int checkshctrl(double rpow)
        
     skip(1);
     if (Rand() < .998) {
-       prout("Shields lowered.");
+       prout(_("Shields lowered."));
        return 0;
     }
     /* Something bad has happened */
-    prouts("***RED ALERT!  RED ALERT!");
+    prouts(_("***RED ALERT!  RED ALERT!"));
     skip(2);
     hit = rpow*game.shield/game.inshld;
     game.energy -= rpow+hit*0.8;
     game.shield -= hit*0.2;
     if (game.energy <= 0.0) {
-       prouts("Sulu-  \"Captain! Shield malf***********************\"");
+       prouts(_("Sulu-  \"Captain! Shield malf***********************\""));
        skip(1);
        stars();
        finish(FPHASER);
        return 1;
     }
-    prouts("Sulu-  \"Captain! Shield malfunction! Phaser fire contained!\"");
+    prouts(_("Sulu-  \"Captain! Shield malfunction! Phaser fire contained!\""));
     skip(2);
-    prout("Lt. Uhura-  \"Sir, all decks reporting damage.\"");
+    prout(_("Lt. Uhura-  \"Sir, all decks reporting damage.\""));
     icas = hit*Rand()*0.012;
     skip(1);
     fry(0.8*hit);
     if (icas) {
        skip(1);
-       prout("McCoy to bridge- \"Severe radiation burns, Jim.");
-       prout("  %d casualties so far.\"", icas);
+       prout(_("McCoy to bridge- \"Severe radiation burns, Jim."));
+       prout(_("  %d casualties so far.\""), icas);
        game.casual -= icas;
     }
     skip(1);
-    prout("Phaser energy dispersed by shields.");
-    prout("Enemy unaffected.");
+    prout(_("Phaser energy dispersed by shields."));
+    prout(_("Enemy unaffected."));
     overheat(rpow);
     return 1;
 }
@@ -897,27 +896,27 @@ void phasers(void)
     /* SR sensors and Computer */
     if (game.damage[DSRSENS]+game.damage[DCOMPTR] > 0) ipoop = 0;
     if (game.condit == IHDOCKED) {
-       prout("Phasers can't be fired through base shields.");
+       prout(_("Phasers can't be fired through base shields."));
        chew();
        return;
     }
     if (game.damage[DPHASER] != 0) {
-       prout("Phaser control damaged.");
+       prout(_("Phaser control damaged."));
        chew();
        return;
     }
     if (game.shldup) {
        if (game.damage[DSHCTRL]) {
-           prout("High speed shield control damaged.");
+           prout(_("High speed shield control damaged."));
            chew();
            return;
        }
        if (game.energy <= 200.0) {
-           prout("Insufficient energy to activate high-speed shield control.");
+           prout(_("Insufficient energy to activate high-speed shield control."));
            chew();
            return;
        }
-       prout("Weapons Officer Sulu-  \"High-speed shield control enabled, sir.\"");
+       prout(_("Weapons Officer Sulu-  \"High-speed shield control enabled, sir.\""));
        ifast = 1;
                
     }
@@ -927,7 +926,7 @@ void phasers(void)
        if (key == IHALPHA) {
            if (isit("manual")) {
                if (game.nenhere==0) {
-                   prout("There is no enemy present to select.");
+                   prout(_("There is no enemy present to select."));
                    chew();
                    key = IHEOL;
                    automode=AUTOMATIC;
@@ -943,7 +942,7 @@ void phasers(void)
                }
                else {
                    if (game.nenhere==0)
-                       prout("Energy will be expended into space.");
+                       prout(_("Energy will be expended into space."));
                    automode = AUTOMATIC;
                    key = scan();
                }
@@ -958,7 +957,7 @@ void phasers(void)
        }
        else if (key == IHREAL) {
            if (game.nenhere==0) {
-               prout("Energy will be expended into space.");
+               prout(_("Energy will be expended into space."));
                automode = AUTOMATIC;
            }
            else if (!ipoop)
@@ -969,13 +968,13 @@ void phasers(void)
        else {
            /* IHEOL */
            if (game.nenhere==0) {
-               prout("Energy will be expended into space.");
+               prout(_("Energy will be expended into space."));
                automode = AUTOMATIC;
            }
            else if (!ipoop)
                automode = FORCEMAN;
            else 
-               proutn("Manual or automatic? ");
+               proutn(_("Manual or automatic? "));
        }
     }
                                
@@ -986,7 +985,7 @@ void phasers(void)
            key = scan();
        }
        if (key != IHREAL && game.nenhere != 0) {
-           prout("Phasers locked on target. Energy available: %.2f",
+           prout(_("Phasers locked on target. Energy available: %.2f"),
                  ifast?game.energy-200.0:game.energy,1,2);
        }
        irec=0;
@@ -996,14 +995,14 @@ void phasers(void)
                irec+=fabs(game.kpower[i])/(PHASEFAC*pow(0.90,game.kdist[i]))*
                    (1.01+0.05*Rand()) + 1.0;
            kz=1;
-           proutn("(%d) units required. ", irec);
+           proutn(_("(%d) units required. "), irec);
            chew();
-           proutn("Units to fire= ");
+           proutn(_("Units to fire= "));
            key = scan();
            if (key!=IHREAL) return;
            rpow = aaitem;
            if (rpow > (ifast?game.energy-200:game.energy)) {
-               proutn("Energy available= %.2f",
+               proutn(_("Energy available= %.2f"),
                       ifast?game.energy-200:game.energy);
                skip(1);
                key = IHEOL;
@@ -1044,12 +1043,12 @@ void phasers(void)
        }
        if (extra > 0 && game.alldone == 0) {
            if (game.ithere) {
-               proutn("*** Tholian web absorbs ");
-               if (game.nenhere>0) proutn("excess ");
-               prout("phaser energy.");
+               proutn(_("*** Tholian web absorbs "));
+               if (game.nenhere>0) proutn(_("excess "));
+               prout(_("phaser energy."));
            }
            else {
-               prout("%d expended on empty space.", (int)extra);
+               prout(_("%d expended on empty space."), (int)extra);
            }
        }
        break;
@@ -1058,14 +1057,14 @@ void phasers(void)
        chew();
        key = IHEOL;
        if (game.damage[DCOMPTR]!=0)
-           prout("Battle comuter damaged, manual file only.");
+           prout(_("Battle comuter damaged, manual file only."));
        else {
            skip(1);
-           prouts("---WORKING---");
+           prouts(_("---WORKING---"));
            skip(1);
-           prout("Short-range-sensors-damaged");
-           prout("Insufficient-data-for-automatic-phaser-fire");
-           prout("Manual-fire-must-be-used");
+           prout(_("Short-range-sensors-damaged"));
+           prout(_("Insufficient-data-for-automatic-phaser-fire"));
+           prout(_("Manual-fire-must-be-used"));
            skip(1);
        }
     case MANUAL:
@@ -1074,7 +1073,7 @@ void phasers(void)
            int ii = game.kx[k], jj = game.ky[k];
            int ienm = game.quad[ii][jj];
            if (msgflag) {
-               proutn("Energy available= %.2f",
+               proutn(_("Energy available= %.2f"),
                       game.energy-.006-(ifast?200:0));
                skip(1);
                msgflag = 0;
@@ -1083,7 +1082,7 @@ void phasers(void)
            if (game.damage[DSRSENS] && !(abs(game.sectx-ii) < 2 && abs(game.secty-jj) < 2) &&
                (ienm == IHC || ienm == IHS)) {
                cramen(ienm);
-               prout(" can't be located without short range scan.");
+               prout(_(" can't be located without short range scan."));
                chew();
                key = IHEOL;
                hits[k] = 0; /* prevent overflow -- thanks to Alexei Voitenko */
@@ -1100,7 +1099,7 @@ void phasers(void)
                if (game.damage[DCOMPTR]==0) proutn("%d", irec);
                else proutn("??");
                proutn(")  ");
-               proutn("units to fire at ");
+               proutn(_("units to fire at "));
                crmena(0, ienm, 2, ii, jj);
                proutn("-  ");
                key = scan();
@@ -1130,7 +1129,7 @@ void phasers(void)
            /* If total requested is too much, inform and start over */
                                
            if (rpow > (ifast?game.energy-200:game.energy)) {
-               prout("Available energy exceeded -- try again.");
+               prout(_("Available energy exceeded -- try again."));
                chew();
                return;
            }
@@ -1162,13 +1161,13 @@ void phasers(void)
        skip(1);
        if (no == 0) {
            if (Rand() >= 0.99) {
-               prout("Sulu-  \"Sir, the high-speed shield control has malfunctioned . . .");
-               prouts("         CLICK   CLICK   POP  . . .");
-               prout(" No  response, sir!");
+               prout(_("Sulu-  \"Sir, the high-speed shield control has malfunctioned . . ."));
+               prouts(_("         CLICK   CLICK   POP  . . ."));
+               prout(_(" No response, sir!"));
                game.shldup = 0;
            }
            else
-               prout("Shields raised.");
+               prout(_("Shields raised."));
        }
        else
            game.shldup = 0;
@@ -1197,10 +1196,10 @@ void hittem(double *hits)
        if (hit > 0.005) {
            if (game.damage[DSRSENS]==0)
                boom(ii, jj);
-           proutn("%d unit hit on ", (int)hit);
+           proutn(_("%d unit hit on "), (int)hit);
        }
        else
-           proutn("Very small hit on ");
+           proutn(_("Very small hit on "));
        ienm = game.quad[ii][jj];
        if (ienm==IHQUEST) iqengry=1;
        crmena(0,ienm,2,ii,jj);
@@ -1214,9 +1213,9 @@ void hittem(double *hits)
        else /* decide whether or not to emasculate klingon */
            if (kpow > 0 && Rand() >= 0.9 &&
                kpow <= ((0.4 + 0.4*Rand())*kpini)) {
-               prout("***Mr. Spock-  \"Captain, the vessel at ",
+               prout(_("***Mr. Spock-  \"Captain, the vessel at "),
                      cramlc(sector,ii,jj));
-               prout("   has just lost its firepower.\"");
+               prout(_("   has just lost its firepower.\""));
                game.kpower[kk] = -kpow;
            }
     }
index e7e9567c7eb46191821e864c521409e991280c67..dc81f56e86dfb70638c872571475c8285555d2b4 100644 (file)
@@ -50,15 +50,15 @@ void events(void)
                game.damage[l] -= (game.damage[l]-repair > 0.0 ? repair : game.damage[l]);
        /* If radio repaired, update star chart and attack reports */
        if (radio_was_broken && game.damage[DRADIO] == 0.0) {
-           prout("Lt. Uhura- \"Captain, the sub-space radio is working and");
-           prout("   surveillance reports are coming in.");
+           prout(_("Lt. Uhura- \"Captain, the sub-space radio is working and"));
+           prout(_("   surveillance reports are coming in."));
            skip(1);
            if (game.iseenit==0) {
                attakreport(0);
                game.iseenit = 1;
            }
            rechart();
-           prout("   The star chart is now up to date.\"");
+           prout(_("   The star chart is now up to date.\""));
            skip(1);
        }
        /* Cause extraneous event LINE to occur */
@@ -111,7 +111,7 @@ void events(void)
            skip(1);
            proutn("***");
            crmshp();
-           prout(" caught in long range tractor beam--");
+           prout(_(" caught in long range tractor beam--"));
            /* If Kirk & Co. screwing around on planet, handle */
            atover(1); /* atover(1) is Grab */
            if (game.alldone) return;
@@ -123,13 +123,13 @@ void events(void)
            if (game.iscraft==0) {
                skip(1);
                if (Rand() > 0.5) {
-                   prout("Galileo, left on the planet surface, is captured");
-                   prout("by aliens and made into a flying McDonald's.");
+                   prout(_("Galileo, left on the planet surface, is captured"));
+                   prout(_("by aliens and made into a flying McDonald's."));
                    game.damage[DSHUTTL] = -10;
                    game.iscraft = -1;
                }
                else {
-                   prout("Galileo, left on the planet surface, is well hidden.");
+                   prout(_("Galileo, left on the planet surface, is well hidden."));
                }
            }
            if (line==0) {
@@ -142,12 +142,12 @@ void events(void)
            }
            iran(QUADSIZE, &game.sectx, &game.secty);
            crmshp();
-           proutn(" is pulled to ");
+           proutn(_(" is pulled to "));
            proutn(cramlc(quadrant, game.quadx, game.quady));
            proutn(", ");
            prout(cramlc(sector, game.sectx, game.secty));
            if (game.resting) {
-               prout("(Remainder of rest/repair period cancelled.)");
+               prout(_("(Remainder of rest/repair period cancelled.)"));
                game.resting = 0;
            }
            if (game.shldup==0) {
@@ -155,7 +155,7 @@ void events(void)
                    doshield(2); /* Shldsup */
                    game.shldchg=0;
                }
-               else prout("(Shields not currently useable.)");
+               else prout(_("(Shields not currently useable.)"));
            }
            newqad(0);
            /* Adjust finish time to time of tractor beaming */
@@ -206,15 +206,15 @@ void events(void)
            if (ipage==0) pause_game(1);
            ipage = 1;
            skip(1);
-           proutn("Lt. Uhura-  \"Captain, the starbase in ");
+           proutn(_("Lt. Uhura-  \"Captain, the starbase in "));
            prout(cramlc(quadrant, game.batx, game.baty));
-           prout("   reports that it is under attack and that it can");
-           proutn("   hold out only until stardate %d",
+           prout(_("   reports that it is under attack and that it can"));
+           proutn(_("   hold out only until stardate %d"),
                   (int)game.future[FCDBAS]);
            prout(".\"");
            if (game.resting) {
                skip(1);
-               proutn("Mr. Spock-  \"Captain, shall we cancel the rest period?\" ");
+               proutn(_("Mr. Spock-  \"Captain, shall we cancel the rest period?\""));
                if (ja()) {
                    game.resting = 0;
                    game.optime = 0.0;
@@ -254,7 +254,7 @@ void events(void)
                game.basex=game.basey=0;
                newcnd();
                skip(1);
-               prout("Spock-  \"Captain, I believe the starbase has been destroyegame.state.\"");
+               prout(_("Spock-  \"Captain, I believe the starbase has been destroyed.\""));
            }
            else if (game.state.rembase != 1 &&
                     (game.damage[DRADIO] <= 0.0 || game.condit == IHDOCKED)) {
@@ -262,12 +262,12 @@ void events(void)
                if (ipage==0) pause_game(1);
                ipage = 1;
                skip(1);
-               prout("Lt. Uhura-  \"Captain, Starfleet Command reports that");
-               proutn("   the starbase in ");
+               prout(_("Lt. Uhura-  \"Captain, Starfleet Command reports that"));
+               proutn(_("   the starbase in "));
                proutn(cramlc(quadrant, game.batx, game.baty));
-               prout(" has been destroyed by");
-               if (game.isatb==2) prout("the Klingon Super-Commander");
-               else prout("a Klingon Commander");
+               prout(_(" has been destroyed by"));
+               if (game.isatb==2) prout(_("the Klingon Super-Commander"));
+               else prout(_("a Klingon Commander"));
                game.state.chart[game.batx][game.baty].starbase = FALSE;
            }
            /* Remove Starbase from galaxy */
@@ -310,11 +310,11 @@ void events(void)
                        if (ipage==0) pause_game(1);
                        ipage = 1;
                        skip(1);
-                       proutn("Lt. Uhura-  \"The deep space probe ");
+                       proutn(_("Lt. Uhura-  \"The deep space probe "));
                        if (!VALID_QUADRANT(j, i))
-                           proutn("has left the galaxy");
+                           proutn(_("has left the galaxy"));
                        else
-                           proutn("is no longer transmitting");
+                           proutn(_("is no longer transmitting"));
                        prout(".\"");
                    }
                    game.future[FDSPROB] = FOREVER;
@@ -324,7 +324,7 @@ void events(void)
                    if (ipage==0) pause_game(1);
                    ipage = 1;
                    skip(1);
-                   proutn("Lt. Uhura-  \"The deep space probe is now in ");
+                   proutn(_("Lt. Uhura-  \"The deep space probe is now in "));
                    proutn(cramlc(quadrant, game.probecx, game.probecy));
                    prout(".\"");
                }
@@ -361,7 +361,7 @@ void wait(void)
     for (;;) {
        key = scan();
        if (key  != IHEOL) break;
-       proutn("How long? ");
+       proutn(_("How long? "));
     }
     chew();
     if (key != IHREAL) {
@@ -371,7 +371,7 @@ void wait(void)
     origTime = delay = aaitem;
     if (delay <= 0.0) return;
     if (delay >= game.state.remtime || game.nenhere != 0) {
-       proutn("Are you sure? ");
+       proutn(_("Are you sure? "));
        if (ja() == 0) return;
     }
 
@@ -381,7 +381,7 @@ void wait(void)
     do {
        if (delay <= 0) game.resting = 0;
        if (game.resting == 0) {
-           prout("%d stardates left.", (int)game.state.remtime);
+           prout(_("%d stardates left."), (int)game.state.remtime);
            return;
        }
        temp = game.optime = delay;
@@ -423,7 +423,7 @@ void nova(int ix, int iy)
     /* handle initial nova */
     game.quad[ix][iy] = IHDOT;
     crmena(1, IHSTAR, 2, ix, iy);
-    prout(" novas.");
+    prout(_(" novas."));
     game.state.galaxy[game.quadx][game.quady].stars--;
     game.state.starkl++;
        
@@ -462,14 +462,14 @@ void nova(int ix, int iy)
                        game.state.galaxy[game.quadx][game.quady].stars -= 1;
                        game.state.starkl++;
                        crmena(1, IHSTAR, 2, ii, jj);
-                       prout(" novas.");
+                       prout(_(" novas."));
                        game.quad[ii][jj] = IHDOT;
                        break;
                    case IHP: /* Destroy planet */
                        game.state.galaxy[game.quadx][game.quady].planet = NULL;
                        game.state.nplankl++;
                        crmena(1, IHP, 2, ii, jj);
-                       prout(" destroyed.");
+                       prout(_(" destroyed."));
                        DESTROY(&game.state.plnets[game.iplnet]);
                        game.iplnet = game.plnetx = game.plnety = 0;
                        if (game.landed == 1) {
@@ -490,12 +490,12 @@ void nova(int ix, int iy)
                        game.state.basekl++;
                        newcnd();
                        crmena(1, IHB, 2, ii, jj);
-                       prout(" destroyed.");
+                       prout(_(" destroyed."));
                        game.quad[ii][jj] = IHDOT;
                        break;
                    case IHE: /* Buffet ship */
                    case IHF:
-                       prout("***Starship buffeted by nova.");
+                       prout(_("***Starship buffeted by nova."));
                        if (game.shldup) {
                            if (game.shield >= 2000.0) game.shield -= 2000.0;
                            else {
@@ -503,7 +503,7 @@ void nova(int ix, int iy)
                                game.energy -= diff;
                                game.shield = 0.0;
                                game.shldup = 0;
-                               prout("***Shields knocked out.");
+                               prout(_("***Shields knocked out."));
                                game.damage[DSHIELD] += 0.005*game.damfac*Rand()*diff;
                            }
                        }
@@ -533,7 +533,7 @@ void nova(int ix, int iy)
                        newcx = ii + ii - hits[mm][1];
                        newcy = jj + jj - hits[mm][2];
                        crmena(1, iquad, 2, ii, jj);
-                       proutn(" damaged");
+                       proutn(_(" damaged"));
                        if (!VALID_SECTOR(newcx, newcy)) {
                            /* can't leave quadrant */
                            skip(1);
@@ -541,7 +541,7 @@ void nova(int ix, int iy)
                        }
                        iquad1 = game.quad[newcx][newcy];
                        if (iquad1 == IHBLANK) {
-                           proutn(", blasted into ");
+                           proutn(_(", blasted into "));
                            crmena(0, IHBLANK, 2, newcx, newcy);
                            skip(1);
                            deadkl(ii, jj, iquad, newcx, newcy);
@@ -552,7 +552,7 @@ void nova(int ix, int iy)
                            skip(1);
                            break;
                        }
-                       proutn(", buffeted to ");
+                       proutn(_(", buffeted to "));
                        proutn(cramlc(sector, newcx, newcy));
                        game.quad[ii][jj] = IHDOT;
                        game.quad[newcx][newcy] = iquad;
@@ -581,7 +581,7 @@ void nova(int ix, int iy)
     if (game.dist == 0.0) return;
     game.optime = 10.0*game.dist/16.0;
     skip(1);
-    prout("Force of nova displaces starship.");
+    prout(_("Force of nova displaces starship."));
     game.iattak=2;     /* Eliminates recursion problem */
     imove();
     game.optime = 10.0*game.dist/16.0;
@@ -638,8 +638,8 @@ void snova(int insx, int insy)
            /* it isn't here, or we just entered (treat as inroute) */
            if (game.damage[DRADIO] == 0.0 || game.condit == IHDOCKED) {
                skip(1);
-               prout("Message from Starfleet Command       Stardate %.2f", game.state.date);
-               prout("     Supernova in %s; caution advised.",
+               prout(_("Message from Starfleet Command       Stardate %.2f"), game.state.date);
+               prout(_("     Supernova in %s; caution advised."),
                      cramlc(quadrant, nqx, nqy));
            }
        }
@@ -664,13 +664,13 @@ void snova(int insx, int insy)
 
     if (incipient) {
        skip(1);
-       prouts("***RED ALERT!  RED ALERT!");
+       prouts(_("***RED ALERT!  RED ALERT!"));
        skip(1);
-       prout("***Incipient supernova detected at ", cramlc(sector, nsx, nsy));
+       prout(_("***Incipient supernova detected at "), cramlc(sector, nsx, nsy));
        nqx = game.quadx;
        nqy = game.quady;
        if (square(nsx-game.sectx) + square(nsy-game.secty) <= 2.1) {
-           proutn("Emergency override attempts t");
+           proutn(_("Emergency override attempts t"));
            prouts("***************");
            skip(1);
            stars();
@@ -741,8 +741,8 @@ void snova(int insx, int insy)
     /* If supernova destroys last klingons give special message */
     if (KLINGREM==0 && (nqx != game.quadx || nqy != game.quady)) {
        skip(2);
-       if (insx == 0) prout("Lucky you!");
-       proutn("A supernova in %s has just destroyed the last Klingons.",
+       if (insx == 0) prout(_("Lucky you!"));
+       proutn(_("A supernova in %s has just destroyed the last Klingons."),
               cramlc(quadrant, nqx, nqy));
        finish(FWON);
        return;
index bcb168eacabf951423f22366cfcb2f3501834e56..c9e83335b56e4e0f0068af62af0a35ecab1dfdd9 100644 (file)
@@ -7,39 +7,40 @@ void dstrct()
     /* Finish with a BANG! */
     chew();
     if (game.damage[DCOMPTR] != 0.0) {
-       prout("Computer damaged; cannot execute destruct sequence.");
+       prout(_("Computer damaged; cannot execute destruct sequence."));
        return;
     }
-    prouts("---WORKING---"); skip(1);
-    prouts("SELF-DESTRUCT-SEQUENCE-ACTIVATED"); skip(1);
+    prouts(_("---WORKING---")); skip(1);
+    prouts(_("SELF-DESTRUCT-SEQUENCE-ACTIVATED")); skip(1);
     prouts("   10"); skip(1);
     prouts("       9"); skip(1);
     prouts("          8"); skip(1);
     prouts("             7"); skip(1);
     prouts("                6"); skip(1);
     skip(1);
-    prout("ENTER-CORRECT-PASSWORD-TO-CONTINUE-");
+    prout(_("ENTER-CORRECT-PASSWORD-TO-CONTINUE-"));
     skip(1);
-    prout("SELF-DESTRUCT-SEQUENCE-OTHERWISE-");
+    prout(_("SELF-DESTRUCT-SEQUENCE-OTHERWISE-"));
     skip(1);
-    prout("SELF-DESTRUCT-SEQUENCE-WILL-BE-ABORTED");
+    prout(_("SELF-DESTRUCT-SEQUENCE-WILL-BE-ABORTED"));
     skip(1);
     scan();
     chew();
     if (strcmp(game.passwd, citem) != 0) {
-       prouts("PASSWORD-REJECTED;"); skip(1);
-       prouts("CONTINUITY-EFFECTED");
+       prouts(_("PASSWORD-REJECTED;"));
+       skip(1);
+       prouts(_("CONTINUITY-EFFECTED"));
        skip(2);
        return;
     }
-    prouts("PASSWORD-ACCEPTED"); skip(1);
+    prouts(_("PASSWORD-ACCEPTED")); skip(1);
     prouts("                   5"); skip(1);
     prouts("                      4"); skip(1);
     prouts("                         3"); skip(1);
     prouts("                            2"); skip(1);
     prouts("                              1"); skip(1);
     if (Rand() < 0.15) {
-       prouts("GOODBYE-CRUEL-WORLD");
+       prouts(_("GOODBYE-CRUEL-WORLD"));
        skip(1);
     }
     kaboom();
@@ -49,9 +50,9 @@ void kaboom(void)
 {
     stars();
     if (game.ship==IHE) prouts("***");
-    prouts("********* Entropy of ");
+    prouts(_("********* Entropy of "));
     crmshp();
-    prouts(" maximized *********");
+    prouts(_(" maximized *********"));
     skip(1);
     stars();
     skip(1);
@@ -73,16 +74,16 @@ void finish(FINTYPE ifin)
     int igotit = 0;
     game.alldone = 1;
     skip(3);
-    prout("It is stardate %.1f.", game.state.date);
+    prout(_("It is stardate %.1f."), game.state.date);
     skip(1);
     switch (ifin) {
     case FWON: // Game has been won
        if (game.state.nromrem != 0)
-           prout("The remaining %d Romulans surrender to Starfleet Command.",
+           prout(_("The remaining %d Romulans surrender to Starfleet Command."),
                  game.state.nromrem);
 
-       prout("You have smashed the Klingon invasion fleet and saved");
-       prout("the Federation.");
+       prout(_("You have smashed the Klingon invasion fleet and saved"));
+       prout(_("the Federation."));
        game.gamewon=1;
        if (game.alive) {
            double badpt;
@@ -96,39 +97,39 @@ void finish(FINTYPE ifin)
                KLINGKILLED/(game.state.date-game.indate) >=
                0.1*game.skill*(game.skill+1.0) + 0.1 + 0.008*badpt) {
                skip(1);
-               prout("In fact, you have done so well that Starfleet Command");
+               prout(_("In fact, you have done so well that Starfleet Command"));
                switch (game.skill) {
                case SKILL_NOVICE:
-                   prout("promotes you one step in rank from \"Novice\" to \"Fair\".");
+                   prout(_("promotes you one step in rank from \"Novice\" to \"Fair\"."));
                    break;
                case SKILL_FAIR:
-                   prout("promotes you one step in rank from \"Fair\" to \"Good\".");
+                   prout(_("promotes you one step in rank from \"Fair\" to \"Good\"."));
                    break;
                case SKILL_GOOD:
-                   prout("promotes you one step in rank from \"Good\" to \"Expert\".");
+                   prout(_("promotes you one step in rank from \"Good\" to \"Expert\"."));
                    break;
                case SKILL_EXPERT:
-                   prout("promotes you to Commodore Emeritus.");
+                   prout(_("promotes you to Commodore Emeritus."));
                    skip(1);
-                   prout("Now that you think you're really good, try playing");
-                   prout("the \"Emeritus\" game. It will splatter your ego.");
+                   prout(_("Now that you think you're really good, try playing"));
+                   prout(_("the \"Emeritus\" game. It will splatter your ego."));
                    break;
                case SKILL_EMERITUS:
                    skip(1);
-                   proutn("Computer-  ");
-                   prouts("ERROR-ERROR-ERROR-ERROR");
+                   proutn(_("Computer-  "));
+                   prouts(_("ERROR-ERROR-ERROR-ERROR"));
                    skip(2);
-                   prouts("  YOUR-SKILL-HAS-EXCEEDED-THE-CAPACITY-OF-THIS-PROGRAM");
+                   prouts(_("  YOUR-SKILL-HAS-EXCEEDED-THE-CAPACITY-OF-THIS-PROGRAM"));
                    skip(1);
-                   prouts("  THIS-PROGRAM-MUST-SURVIVE");
+                   prouts(_("  THIS-PROGRAM-MUST-SURVIVE"));
                    skip(1);
-                   prouts("  THIS-PROGRAM-MUST-SURVIVE");
+                   prouts(_("  THIS-PROGRAM-MUST-SURVIVE"));
                    skip(1);
-                   prouts("  THIS-PROGRAM-MUST-SURVIVE");
+                   prouts(_("  THIS-PROGRAM-MUST-SURVIVE"));
                    skip(1);
-                   prouts("  THIS-PROGRAM-MUST?- MUST ? - SUR? ? -?  VI");
+                   prouts(_("  THIS-PROGRAM-MUST?- MUST ? - SUR? ? -?  VI"));
                    skip(2);
-                   prout("Now you can retire and write your own Star Trek game!");
+                   prout(_("Now you can retire and write your own Star Trek game!"));
                    skip(1);
                    break;
                }
@@ -138,9 +139,9 @@ void finish(FINTYPE ifin)
                        && !game.idebug
 #endif
                        )
-                       prout("You cannot get a citation, so...");
+                       prout(_("You cannot get a citation, so..."));
                    else {
-                       proutn("Do you want your Commodore Emeritus Citation printed? ");
+                       proutn(_("Do you want your Commodore Emeritus Citation printed? "));
                        chew();
                        if (ja()) {
                            igotit = 1;
@@ -150,136 +151,136 @@ void finish(FINTYPE ifin)
            }
            // Only grant long life if alive (original didn't!)
            skip(1);
-           prout("LIVE LONG AND PROSPER.");
+           prout(_("LIVE LONG AND PROSPER."));
        }
        score();
        if (igotit != 0) plaque();
        return;
     case FDEPLETE: // Federation Resources Depleted
-       prout("Your time has run out and the Federation has been");
-       prout("conquered.  Your starship is now Klingon property,");
-       prout("and you are put on trial as a war criminal.  On the");
-       proutn("basis of your record, you are ");
+       prout(_("Your time has run out and the Federation has been"));
+       prout(_("conquered.  Your starship is now Klingon property,"));
+       prout(_("and you are put on trial as a war criminal.  On the"));
+       proutn(_("basis of your record, you are "));
        if (KLINGREM*3.0 > INKLINGTOT) {
-           prout("aquitted.");
+           prout(_("acquitted."));
            skip(1);
-           prout("LIVE LONG AND PROSPER.");
+           prout(_("LIVE LONG AND PROSPER."));
        }
        else {
-           prout("found guilty and");
-           prout("sentenced to death by slow torture.");
+           prout(_("found guilty and"));
+           prout(_("sentenced to death by slow torture."));
            game.alive = 0;
        }
        score();
        return;
     case FLIFESUP:
-       prout("Your life support reserves have run out, and");
-       prout("you die of thirst, starvation, and asphyxiation.");
-       prout("Your starship is a derelict in space.");
+       prout(_("Your life support reserves have run out, and"));
+       prout(_("you die of thirst, starvation, and asphyxiation."));
+       prout(_("Your starship is a derelict in space."));
        break;
     case FNRG:
-       prout("Your energy supply is exhausted.");
+       prout(_("Your energy supply is exhausted."));
        skip(1);
-       prout("Your starship is a derelict in space.");
+       prout(_("Your starship is a derelict in space."));
        break;
     case FBATTLE:
-       proutn("The ");
+       proutn(_("The "));
        crmshp();
-       prout("has been destroyed in battle.");
+       prout(_("has been destroyed in battle."));
        skip(1);
-       prout("Dulce et decorum est pro patria mori.");
+       prout(_("Dulce et decorum est pro patria mori."));
        break;
     case FNEG3:
-       prout("You have made three attempts to cross the negative energy");
-       prout("barrier which surrounds the galaxy.");
+       prout(_("You have made three attempts to cross the negative energy"));
+       prout(_("barrier which surrounds the galaxy."));
        skip(1);
-       prout("Your navigation is abominable.");
+       prout(_("Your navigation is abominable."));
        score();
        return;
     case FNOVA:
-       prout("Your starship has been destroyed by a nova.");
-       prout("That was a great shot.");
+       prout(_("Your starship has been destroyed by a nova."));
+       prout(_("That was a great shot."));
        skip(1);
        break;
     case FSNOVAED:
-       proutn("The ");
+       proutn(_("The "));
        crmshp();
-       prout(" has been fried by a supernova.");
-       prout("...Not even cinders remain...");
+       prout(_(" has been fried by a supernova."));
+       prout(_("...Not even cinders remain..."));
        break;
     case FABANDN:
-       prout("You have been captured by the Klingons. If you still");
-       prout("had a starbase to be returned to, you would have been");
-       prout("repatriated and given another chance. Since you have");
-       prout("no starbases, you will be mercilessly tortured to death.");
+       prout(_("You have been captured by the Klingons. If you still"));
+       prout(_("had a starbase to be returned to, you would have been"));
+       prout(_("repatriated and given another chance. Since you have"));
+       prout(_("no starbases, you will be mercilessly tortured to death."));
        break;
     case FDILITHIUM:
-       prout("Your starship is now an expanding cloud of subatomic particles");
+       prout(_("Your starship is now an expanding cloud of subatomic particles"));
        break;
     case FMATERIALIZE:
-       prout("Starbase was unable to re-materialize your starship.");
-       prout("Sic transit gloria muntdi");
+       prout(_("Starbase was unable to re-materialize your starship."));
+       prout(_("Sic transit gloria muntdi"));
        break;
     case FPHASER:
-       proutn("The ");
+       proutn(_("The "));
        crmshp();
-       prout(" has been cremated by its own phasers.");
+       prout(_(" has been cremated by its own phasers."));
        break;
     case FLOST:
-       prout("You and your landing party have been");
-       prout("converted to energy, disipating through space.");
+       prout(_("You and your landing party have been"));
+       prout(_("converted to energy, disipating through space."));
        break;
     case FMINING:
-       prout("You are left with your landing party on");
-       prout("a wild jungle planet inhabited by primitive cannibals.");
+       prout(_("You are left with your landing party on"));
+       prout(_("a wild jungle planet inhabited by primitive cannibals."));
        skip(1);
-       prout("They are very fond of \"Captain Kirk\" soup.");
+       prout(_("They are very fond of \"Captain Kirk\" soup."));
        skip(1);
-       proutn("Without your leadership, the ");
+       proutn(_("Without your leadership, the "));
        crmshp();
-       prout(" is destroyed.");
+       prout(_(" is destroyed."));
        break;
     case FDPLANET:
-       prout("You and your mining party perish.");
+       prout(_("You and your mining party perish."));
        skip(1);
-       prout("That was a great shot.");
+       prout(_("That was a great shot."));
        skip(1);
        break;
     case FSSC:
-       prout("The Galileo is instantly annihilated by the supernova.");
+       prout(_("The Galileo is instantly annihilated by the supernova."));
        // no break;
     case FPNOVA:
-       prout("You and your mining party are atomized.");
+       prout(_("You and your mining party are atomized."));
        skip(1);
-       proutn("Mr. Spock takes command of the ");
+       proutn(_("Mr. Spock takes command of the "));
        crmshp();
-       prout(" and");
-       prout("joins the Romulans, reigning terror on the Federation.");
+       prout(_(" and"));
+       prout(_("joins the Romulans, reigning terror on the Federation."));
        break;
     case FSTRACTOR:
-       prout("The shuttle craft Galileo is also caught,");
-       prout("and breaks up under the strain.");
+       prout(_("The shuttle craft Galileo is also caught,"));
+       prout(_("and breaks up under the strain."));
        skip(1);
-       prout("Your debris is scattered for millions of miles.");
-       proutn("Without your leadership, the ");
+       prout(_("Your debris is scattered for millions of miles."));
+       proutn(_("Without your leadership, the "));
        crmshp();
-       prout(" is destroyed.");
+       prout(_(" is destroyed."));
        break;
     case FDRAY:
-       prout("The mutants attack and kill Spock.");
-       prout("Your ship is captured by Klingons, and");
-       prout("your crew is put on display in a Klingon zoo.");
+       prout(_("The mutants attack and kill Spock."));
+       prout(_("Your ship is captured by Klingons, and"));
+       prout(_("your crew is put on display in a Klingon zoo."));
        break;
     case FTRIBBLE:
-       prout("Tribbles consume all remaining water,");
-       prout("food, and oxygen on your ship.");
+       prout(_("Tribbles consume all remaining water,"));
+       prout(_("food, and oxygen on your ship."));
        skip(1);
-       prout("You die of thirst, starvation, and asphyxiation.");
-       prout("Your starship is a derelict in space.");
+       prout(_("You die of thirst, starvation, and asphyxiation."));
+       prout(_("Your starship is a derelict in space."));
        break;
     case FHOLE:
-       prout("Your ship is drawn to the center of the black hole.");
-       prout("You are crushed into extremely dense matter.");
+       prout(_("Your ship is drawn to the center of the black hole."));
+       prout(_("You are crushed into extremely dense matter."));
        break;
     }
     if (game.ship==IHF) game.ship= 0;
@@ -289,24 +290,24 @@ void finish(FINTYPE ifin)
        double goodies = game.state.remres/game.inresor;
        double baddies = (game.state.remkl + 2.0*game.state.remcom)/(game.inkling+2.0*game.incom);
        if (goodies/baddies >= 1.0+0.5*Rand()) {
-           prout("As a result of your actions, a treaty with the Klingon");
-           prout("Empire has been signed. The terms of the treaty are");
+           prout(_("As a result of your actions, a treaty with the Klingon"));
+           prout(_("Empire has been signed. The terms of the treaty are"));
            if (goodies/baddies >= 3.0+Rand()) {
-               prout("favorable to the Federation.");
+               prout(_("favorable to the Federation."));
                skip(1);
-               prout("Congratulations!");
+               prout(_("Congratulations!"));
            }
            else
-               prout("highly unfavorable to the Federation.");
+               prout(_("highly unfavorable to the Federation."));
        }
        else
-           prout("The Federation will be destroyed.");
+           prout(_("The Federation will be destroyed."));
     }
     else {
-       prout("Since you took the last Klingon with you, you are a");
-       prout("martyr and a hero. Someday maybe they'll erect a");
-       prout("statue in your memory. Rest in peace, and try not");
-       prout("to think about pigeons.");
+       prout(_("Since you took the last Klingon with you, you are a"));
+       prout(_("martyr and a hero. Someday maybe they'll erect a"));
+       prout(_("statue in your memory. Rest in peace, and try not"));
+       prout(_("to think about pigeons."));
        game.gamewon = 1;
     }
     score();
@@ -332,58 +333,58 @@ void score(void)
        + 20*NKILLROM + 200*NKILLSC - 10*game.state.nplankl + game.state.nromrem;
     if (game.alive == 0) iscore -= 200;
     skip(2);
-    prout("Your score --");
+    prout(_("Your score --"));
     if (NKILLROM)
-       prout("%6d Romulans destroyed                 %5d",
+       prout(_("%6d Romulans destroyed                 %5d"),
              NKILLROM,20*NKILLROM);
     if (game.state.nromrem)
-       prout("%6d Romulans captured                  %5d",
+       prout(_("%6d Romulans captured                  %5d"),
              game.state.nromrem, game.state.nromrem);
     if (NKILLK)
-       prout("%6d ordinary Klingons destroyed        %5d",
+       prout(_("%6d ordinary Klingons destroyed        %5d"),
              NKILLK, 10*NKILLK);
     if (NKILLC)
-       prout("%6d Klingon commanders destroyed       %5d",
+       prout(_("%6d Klingon commanders destroyed       %5d"),
              NKILLC, 50*NKILLC);
     if (NKILLSC)
-       prout("%6d Super-Commander destroyed          %5d",
+       prout(_("%6d Super-Commander destroyed          %5d"),
              NKILLSC, 200*NKILLSC);
     if (ithperd)
-       prout("%6.2f Klingons per stardate              %5d",
+       prout(_("%6.2f Klingons per stardate              %5d"),
              perdate, ithperd);
     if (game.state.starkl)
-       prout("%6d stars destroyed by your action     %5d",
+       prout(_("%6d stars destroyed by your action     %5d"),
              game.state.starkl, -5*game.state.starkl);
     if (game.state.nplankl)
-       prout("%6d planets destroyed by your action   %5d",
+       prout(_("%6d planets destroyed by your action   %5d"),
              game.state.nplankl, -10*game.state.nplankl);
     if (game.state.basekl)
-       prout("%6d bases destroyed by your action     %5d",
+       prout(_("%6d bases destroyed by your action     %5d"),
              game.state.basekl, -100*game.state.basekl);
     if (game.nhelp)
-       prout("%6d calls for help from starbase       %5d",
+       prout(_("%6d calls for help from starbase       %5d"),
              game.nhelp, -45*game.nhelp);
     if (game.casual)
-       prout("%6d casualties incurred                %5d",
+       prout(_("%6d casualties incurred                %5d"),
              game.casual, -game.casual);
     if (klship)
-       prout("%6d ship(s) lost or destroyed          %5d",
+       prout(_("%6d ship(s) lost or destroyed          %5d"),
              klship, -100*klship);
     if (game.alive==0)
-       prout("Penalty for getting yourself killed        -200");
+       prout(_("Penalty for getting yourself killed        -200"));
     if (game.gamewon) {
-       proutn("Bonus for winning ");
+       proutn(_("Bonus for winning "));
        switch (game.skill) {
-       case SKILL_NOVICE:   proutn("Novice game  "); break;
-       case SKILL_FAIR:     proutn("Fair game    "); break;
-       case SKILL_GOOD:     proutn("Good game    "); break;
-       case SKILL_EXPERT:   proutn("Expert game  "); break;
-       case SKILL_EMERITUS: proutn("Emeritus game"); break;
+       case SKILL_NOVICE:   proutn(_("Novice game  ")); break;
+       case SKILL_FAIR:     proutn(_("Fair game    ")); break;
+       case SKILL_GOOD:     proutn(_("Good game    ")); break;
+       case SKILL_EXPERT:   proutn(_("Expert game  ")); break;
+       case SKILL_EMERITUS: proutn(_("Emeritus game")); break;
        }
        prout("           %5d", iwon);
     }
     skip(1);
-    prout("TOTAL SCORE                               %5d", iscore);
+    prout(_("TOTAL SCORE                               %5d"), iscore);
 }
 
 void plaque(void) {
@@ -396,15 +397,15 @@ void plaque(void) {
        skip(2);
        
        while (fp == NULL) {
-                proutn("File or device name for your plaque: ");
+                proutn(_("File or device name for your plaque: "));
                 cgetline(winner, sizeof(winner));
                fp = fopen(winner, "w");
                if (fp==NULL) {
-                        prout("Invalid name.");
+                        prout(_("Invalid name."));
                }
        }
 
-        proutn("Enter name to go on plaque (up to 30 characters): ");
+        proutn(_("Enter name to go on plaque (up to 30 characters): "));
         cgetline(winner, sizeof(winner));
        /* The 38 below must be 64 for 132-column paper */
        nskip = 38 - strlen(winner)/2;
@@ -428,26 +429,26 @@ void plaque(void) {
        fprintf(fp, "                                                      EE  :                    EEEEEEEE\n");
        fprintf(fp, "                                                       EEEEEEEEEEEEEEEEEEEEEEE\n");
        fprintf(fp, "\n\n\n");
-       fprintf(fp, "                                                       U. S. S. ENTERPRISE\n");
+       fprintf(fp, _("                                                       U. S. S. ENTERPRISE\n"));
        fprintf(fp, "\n\n\n\n");
-       fprintf(fp, "                                  For demonstrating outstanding ability as a starship captain\n");
+       fprintf(fp, _("                                  For demonstrating outstanding ability as a starship captain\n"));
        fprintf(fp, "\n");
-       fprintf(fp, "                                                Starfleet Command bestows to you\n");
+       fprintf(fp, _("                                                Starfleet Command bestows to you\n"));
        fprintf(fp, "\n");
        fprintf(fp,"%*s%s\n\n", nskip, "", winner);
-       fprintf(fp, "                                                           the rank of\n\n");
-       fprintf(fp, "                                                       \"Commodore Emeritus\"\n\n");
+       fprintf(fp, _("                                                           the rank of\n\n"));
+       fprintf(fp, _("                                                       \"Commodore Emeritus\"\n\n"));
        fprintf(fp, "                                                          ");
        switch (iskill) {
-               case SKILL_EXPERT: fprintf(fp," Expert level\n\n"); break;
-               case SKILL_EMERITUS: fprintf(fp,"Emeritus level\n\n"); break;
-               default: fprintf(fp," Cheat level\n\n"); break;
+               case SKILL_EXPERT: fprintf(fp,_(" Expert level\n\n")); break;
+               case SKILL_EMERITUS: fprintf(fp,_("Emeritus level\n\n")); break;
+               default: fprintf(fp,_(" Cheat level\n\n")); break;
        }
        t = time(NULL);
        timestring = ctime(&t);
-       fprintf(fp, "                                                 This day of %.6s %.4s, %.8s\n\n",
+       fprintf(fp, _("                                                 This day of %.6s %.4s, %.8s\n\n"),
                        timestring+4, timestring+20, timestring+11);
-       fprintf(fp,"                                                        Your score:  %d\n\n", iscore);
-       fprintf(fp,"                                                    Klingons per stardate:  %.2f\n", perdate);
+       fprintf(fp,_("                                                        Your score:  %d\n\n"), iscore);
+       fprintf(fp,_("                                                    Klingons per stardate:  %.2f\n"), perdate);
        fclose(fp);
 }
index 5c5ac644526dc4c91ba5f9db6be3e20b04fab22f..b513f26af4efe625d0cddb238ba06491de6057b7 100644 (file)
--- a/src/io.c
+++ b/src/io.c
@@ -1,10 +1,7 @@
 #include <stdio.h>
 #include <unistd.h>
-#include <curses.h>
-#include <signal.h>
-#include <ctype.h>
-#include <stdarg.h>
 
+#include "config.h"
 #include "sst.h"
 #include "sstlinux.h"
 
@@ -34,6 +31,11 @@ static void outro(void)
 
 void iostart(void) 
 {
+    setlocale(LC_ALL, "");
+    bindtextdomain(PACKAGE, LOCALEDIR);
+    textdomain(PACKAGE);
+    gettext("");
+
     if (!(game.options & OPTION_CURSES)) {
        rows = atoi(getenv("LINES"));
     } else {
index b93859ca788a2161579e3ed1fc7c5a674c349693..7b28c2d6fab57e377590ffdefa901b422a37563d 100644 (file)
@@ -474,7 +474,7 @@ int choose(int needprompt)
     // Choose game options -- added by ESR for SST2K
     if (scan() != IHALPHA) {
        chew();
-       proutn("Choose your game options: ");
+       proutn("Choose your game style (or just press enter): ");
        scan();
     }
     if (isit("plain")) {
index 06832359e2406fe3aa6042b8f9766043e08466ce..2af0f192703c146121ff4f136b385f11ae53d79b 100644 (file)
--- a/src/sst.h
+++ b/src/sst.h
@@ -4,6 +4,8 @@
 #include <math.h>
 #include <stdlib.h>
 #include <string.h>
+#include <locale.h>
+#include <libintl.h>
 #include <curses.h>
 
 #ifdef DATA_DIR
@@ -12,6 +14,8 @@
 #define SSTDOC DOC_NAME
 #endif
 
+#define _(str) gettext(str)
+
 #define min(x, y)      ((x)<(y)?(x):(y))
 #define max(x, y)      ((x)>(y)?(x):(y))