Auto-update from Pootle 2014-07-16

This commit was automatically generated from http://translations.colobot.info/
dev-hd-graphics
krzys-h 2014-07-16 04:33:06 +02:00
parent a48b7adbb7
commit 21213293db
7 changed files with 82 additions and 738 deletions

View File

@ -20,78 +20,66 @@ msgstr ""
#: train601.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-text
#: train601/scene.txt:1
#, no-wrap
msgid "train601:A function"
msgstr "train601:Функция"
msgstr ""
#. type: Resume-text
#: train601/scene.txt:2
#, no-wrap
msgid "train601:Create a function in order to make your program shorter."
msgstr "train601:Создайте функцию чтобы запрограммировать стрелка."
msgstr ""
#. type: ScriptName-text
#: train601/scene.txt:3
#, no-wrap
msgid "train601:Move"
msgstr "train601:Move"
msgstr ""
#. type: \b; header
#: train601-help/tproc1.txt:1
#, no-wrap
#, fuzzy, no-wrap
msgid "Exercise"
msgstr "Упражнение"
msgstr ""
#. type: Plain text
#: train601-help/tproc1.txt:3
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <a object|bottr>bot</a> must pass over all the <a object|waypoint>blue "
"crosses</a> on the ground. The way that must be covered is made of two "
"squares. The first one measures 15 meters, the second 25 meters."
msgstr ""
"<a object|bottr>Бот</a> должен пройти через все <a object|waypoint>синие "
"кресты</a> на земле. Путь, который следует преодолеть, состоит из двух "
"квадратов. Первый - 15 метров, второй - 25 метров."
#. type: Image filename
#: train601-help/tproc1.txt:4
#, no-wrap
#, fuzzy, no-wrap
msgid "tproc1a"
msgstr "tproc1a"
msgstr ""
#. type: \b; header
#: train601-help/tproc1.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid "General principle"
msgstr "Общий принцип"
msgstr ""
#. type: Plain text
#: train601-help/tproc1.txt:7
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"In order to solve this problem, the most efficient solution consists in "
"creating a <a cbot|function>function</a> that instructs the bot to move on a "
"square shape of a certain size. The main program becomes then very "
"simple:<c/>"
msgstr ""
"Чтобы решить эту задачу, вы должны создать функцию, которая приказывает боту "
"двигаться по квадрату с указанной стороной. Поэтому основная программа "
"оказывается очень простой:<c/>"
#. type: \s; block (usually verbatim code)
#: train601-help/tproc1.txt:12
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"extern void object::Function1( )\n"
"{\n"
@ -99,16 +87,10 @@ msgid ""
"\tSquare(25);\n"
"}"
msgstr ""
"extern void object::Function1( )\n"
"{\n"
"\tSquare(15);\n"
"\tSquare(25);\n"
"}"
#. type: Plain text
#: train601-help/tproc1.txt:14
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"You still have to define the function called <code>Square</code>. In order "
"to do this, you will have to write some instructions outside the <a "
@ -117,16 +99,10 @@ msgid ""
"will define the function <code>Square</code>. The program will take the "
"following shape:"
msgstr ""
"Вам все еще нужно определить функцию, которая называется <code>Square</code>"
". Чтобы это сделать, вы должны написать несколько инструкций, вне <a "
"cbot|bloc>блока</a> , которые до этого времени были фреймом каждой из ваших "
"программ. В самом конце программы после последней закрывающей скобки мы "
"определим функцию <code>Square</code>. Тогда программа примет следующий вид:"
#. type: \s; block (usually verbatim code)
#: train601-help/tproc1.txt:24
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"extern void object::Function1( )\n"
"{\n"
@ -138,42 +114,26 @@ msgid ""
"\t</code>new function ...<c/>\n"
"}"
msgstr ""
"extern void object::Function1( )\n"
"{\n"
"\t<n/>главная функция ...<code>\n"
"}\n"
"\n"
"void object::Square(float length)\n"
"{\n"
"\t</code>новая функция ...<c/>\n"
"}"
#. type: Plain text
#: train601-help/tproc1.txt:26
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Let us look in detail at the different elements of the declaration of the "
"function <code>Square</code>:"
msgstr ""
"Теперь давайте детально разберем различные элементы задания функции "
"<code>Square</code>:"
#. type: Plain text
#: train601-help/tproc1.txt:29
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<code><a cbot|void>void</a></code>\n"
"This means that this function will return no value."
msgstr ""
"<code><a cbot|void>void</a></code>\n"
"Это значит, что эта функция не будет возвращать значение."
#. type: Plain text
#: train601-help/tproc1.txt:32
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<code><a cbot|object>object</a>::</code>\n"
"When you write this in front of the function name, you can have access in "
@ -182,27 +142,18 @@ msgid ""
"element is not compulsory, as we will not need the characteristics of the "
"bot in the function."
msgstr ""
"<code><a cbot|object>object</a>::</code>\n"
"Если вы напишите это перед именем функции, то сможете с ее помощью получить "
"доступ ко всем характеристикам бота, таким как <code>позиция</code>, "
"<code>ориентация</code>, и т.п. В этом упражнении этот элемент не "
"обязателен, так как нам для функции характеристики ботов не нужны."
#. type: Plain text
#: train601-help/tproc1.txt:35
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<code>Square ( )</code>\n"
"This is the name of the function. You can call it Square, or any other name."
msgstr ""
"<code>Square ( )</code>\n"
"Это имя функции. Вы можете назвать ее Square, или дать любое другое имя."
#. type: Plain text
#: train601-help/tproc1.txt:38
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<code><a cbot|float>float</a> length</code>\n"
"Here you define the parameters that the function will get when it is "
@ -211,83 +162,61 @@ msgid ""
"value <code>15</code>. The second time, <code>length</code> will contain "
"<code>25</code>."
msgstr ""
"<code><a cbot|float>float</a> length</code>\n"
"Здесь вы задаете параметры, которые получит функция после того как функция "
"будет вызвана. При первом вызове функции с помощью <code>Square(15)</code>, "
"переменная <code>length</code> будет содержать значение <code>15</code>. При "
"втором вызове, <code>length</code> будет <code>25</code>."
#. type: Plain text
#: train601-help/tproc1.txt:40
#, no-wrap
#, fuzzy, no-wrap
msgid "Here is in detail what will happen when the program is executed:\n"
msgstr "Вот детальное описание того, что произойдет после запуска программы:\n"
msgstr ""
#. type: Bullet: '-'
#: train601-help/tproc1.txt:40
#, no-wrap
#, fuzzy, no-wrap
msgid "First the main function <code>Function</code> will be executed."
msgstr "Сначала будет запущена главная функция <code>Function</code>."
msgstr ""
#. type: Bullet: '-'
#: train601-help/tproc1.txt:41
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"At the line <code>Square(15)</code>, the program will follow the red arrow "
"and enter the function <code>Square</code> a first time, <code>length</code> "
"containing <code>15</code>."
msgstr ""
"В строке <code>Square(15)</code> программа будет следовать за красной "
"стрелкой и перейдет в функцию <code>Square</code> в первый раз, "
"<code>length</code> содержит <code>15</code>."
#. type: Bullet: '-'
#: train601-help/tproc1.txt:42
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"At the end of the function <code>Square</code>, the program follows the "
"orange arrow and comes back to the main function."
msgstr ""
"При завершении функции <code>Square</code> программа следует за оранжевой "
"стрелкой и возвращается к главной функции."
#. type: Bullet: '-'
#: train601-help/tproc1.txt:43
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"At the line <code>Square(25)</code>, the program will follow the blue arrow "
"and enter the function <code>Square</code> a second time."
msgstr ""
"В строке <code>Square(25)</code> программа следует за синей стрелкой и "
"переходит в функцию <code>Square</code> во второй раз."
#. type: Bullet: '-'
#: train601-help/tproc1.txt:44
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"At the end of the function <code>Square</code>, the program follows the "
"light blue arrow and comes back to the main function."
msgstr ""
"При окончании функции <code>Square</code>, программа следует за голубой "
"стрелкой и возвращается к главной функции."
#. type: Image filename
#: train601-help/tproc1.txt:46
#, no-wrap
#, fuzzy, no-wrap
msgid "tproc1b"
msgstr "tproc1b"
msgstr ""
#. type: Plain text
#: train601-help/tproc1.txt:48
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"In the function <code>Square</code>, use the instructions <code><a "
"cbot|move>move</a></code> and <code><a cbot|turn>turn</a></code>. In order "
@ -295,17 +224,10 @@ msgid ""
"that will repeat the instructions <code><a cbot|move>move</a></code> and "
"<code><a cbot|turn>turn</a></code> 4 times; however, this is not compulsory."
msgstr ""
"В функции <code>Square</code> используйте инструкции <code><a "
"cbot|move>move</a></code> и <code><a cbot|turn>turn</a></code>. Чтобы "
"сделать ее покороче, вы можете использовать цикл <code><a "
"cbot|for>for</a></code>, который повторит инструкции <code><a "
"cbot|move>move</a></code> и <code><a cbot|turn>turn</a></code> 4 раза; но "
"это не обязательно."
#. type: \s; block (usually verbatim code)
#: train601-help/tproc1.txt:57
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"void object::Square(float length)\n"
"{\n"
@ -316,29 +238,17 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"void object::Square(float length)\n"
"{\n"
"\tfor ( int i=0 ; i<4 ; i=i+1 )\n"
"\t{\n"
"\t\tmove(length);\n"
"\t\tturn(90);\n"
"\t}\n"
"}"
#. type: \t; header
#: train601-help/tproc1.txt:58
#, no-wrap
#, fuzzy, no-wrap
msgid "See also"
msgstr "См. также"
msgstr ""
#. type: Plain text
#: train601-help/tproc1.txt:59
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<a cbot>Programming</a>, <a cbot|type>types</a> and <a "
"cbot|category>categories</a>."
msgstr ""
"<a cbot>Программирование</a>, <a cbot|type>типы</a> и <a "
"cbot|category>категории</a>."

View File

@ -20,64 +20,55 @@ msgstr ""
#: train602.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-text
#: train602/scene.txt:1
#, no-wrap
msgid "train602:Spiral"
msgstr "train602:Спираль"
msgstr ""
#. type: Resume-text
#: train602/scene.txt:2
#, no-wrap
msgid "train602:Create a procedure in order to teach your bot to perform a spiral."
msgstr ""
"train602:Создайте процедуру чтобы научить своего бота двигаться по спирали."
#. type: ScriptName-text
#: train602/scene.txt:3
#, no-wrap
msgid "train602:Move"
msgstr "train602:Move"
msgstr ""
#. type: \b; header
#: train602-help/tproc2.txt:1
#, no-wrap
#, fuzzy, no-wrap
msgid "Exercise"
msgstr "Упражнение"
msgstr ""
#. type: Plain text
#: train602-help/tproc2.txt:3
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Follow the way in form of a spiral. The bot must move 2 times 25m forward "
"and turn, then move 2 times 20m forward and turn, and so on.\n"
msgstr ""
"Следуйте по спиральному пути. Бот должен проследовать два раза вперед на 25 "
"метров и развернуться, а после этого пройти два раза вперед на 20 метров и "
"развернуться еще раз и т.д.\n"
#. type: Image filename
#: train602-help/tproc2.txt:3
#, no-wrap
#, fuzzy, no-wrap
msgid "tproc2"
msgstr "tproc2"
msgstr ""
#. type: \b; header
#: train602-help/tproc2.txt:4
#, no-wrap
#, fuzzy, no-wrap
msgid "Function"
msgstr "Функция"
msgstr ""
#. type: Plain text
#: train602-help/tproc2.txt:6
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"You will have noticed that the way is made of \"L\"-shaped parts that are "
"fit one into another. The first one (dark blue) measures two times 25 "
@ -85,16 +76,10 @@ msgid ""
"with writing the <a cbot|function>function</a> that will move the bot on a "
"\"L\"-shaped part whose length will be given as a parameter:"
msgstr ""
"Вы заметите, что путь состоит из частей, имеющих форму буквы \"L\", которые "
"сложены друг с другом. Первая чать (темно-синяя) имеет размер два раза по 25 "
"метров. Вторая (светло-синяя) на 5 метров меньше. Давайте начнем написание "
"программы с функции, которая переместит бота на части, имеющей форму буквы \""
"L\", чья длина будет задана в виде параметра:"
#. type: \s; block (usually verbatim code)
#: train602-help/tproc2.txt:15
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"void object::Part(float length)\n"
"{\n"
@ -105,19 +90,10 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"void object::Part(float length)\n"
"{\n"
"\tfor ( int i=0 ; i<2 ; i=i+1 )\n"
"\t{\n"
"\t\tmove(length);\n"
"\t\tturn(90);\n"
"\t}\n"
"}"
#. type: Plain text
#: train602-help/tproc2.txt:17
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Now you just need to write the main function, that will call the function "
"<code>Part</code>. At the beginning the variable <code>rest</code> will be "
@ -126,17 +102,10 @@ msgid ""
"the loop, first call the function <code>Part</code> (see above), then "
"subtract 5m to the length of the L."
msgstr ""
"Теперь вы должны написать главную функцию, которая будет вызывать функцию "
"<code>Part</code>. В самом начале переменная <code>rest</code> будет "
"установлена на 25 метров. Цикл <code>while</code> повторит инструкции внутри "
"блока. Это будет продолжаться до тех пор, пока <code>rest</code> больше "
"нуля. Внутри цикла сначала произойдет вызов функции <code>Part</code> (см. "
"выше), а после этого из длины L будет вычтено 5 метров."
#. type: \s; block (usually verbatim code)
#: train602-help/tproc2.txt:27
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"extern void object::Function2( )\n"
"{\n"
@ -148,42 +117,26 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"extern void object::Function2( )\n"
"{\n"
"\tfloat\trest = 25;\n"
"\twhile ( rest > 0 )\n"
"\t{\n"
"\t\tPart(rest);\n"
"\t\trest = rest-5;\n"
"\t}\n"
"}"
#. type: Plain text
#: train602-help/tproc2.txt:29
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The function <code>Part</code> will be called a last time with the value "
"<code>5</code>. Then the expression <code>rest-5</code> will set the value "
"of the variable <code>rest</code> to zero, and the <code>while</code> loop "
"will stop."
msgstr ""
"Функция <code>Part</code> будет вызвана в последний раз со значением "
"<code>5</code>. После этого выражение <code>rest-5</code> установит значение "
"переменной <code>rest</code> на нуль, и цикл <code>while</code> будет "
"остановлен."
#. type: \b; header
#: train602-help/tproc2.txt:30
#, no-wrap
#, fuzzy, no-wrap
msgid "Remark"
msgstr "Комментарий"
msgstr ""
#. type: Plain text
#: train602-help/tproc2.txt:32
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"You will have noticed that in the previous exercise, the main function was "
"at the beginning of the program, whereas in this exercise, it is at the end "
@ -191,25 +144,17 @@ msgid ""
"functions in the program does not matter, you can write a program either "
"way."
msgstr ""
"Вы заметите, что в предыдущем упражнении главная функция располагалась в "
"начале программы, а в этом упражнении она в конце программы после функции "
"<code>Part</code>. Последовательность функций в программе не имеет значения, "
"вы можете писать программу так, как вам больше нравится."
#. type: \t; header
#: train602-help/tproc2.txt:33
#, no-wrap
#, fuzzy, no-wrap
msgid "See also"
msgstr "См. также"
msgstr ""
#. type: Plain text
#: train602-help/tproc2.txt:34
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<a cbot>Programming</a>, <a cbot|type>types</a> and <a "
"cbot|category>categories</a>."
msgstr ""
"<a cbot>Программирование</a>, <a cbot|type>типы</a> и <a "
"cbot|category>категории</a>."

View File

@ -20,13 +20,13 @@ msgstr ""
#: train603.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-text
#: train603/scene.txt:1
#, no-wrap
msgid "train603:Remote control #2"
msgstr "train603:Дистанционное управление #2"
msgstr ""
#. type: Resume-text
#: train603/scene.txt:2
@ -35,85 +35,65 @@ msgid ""
"train603:Remote control a robot using an information exchange post, so it "
"will pass over the 6 blue waypoints."
msgstr ""
"train603:Написать программу для бота так, чтобы он проехаться по 6 синим "
"отметкам, используя для этого пост обмена информацией как пульт "
"дистанционного управления."
#. type: ScriptName-text
#: train603/scene.txt:3
#, no-wrap
msgid "train603:remote"
msgstr "train603:remote"
msgstr ""
#. type: \b; header
#: train603-help/tremote2.txt:1
#, no-wrap
#, fuzzy, no-wrap
msgid "Exercise"
msgstr "Упражнение"
msgstr ""
#. type: Plain text
#: train603-help/tremote2.txt:4
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Remote control a robot using an <a object|exchange>information exchange "
"post</a>, so it will pass over the 6 blue waypoints.\n"
"The main actors of this exercise are¦:"
msgstr ""
"Написать программу для бота так, чтобы он проехаться по 6 синим отметкам, "
"используя для этого <a object|exchange>пост обмена информацией</a> как пульт "
"дистанционного управления.\n"
"Что потребуется¦:"
#. type: Bullet: '1)'
#: train603-help/tremote2.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"A <a object|botgr>wheeled grabber</a> robot without an energy cell. This is "
"the master you have to program."
msgstr "<a object|botgr>Колесный сборщик</a> без батареи."
msgstr ""
#. type: Bullet: '2)'
#: train603-help/tremote2.txt:6
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"An <a object|exchange>information exchange post</a> that receives "
"information from the master and then transmits it to the slave."
msgstr ""
"<a object|exchange>Пост обмена информацией</a> - для приема и передачи "
"информации."
#. type: Bullet: '3)'
#: train603-help/tremote2.txt:7
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"A <a object|bottr>practice bot</a> which waits for orders from the exchange "
"post. This robot has already been programmed."
msgstr ""
"<a object|bottr>Тренировочный бот</a>, который будет ждать комманды от "
"поста. Бот уже заранее запрограммирован."
#. type: Image filename
#: train603-help/tremote2.txt:9
#, no-wrap
#, fuzzy, no-wrap
msgid "tremot2a"
msgstr "tremot2a"
msgstr ""
#. type: Plain text
#: train603-help/tremote2.txt:11
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"An information exchange post stores \"name/value\" couples. To control the "
"\"slave\" robot we use two couples¦:"
msgstr ""
"Пост обмена информацией хранит данные в виде \"name/value\"(имя/значение) "
"только парами. Для управления ботом нам потребуется две таких пары ¦:"
#. type: Bullet: '1)'
#: train603-help/tremote2.txt:12
@ -130,44 +110,32 @@ msgstr ""
#. type: Plain text
#: train603-help/tremote2.txt:17
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Order #1 means \"move\" and order #2 means \"turn\". The parameter is the "
"distance to move or the turning angle. For example to make the slave move 20 "
"meters write¦:\n"
"<c/><s/>\t<a cbot|send>send</a>(\"order\", 1, 100); // order \"move\""
msgstr ""
"Параметр #1 будет \"двигать\", а параметр #2 будет \"поворачивать\". "
"Параметром(#2) будут являться расстояние или угол поворота. Для примера "
"продвинемся на 20 метров вперед¦:\n"
"<c/><s/>\t<a cbot|send>send</a>(\"order\", 1, 100); // даем команду \""
"двигаться\""
#. type: \s; block (usually verbatim code)
#: train603-help/tremote2.txt:18
#, no-wrap
#, fuzzy, no-wrap
msgid "\t<a cbot|send>send</a>(\"param\", 20, 100); // distance 20 meters"
msgstr "\t<a cbot|send>send</a>(\"param\", 20, 100); // расстояние 20 метров"
msgstr ""
#. type: Plain text
#: train603-help/tremote2.txt:22
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"These two instruction send following 2 pieces of information to the exchange "
"post¦:\n"
"<c/> order=1\n"
" param=20"
msgstr ""
"Эти две инструкции необходимо передать на пост последними¦:\n"
"<c/> order=1\n"
" param=20"
#. type: Plain text
#: train603-help/tremote2.txt:25
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The slave robot waits for an order and executes it. Once the order has been "
"executed by the slave, it removes the order from the exchange post. Once an "
@ -177,46 +145,29 @@ msgid ""
"<c/><s/>\twhile ( <a cbot|testinfo>testinfo</a>(\"order\", 100) ) // wait "
"for end of work"
msgstr ""
"Бот получает информацию и выполняет программу. Как только данные были "
"получены, он удаляется от поста. После того, как программа начала "
"выполняться главный бот будет ждать, пока управляемый бот не завершит "
"задания. Только после этого он отправит ему другую информуцию. Это делается "
"путем тестирования.\n"
"Просто напишите¦:\n"
"<c/><s/>\twhile ( <a cbot|testinfo>testinfo</a>(\"order\", 100) ) // ждать, "
"пока работа закончится"
#. type: \s; block (usually verbatim code)
#: train603-help/tremote2.txt:28
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\twait(1);\n"
"\t}"
msgstr ""
"\t{\n"
"\t\twait(1);\n"
"\t}"
#. type: Plain text
#: train603-help/tremote2.txt:31
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"As we must give more than one order its most convenient to write a <a "
"cbot|function>function</a> <code>SendToPost</code>, that sends the order and "
"wait for its completion¦:\n"
"<c/><s/>void object::SendToPost(float order, float param)"
msgstr ""
"Для наиболее удобной записи <a cbot|function>функции</a> "
"<code>SendToPost</code>, можно применить такую программу¦:\n"
"<c/><s/>void object::SendToPost(float order, float param)"
#. type: \s; block (usually verbatim code)
#: train603-help/tremote2.txt:40
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\tsend(\"param\", param, 100); // send the parameter\n"
@ -228,41 +179,26 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"{\n"
"\tsend(\"param\", param, 100); // Отправить параметр\n"
"\tsend(\"order\", order, 100); // Отправить приказ\n"
"\n"
"\twhile ( testinfo(\"order\", 100) ) // wait for end of work\n"
"\t{\n"
"\t\twait(1);\n"
"\t}\n"
"}"
#. type: Plain text
#: train603-help/tremote2.txt:43
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"To move forward by 20 meters, you must write in the main program¦:\n"
"<c/><s/>\tSendToPost(1, 20); // move(20);"
msgstr ""
"Для движения на 20 метров вперед, вы должны написать в главной программе вот "
"это¦:\n"
"<c/><s/>\tSendToPost(1, 20); // move(20);"
#. type: Plain text
#: train603-help/tremote2.txt:45
#, no-wrap
#, fuzzy, no-wrap
msgid "This is the route the robot must travel through¦:"
msgstr "Этот маршрут робот должен пройти так¦:"
msgstr ""
#. type: Image filename
#: train603-help/tremote2.txt:46
#, no-wrap
#, fuzzy, no-wrap
msgid "tremot2b"
msgstr "tremot2b"
msgstr ""
#. type: Plain text
#: train603-help/tremote2.txt:48
@ -273,17 +209,13 @@ msgstr ""
#. type: \t; header
#: train603-help/tremote2.txt:49
#, no-wrap
#, fuzzy, no-wrap
msgid "See also"
msgstr "Смотри также"
msgstr ""
#. type: Plain text
#: train603-help/tremote2.txt:50
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<a cbot>Programming</a>, <a cbot|type>types</a> and <a "
"cbot|category>categories</a>."
msgstr ""
"<a cbot>Язык CBOT</a>, <a cbot|type>Переменные</a> и <a "
"cbot|category>Категории</a>."

View File

@ -20,10 +20,10 @@ msgstr ""
#: train7.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-resume
#: train7/train700.txt:1 train7/train700.txt:1
#, no-wrap
msgid "train700:Classes"
msgstr "train700:Classes"
msgstr ""

View File

@ -20,13 +20,13 @@ msgstr ""
#: train701.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-text
#: train701/scene.txt:1
#, no-wrap
msgid "train701:Remote control #3"
msgstr "train701:Дистанционное управление #3"
msgstr ""
#. type: Resume-text
#: train701/scene.txt:2
@ -35,26 +35,22 @@ msgid ""
"train701:Remote control a bot without using an information exchange post by "
"using a string."
msgstr ""
"train701:Дистанционное управление ботом без использования поста обменом "
"информацией."
#. type: ScriptName-text
#: train701/scene.txt:3
#, no-wrap
msgid "train701:Remote3"
msgstr "train701:Remote3"
msgstr ""
#. type: \b; header
#: train701-help/tremote3.txt:1
#, no-wrap
#, fuzzy, no-wrap
msgid "Exercice"
msgstr "Упражнение"
msgstr ""
#. type: Plain text
#: train701-help/tremote3.txt:3
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Remote control a slave robot without using an <a object|exchange>information "
"exchange post</a>. The robot should pass over the 6 blue crosses. You must "
@ -66,57 +62,39 @@ msgid ""
"cbot|static>static</a></code> class member that will be used to communicate "
"from the master to the slave."
msgstr ""
"Дистанционное управление ботом без использования <a object|exchange>поста "
"обменом информацией</a>. Бот должен проехать по 6 синим отметкам. Вам "
"потребуется использовать команду <a cbot|string>string</a> для того, чтобы "
"передавать команды управляемому боту. Эта строка будет содержать порядок "
"выполнения, например <code>\"move(20)\"</code>. Вы видите, что это тот же "
"синтаксис, используемый в языке CBOT, но мы могли бы выбрать любой другой "
"синтаксис, например что-то вроде <code>\"advance=20\"</code>. Эта строка "
"имеет <code><a cbot|static>статичный</a></code> класс, который будет "
"использован для связи ведущего бота(master, тот, кто управляет) с ведомым "
"ботом(slave, тот, кем управляют)."
#. type: Plain text
#: train701-help/tremote3.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid "The two main actors of this exercise are:\n"
msgstr "Что потребуется:\n"
msgstr ""
#. type: Bullet: '1)'
#: train701-help/tremote3.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <a object|botgr>wheeled grabber</a> without an energy pack and therefore "
"immobile. This is the master you should program so it will transmit orders "
"to the slave."
msgstr ""
"<a object|botgr>Колесный сборщик</a> без батареи. Данный бот будет ведущим."
#. type: Bullet: '2)'
#: train701-help/tremote3.txt:6
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The slave <a object|bottr>practice bot</a> which is already programmed and "
"just waits for orders from the master."
msgstr ""
"Ведомый <a object|bottr>тренировочный бот</a> запрограммированый заранее на "
"ожидание комманд от ведущего бота."
#. type: \b; header
#: train701-help/tremote3.txt:8
#, no-wrap
#, fuzzy, no-wrap
msgid "The slave"
msgstr "Ведомый"
msgstr ""
#. type: Plain text
#: train701-help/tremote3.txt:10
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"First of all we must understand how the program of the slave works. The <a "
"cbot|class>class</a> <code>exchange</code> contains the mechanism for "
@ -126,63 +104,43 @@ msgid ""
"<code>m_order</code> is shared between all instances of the <a "
"cbot|class>class</a> exchange."
msgstr ""
"Прежде всего нужно понять, как программа работает. <a cbot|class>Класс</a> "
"<code>exchange</code> содержит в себе механизм обмена данными. Мы заявляем "
"<code><a cbot|static>статичный</a></code> номер класса <code>m_order</code> "
"который содержит в себе команды для выполнения. Слово "
"<code>статический</code> гарантирует, что <code>m_order</code> будет "
"одинаковым во всех <a cbot|class>классах</a>."
#. type: Plain text
#: train701-help/tremote3.txt:12
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> exchange"
msgstr "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> exchange"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:14
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\t<a cbot|static>static</a> <a cbot|private>private</a> <a "
"cbot|string>string</a> m_order = \"\";"
msgstr ""
"{\n"
"\t<a cbot|static>static</a> <a cbot|private>private</a> <a "
"cbot|string>string</a> m_order = \"\";"
#. type: Plain text
#: train701-help/tremote3.txt:16
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<n/>The <code>put</code> method will be used by the master robot for "
"transmitting an order. As long as the string <code>m_order</code> is not "
"empty, the slave has not finished the order and the <code>put</code> method "
"will return <code>false</code> and will do nothing."
msgstr ""
"<n/>Метод <code>\"put\"</code> позволит ведущему боту передавать команды. "
"Пока строка <code>m_order</code> не будет очищена, ведомый бот не закончит "
"работу и метод <code>put</code> вернет <code>ложь</code>(т.е. бот ничего не "
"будет делать)."
#. type: Plain text
#: train701-help/tremote3.txt:18
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<c/><s/>\t<a cbot|synchro>synchronized</a> <a cbot|bool>bool</a> put(string "
"order)"
msgstr ""
"<c/><s/>\t<a cbot|synchro>synchronized</a> <a cbot|bool>bool</a> put(string "
"order)"
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:29
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\tif ( m_order == \"\" )\n"
@ -196,42 +154,25 @@ msgid ""
"\t\t}\n"
"\t}"
msgstr ""
"\t{\n"
"\t\tif ( m_order == \"\" )\n"
"\t\t{\n"
"\t\t\tm_order = order;\n"
"\t\t\treturn true;\n"
"\t\t}\n"
"\t\telse\n"
"\t\t{\n"
"\t\t\treturn false;\n"
"\t\t}\n"
"\t}"
#. type: Plain text
#: train701-help/tremote3.txt:31
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Another method <code>get</code> will be used by the slave to retrieve the "
"orders. This method returns the string contained in <code>m_order</code> and "
"empties it, so a new order can be accepted:"
msgstr ""
"Другой метод <code>get</code> может быть использован ведомым ботом для "
"получения задания. Этот метод возвращает в строку <code>m_order</code> "
"заявку(order) на выполнение работы:"
#. type: Plain text
#: train701-help/tremote3.txt:33
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|synchro>synchronized</a> string get()"
msgstr "<c/><s/>\t<a cbot|synchro>synchronized</a> string get()"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:39
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\tstring ret = m_order;\n"
@ -240,69 +181,49 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"\t{\n"
"\t\tstring ret = m_order;\n"
"\t\tm_order = \"\";\n"
"\t\treturn ret;\n"
"\t}\n"
"}"
#. type: Plain text
#: train701-help/tremote3.txt:41
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The main program of the slave contains an instance of the class "
"<code>exchange</code> called <code>list</code>."
msgstr ""
"Основная программа в ведомом боте содержит класс <code>exchange</code> "
"вызываемый через <code>list</code>."
#. type: Plain text
#: train701-help/tremote3.txt:43
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|extern>extern</a> void object::Slave3( )"
msgstr "<c/><s/><a cbot|extern>extern</a> void object::Slave3( )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:46
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\texchange list();\n"
"\tstring todo;"
msgstr ""
"{\n"
"\texchange list();\n"
"\tstring todo;"
#. type: Plain text
#: train701-help/tremote3.txt:48
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The outer <code>while</code> loop lasts for ever. The inner "
"<code>while</code> loop waits for an order by using the <code>get</code> "
"method of the <code>exchange</code> class. As soon as <code>get</code> "
"returns a non empty string, the while loop stops."
msgstr ""
"Внешний <code>цикл</code> длится вечно. Внутренний <code>цикл</code> ждет "
"заявку с помощью метода <code>get</code> и <code>exchange</code> класса. Как "
"только метод <code>get</code> вернет не пустую строку, цикл остановится."
#. type: Plain text
#: train701-help/tremote3.txt:50
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|while>while</a> ( true )"
msgstr "<c/><s/>\t<a cbot|while>while</a> ( true )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:57
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\t<a cbot|while>while</a> ( true )\n"
@ -312,36 +233,24 @@ msgid ""
"\t\t\twait(1);\n"
"\t\t}"
msgstr ""
"\t{\n"
"\t\t<a cbot|while>while</a> ( true )\n"
"\t\t{\n"
"\t\t\ttodo = list.get();\n"
"\t\t\tif ( todo != \"\" ) break;\n"
"\t\t\twait(1);\n"
"\t\t}"
#. type: Plain text
#: train701-help/tremote3.txt:59
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Now we have received the order in the <code>todo</code> variable. All we "
"have to do is execute it:"
msgstr ""
"Теперь мы получили заявку в переменную <code>todo</code>. Значит нам нужно "
"выполнить заказ:"
#. type: Plain text
#: train701-help/tremote3.txt:61
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t\tif ( <a cbot|strfind>strfind</a>(todo, \"move\") == 0 )"
msgstr "<c/><s/>\t\tif ( <a cbot|strfind>strfind</a>(todo, \"move\") == 0 )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:70
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t\t{\n"
"\t\t\tmove(<a cbot|strval>strval</a>(<a cbot|strmid>strmid</a>(todo,5)));\n"
@ -353,45 +262,30 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"\t\t{\n"
"\t\t\tmove(<a cbot|strval>strval</a>(<a cbot|strmid>strmid</a>(todo,5)));\n"
"\t\t}\n"
"\t\tif ( strfind(todo, \"turn\") == 0 )\n"
"\t\t{\n"
"\t\t\tturn(strval(strmid(todo,5)));\n"
"\t\t}\n"
"\t}\n"
"}"
#. type: \b; header
#: train701-help/tremote3.txt:71
#, no-wrap
#, fuzzy, no-wrap
msgid "The master"
msgstr "Ведущий"
msgstr ""
#. type: Plain text
#: train701-help/tremote3.txt:73
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"In the master we write an function called <code>SendOrder</code> which will "
"send an order to the slave:"
msgstr ""
"В ведущем боте создадим функцию <code>SendOrder</code>, которая будет "
"отправлять заказы к ведомому боту:"
#. type: Plain text
#: train701-help/tremote3.txt:75
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>void object::SendOrder(string order)"
msgstr "<c/><s/>void object::SendOrder(string order)"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:83
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\texchange list();\n"
@ -402,38 +296,25 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"{\n"
"\texchange list();\n"
"\t\n"
"\twhile ( list.put(order) == false )\n"
"\t{\n"
"\t\twait(1);\n"
"\t}\n"
"}"
#. type: Plain text
#: train701-help/tremote3.txt:86
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <code>while</code> loop waits until a pending order has been terminated, "
"that is the slaved has exited from the <code>get</code> method.\n"
"Now the main program of the master is very simple:"
msgstr ""
"<code>Цикл</code> ждет, пока ожидаемая заявка не будет выполнена.\n"
"Пока программа для ведущего бота довольно проста:"
#. type: Plain text
#: train701-help/tremote3.txt:88
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>extern void object::Remote3( )"
msgstr "<c/><s/>extern void object::Remote3( )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train701-help/tremote3.txt:99
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\tSendOrder(\"move(20)\");\n"
@ -447,39 +328,21 @@ msgid ""
"\tSendOrder(\"move(10)\");\n"
"}"
msgstr ""
"{\n"
"\tSendOrder(\"move(20)\");\n"
"\tSendOrder(\"turn(90)\");\n"
"\tSendOrder(\"move(20)\");\n"
"\tSendOrder(\"turn(90)\");\n"
"\tSendOrder(\"move(10)\");\n"
"\tSendOrder(\"turn(90)\");\n"
"\tSendOrder(\"move(10)\");\n"
"\tSendOrder(\"turn(-90)\");\n"
"\tSendOrder(\"move(10)\");\n"
"}"
#. type: Plain text
#: train701-help/tremote3.txt:101
#, no-wrap
#, fuzzy, no-wrap
msgid "<format key><key help/></format> show these instruction at any time."
msgstr ""
"Клавиша <format key><key help/></format> показывает эту инструкцию в любое "
"время."
#. type: \t; header
#: train701-help/tremote3.txt:102
#, no-wrap
#, fuzzy, no-wrap
msgid "See also"
msgstr "Смотри также"
msgstr ""
#. type: Plain text
#: train701-help/tremote3.txt:103
#, no-wrap
#, fuzzy, no-wrap
msgid "<a command>Controls</a> and <a cbot>programming</a>."
msgstr ""
"<a cbot>Язык CBOT</a>, <a cbot|type>Переменные</a> и <a "
"cbot|category>Категории</a>."

View File

@ -20,13 +20,13 @@ msgstr ""
#: train702.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-text
#: train702/scene.txt:1
#, no-wrap
msgid "train702:Remote control #4"
msgstr "train702:Дистанционное управление #4"
msgstr ""
#. type: Resume-text
#: train702/scene.txt:2
@ -35,114 +35,87 @@ msgid ""
"train702:Remote control a bot without using an information exchange post by "
"defining a class for the orders."
msgstr ""
"train702:Дистанционное управление ботом без использования поста обменом "
"информацией, используя только статичные классы для заявок."
#. type: ScriptName-text
#: train702/scene.txt:3
#, no-wrap
msgid "train702:Remote4"
msgstr "train702:Remote4"
msgstr ""
#. type: \b; header
#: train702-help/tremote4.txt:1
#, no-wrap
#, fuzzy, no-wrap
msgid "Exercise"
msgstr "Упражнение"
msgstr ""
#. type: Plain text
#: train702-help/tremote4.txt:3
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Remote control a slave robot without using an <a object|exchange>information "
"exchange post</a>. The robot should pass over the 6 blue crosses. You must "
"use a <code><a cbot|static>static</a></code> variable to pass the orders to "
"the slave bot."
msgstr ""
"Дистанционное управление ботом без использования <a object|exchange>поста "
"обменом информацией</a>. Бот должен проехать по 6 синим отметкам. Вам "
"придется использовать <code><a cbot|static>статичные</a></code> переменные "
"для отправки заявок ведомому боту."
#. type: Plain text
#: train702-help/tremote4.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid "The two main actors of this exercise are:\n"
msgstr "Что потребуется:\n"
msgstr ""
#. type: Bullet: '1)'
#: train702-help/tremote4.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <a object|botgr>wheeled grabber</a> without an energy pack and therefore "
"immobile. This is the master you should program so it will transmit orders "
"to the slave."
msgstr ""
"<a object|botgr>Колесный сборщик</a> без батареи. Данный бот будет ведущим."
#. type: Bullet: '2)'
#: train702-help/tremote4.txt:6
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The slave <a object|bottr>practice bot</a> which is already programmed and "
"just waits for orders from the master."
msgstr ""
"Ведомый <a object|bottr>тренировочный бот</a> запрограммированый заранее на "
"ожидание комманд от ведущего бота."
#. type: \b; header
#: train702-help/tremote4.txt:8
#, no-wrap
#, fuzzy, no-wrap
msgid "The slave"
msgstr "Ведомый"
msgstr ""
#. type: Plain text
#: train702-help/tremote4.txt:10
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"First of all we must understand how the program of the slave works. The <a "
"cbot|class>class</a> <code>order</code> contains two members: "
"<code>m_type</code> is the order to execute (move or turn) and "
"<code>m_param</code> is the distance to move or the rotation angle¦:"
msgstr ""
"Прежде всего нужно понять, как программа работает. <a cbot|class>Класс</a> "
"<code>order</code> содержит в себе две части: <code>m_type</code> для заявок "
"на выполнение (движение или поворот) и <code>m_param</code> для дистанции "
"или угла поворота¦:"
#. type: Plain text
#: train702-help/tremote4.txt:12
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> order"
msgstr "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> order"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:16
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\t<a cbot|int>int</a> m_type = <a cbot|nan>nan</a>;\n"
"\t<a cbot|float>float</a> m_param;\n"
"}"
msgstr ""
"{\n"
"\t<a cbot|int>int</a> m_type = <a cbot|nan>nan</a>;\n"
"\t<a cbot|float>float</a> m_param;\n"
"}"
#. type: Plain text
#: train702-help/tremote4.txt:18
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"A second <a cbot|class>class</a> <code>exchange</code> contains the "
"mechanism for exchanging the orders. We declare a <code><a "
@ -151,37 +124,25 @@ msgid ""
"the member <code>m_order</code> is shared between all instances of the <a "
"cbot|class>class</a> exchange."
msgstr ""
"Второй <a cbot|class>класс</a> <code>exchange</code> содержит в себе "
"механизм обмена информацией. Мы заявляем <code><a "
"cbot|static>статичную</a></code> часть класса <code>m_order</code>, которая "
"содержит в себе команды для выполнения. Слово <code>статический</code> "
"гарантирует, что <code>m_order</code> будет одинаковым во всех <a "
"cbot|class>классах</a>."
#. type: Plain text
#: train702-help/tremote4.txt:20
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> exchange"
msgstr "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> exchange"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:22
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\t<a cbot|static>static</a> <a cbot|private>private</a> order m_order = new "
"order;"
msgstr ""
"{\n"
"\t<a cbot|static>static</a> <a cbot|private>private</a> order m_order = new "
"order;"
#. type: Plain text
#: train702-help/tremote4.txt:24
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<n/>The <code>put</code> method will be used by the master robot for "
"transmitting an order. As long as <code>m_order</code> is different from "
@ -189,25 +150,18 @@ msgid ""
"the <code>put</code> method will return <code>false</code> and will do "
"nothing¦:"
msgstr ""
"Метод <code>\"put\"</code> позволит ведущему боту передавать команды. Пока "
"значение переменной <code>m_order</code> отличается от <code><a "
"cbot|nan>nan</a></code>, ведомый бот не закончит работу и метод "
"<code>put</code> вернет <code>ложь</code>(т.е. бот ничего не будет делать)¦:"
#. type: Plain text
#: train702-help/tremote4.txt:26
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"<c/><s/>\t<a cbot|synchro>synchronized</a> <a cbot|bool>bool</a> put(order "
"a)"
msgstr ""
"<c/><s/>\t<a cbot|synchro>synchronized</a> <a cbot|bool>bool</a> put(order a)"
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:37
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\tif ( m_order.m_type == nan )\n"
@ -221,142 +175,98 @@ msgid ""
"\t\t}\n"
"\t}"
msgstr ""
"\t{\n"
"\t\tif ( m_order.m_type == nan )\n"
"\t\t{\n"
"\t\t\tm_order = a;\n"
"\t\t\treturn true;\n"
"\t\t}\n"
"\t\telse\n"
"\t\t{\n"
"\t\t\treturn false;\n"
"\t\t}\n"
"\t}"
#. type: Plain text
#: train702-help/tremote4.txt:39
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Another method <code>get</code> will be used by the slave to retrieve the "
"orders. This method returns the order to be executed:"
msgstr ""
"Другой метод <code>get</code> может быть использован ведомым ботом для "
"получения задания. Этот метод возвращает в строку <code>m_order</code> "
"заявку(order) на выполнение работы:"
#. type: Plain text
#: train702-help/tremote4.txt:41
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|synchro>synchronized</a> order get()"
msgstr "<c/><s/>\t<a cbot|synchro>synchronized</a> order get()"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:44
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\treturn m_order;\n"
"\t}"
msgstr ""
"\t{\n"
"\t\treturn m_order;\n"
"\t}"
#. type: Plain text
#: train702-help/tremote4.txt:46
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"A third method <code>delete</code> will be used by the slave to indicate "
"that the order has been executed:"
msgstr ""
"Третий метод <code>delete</code> служит ведомому боту для индикации "
"состояния выболнения заявки:"
#. type: Plain text
#: train702-help/tremote4.txt:48
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|synchro>synchronized</a> void delete()"
msgstr "<c/><s/>\t<a cbot|synchro>synchronized</a> void delete()"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:52
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\tm_order.m_type = nan;\n"
"\t}\n"
"}"
msgstr ""
"\t{\n"
"\t\tm_order.m_type = nan;\n"
"\t}\n"
"}"
#. type: Plain text
#: train702-help/tremote4.txt:54
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The main program of the slave contains an instance of the class "
"<code>exchange</code> called <code>list</code>. We put () after the word "
"<code>list</code> in order to create an instance of the class "
"<code>exchange</code>."
msgstr ""
"Основная программа в ведомом боте содержит класс <code>exchange</code> "
"вызываемый через <code>list</code>."
#. type: Plain text
#: train702-help/tremote4.txt:56
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|extern>extern</a> void object::Slave3( )"
msgstr "<c/><s/><a cbot|extern>extern</a> void object::Slave3( )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:59
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\texchange list();\n"
"\torder todo;"
msgstr ""
"{\n"
"\texchange list();\n"
"\torder todo;"
#. type: Plain text
#: train702-help/tremote4.txt:61
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The outer <code>while</code> loop lasts for ever. The inner "
"<code>while</code> loop waits for an order by using the <code>get</code> "
"method of the <code>exchange</code> class. As soon as <code>get</code> "
"returns a value different from <code>nan</code>, the while loop stops."
msgstr ""
"Внешний <code>цикл</code> длится вечно. Внутренний <code>цикл</code> ждет "
"заявку с помощью метода <code>get</code> и <code>exchange</code> класса. Как "
"только метод <code>get</code> вернет значение, отличное от <code>nan</code>, "
"цикл остановится."
#. type: Plain text
#: train702-help/tremote4.txt:63
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|while>while</a> ( true )"
msgstr "<c/><s/>\t<a cbot|while>while</a> ( true )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:70
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\t<a cbot|while>while</a> ( true )\n"
@ -366,36 +276,24 @@ msgid ""
"\t\t\twait(1);\n"
"\t\t}"
msgstr ""
"\t{\n"
"\t\t<a cbot|while>while</a> ( true )\n"
"\t\t{\n"
"\t\t\ttodo = list.get();\n"
"\t\t\tif ( todo.m_type != nan ) break;\n"
"\t\t\twait(1);\n"
"\t\t}"
#. type: Plain text
#: train702-help/tremote4.txt:72
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Now we have received the order in the <code>todo</code> variable. All we "
"have to do is execute it:"
msgstr ""
"Теперь мы получили заявку в переменную <code>todo</code>. Теперь нам нужно "
"выполнить заказ:"
#. type: Plain text
#: train702-help/tremote4.txt:74
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t\tif ( todo.m_type == 1 )"
msgstr "<c/><s/>\t\tif ( todo.m_type == 1 )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:85
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t\t{\n"
"\t\t\tmove(todo.m_param);\n"
@ -409,77 +307,53 @@ msgid ""
"\t\t\tmessage(\"Unknown order\");\n"
"\t\t}"
msgstr ""
"\t\t{\n"
"\t\t\tmove(todo.m_param);\n"
"\t\t}\n"
"\t\telse if ( todo.m_type == 2 )\n"
"\t\t{\n"
"\t\t\tturn(todo.m_param);\n"
"\t\t}\n"
"\t\telse\n"
"\t\t{\n"
"\t\t\tmessage(\"Unknown order\");\n"
"\t\t}"
#. type: Plain text
#: train702-help/tremote4.txt:87
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"As soon as the execution of the order is finished, we must call the "
"<code>delete</code> method so the master knows that another order can be "
"sent¦:"
msgstr ""
"Как только поданая заявка выполнена, мы можем использовать метод "
"<code>delete</code>, чтобы ведущий бот знал, что ожидается следущая заявка¦:"
#. type: Plain text
#: train702-help/tremote4.txt:89
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t\tlist.delete();"
msgstr "<c/><s/>\t\tlist.delete();"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:91
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t}\n"
"}"
msgstr ""
"\t}\n"
"}"
#. type: \b; header
#: train702-help/tremote4.txt:92
#, no-wrap
#, fuzzy, no-wrap
msgid "The master"
msgstr "Ведущий"
msgstr ""
#. type: Plain text
#: train702-help/tremote4.txt:94
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"In the master we write an function called <code>SendOrder</code> which will "
"send an order to the slave:"
msgstr ""
"В ведущем боте создадим функцию <code>SendOrder</code>, которая будет "
"отправлять заказы к ведомому боту:"
#. type: Plain text
#: train702-help/tremote4.txt:96
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>void object::SendOrder(float order, float param)"
msgstr "<c/><s/>void object::SendOrder(float order, float param)"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:108
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\texchange list();\n"
@ -494,44 +368,26 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"{\n"
"\texchange list();\n"
"\torder todo();\n"
"\t\n"
"\ttodo.m_type = order;\n"
"\ttodo.m_param = param;\n"
"\t\n"
"\twhile ( list.put(todo) == false )\n"
"\t{\n"
"\t\twait(1);\n"
"\t}\n"
"}"
#. type: Plain text
#: train702-help/tremote4.txt:111
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <code>while</code> loop waits until a pending order has been terminated, "
"that is the slaved has exited from the <code>get</code> method and the "
"<code>delete</code> method has been called.\n"
"Now the main program of the master is very simple:"
msgstr ""
"Цикл <code>while</code> будет ждать, пока заявка не будет выполнена и пока "
"ведомый бот не вызовет методы <code>get</code> и <code>delete</code>.\n"
"Пока программа для ведущего бота довольно проста:"
#. type: Plain text
#: train702-help/tremote4.txt:113
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>extern void object::Remote4( )"
msgstr "<c/><s/>extern void object::Remote4( )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train702-help/tremote4.txt:124
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\tSendOrder(1, 20); // move(20);\n"
@ -545,39 +401,21 @@ msgid ""
"\tSendOrder(1, 10); // move(10);\n"
"}"
msgstr ""
"{\n"
"\tSendOrder(1, 20); // move(20);\n"
"\tSendOrder(2, 90); // turn(90);\n"
"\tSendOrder(1, 20); // move(20);\n"
"\tSendOrder(2, 90); // turn(90);\n"
"\tSendOrder(1, 10); // move(10);\n"
"\tSendOrder(2, 90); // turn(90);\n"
"\tSendOrder(1, 10); // move(10);\n"
"\tSendOrder(2,-90); // turn(-90);\n"
"\tSendOrder(1, 10); // move(10);\n"
"}"
#. type: Plain text
#: train702-help/tremote4.txt:126
#, no-wrap
#, fuzzy, no-wrap
msgid "<format key><key help/></format> show these instruction at any time."
msgstr ""
"Клавиша <format key><key help/></format> показывает эту инструкцию в любое "
"время."
#. type: \t; header
#: train702-help/tremote4.txt:128
#, no-wrap
#, fuzzy, no-wrap
msgid "See also"
msgstr "Смотри также"
msgstr ""
#. type: Plain text
#: train702-help/tremote4.txt:129
#, no-wrap
#, fuzzy, no-wrap
msgid "<a command>Controls</a> and <a cbot>programming</a>."
msgstr ""
"<a cbot>Язык CBOT</a>, <a cbot|type>Переменные</a> и <a "
"cbot|category>Категории</a>."

View File

@ -20,13 +20,13 @@ msgstr ""
#: train703.languagecode:1
#, no-wrap
msgid "E"
msgstr "R"
msgstr ""
#. type: Title-text
#: train703/scene.txt:1
#, no-wrap
msgid "train703:Remote control #5"
msgstr "train703:Дистанционное управление #5"
msgstr ""
#. type: Resume-text
#: train703/scene.txt:2
@ -35,123 +35,94 @@ msgid ""
"train703:Remote control a bot without using an information exchange post by "
"storing the orders."
msgstr ""
"train703:Дистанционное управление ботом без использования поста обменом "
"информацией, используя сохранение заявок."
#. type: ScriptName-text
#: train703/scene.txt:3
#, no-wrap
msgid "train703:Remote5"
msgstr "train703:Remote5"
msgstr ""
#. type: \b; header
#: train703-help/tremote5.txt:1
#, no-wrap
#, fuzzy, no-wrap
msgid "Exercise"
msgstr "Упражнение"
msgstr ""
#. type: Plain text
#: train703-help/tremote5.txt:3
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Remote control a slave robot without using an <a object|exchange>information "
"exchange post</a>. The robot should pass over the 6 blue crosses. "
msgstr ""
"Дистанционное управление ботом без использования <a object|exchange>поста "
"обменом информацией</a>. Бот должен проехать по 6 синим отметкам."
#. type: Plain text
#: train703-help/tremote5.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid "The two main actors of this exercise are:\n"
msgstr "Что потребуется:\n"
msgstr ""
#. type: Bullet: '1)'
#: train703-help/tremote5.txt:5
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <a object|botgr>wheeled grabber</a> without an energy pack and therefore "
"immobile. This is the master you should program so it will transmit orders "
"to the slave."
msgstr ""
"<a object|botgr>Колесный сборщик</a> без батареи. Данный бот будет ведущим."
#. type: Bullet: '2)'
#: train703-help/tremote5.txt:6
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The slave <a object|bottr>practice bot</a> which is already programmed and "
"just waits for orders from the master."
msgstr ""
"Ведомый <a object|bottr>тренировочный бот</a> запрограммированый заранее на "
"ожидание комманд от ведущего бота."
#. type: Plain text
#: train703-help/tremote5.txt:9
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The orders shall be stored, so the master will be able to transmit several "
"orders without waiting for each order being processed. We use an <a "
"cbot|array>array</a> for this purpose."
msgstr ""
"Ведущий бот будет передавать сразу несколько заявок, не дожидаясь, пока они "
"будут обрабатываться. Мы будем использовать <a cbot|array>массив</a> для "
"эттой цели."
#. type: \b; header
#: train703-help/tremote5.txt:10
#, no-wrap
#, fuzzy, no-wrap
msgid "The slave"
msgstr "Ведомый"
msgstr ""
#. type: Plain text
#: train703-help/tremote5.txt:12
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"First of all we must understand how the program of the slave works. The <a "
"cbot|class>class</a> <code>order</code> contains two members: "
"<code>m_type</code> is the order to execute (move or turn) and "
"<code>m_param</code> is the distance to move or the rotation angle¦:"
msgstr ""
"Прежде всего нужно понять, как программа работает. <a cbot|class>Класс</a> "
"<code>order</code> содержит в себе две части: <code>m_type</code> для заявок "
"на выполнение (движение или поворот) и <code>m_param</code> для дистанции "
"или угла поворота¦:"
#. type: Plain text
#: train703-help/tremote5.txt:14
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> order"
msgstr "<c/><s/><a cbot|public>public</a> <a cbot|class>class</a> order"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:18
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\t<a cbot|int>int</a> m_type;\n"
"\t<a cbot|float>float</a> m_param;\n"
"}"
msgstr ""
"{\n"
"\t<a cbot|int>int</a> m_type;\n"
"\t<a cbot|float>float</a> m_param;\n"
"}"
#. type: Plain text
#: train703-help/tremote5.txt:20
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"A second <a cbot|class>class</a> <code>exchange</code> contains the "
"mechanism for exchanging the orders. We declare a <code><a "
@ -160,67 +131,48 @@ msgid ""
"insures that the member <code>m_fifo</code> is shared between all instances "
"of the <a cbot|class>class</a> exchange."
msgstr ""
"Второй <a cbot|class>класс</a> <code>exchange</code> содержит в себе "
"механизм обмена информацией. Мы заявляем <code><a "
"cbot|static>статичную</a></code> часть класса <code>m_fifo</code>, которая "
"содержит в себе лист команд для выполнения. Слово <code>статический</code> "
"гарантирует, что <code>m_fifo</code> будет одинаковым во всех <a "
"cbot|class>классах</a>."
#. type: Plain text
#: train703-help/tremote5.txt:22
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>{"
msgstr "<c/><s/>{"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:23
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t<a cbot|static>static</a> <a cbot|private>private</a> order m_fifo[] = "
"null;"
msgstr ""
"\t<a cbot|static>static</a> <a cbot|private>private</a> order m_fifo[] = "
"null;"
#. type: Plain text
#: train703-help/tremote5.txt:25
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The <code>put</code> method will be used by the master robot for "
"transmitting an order. The order will simply be added at the end of the "
"<code>m_fifo</code> array:"
msgstr ""
"Метод <code>put</code> позволит ведущему боту передавать завяки. Заявки "
"могут быть легко добавлены в конце массива <code>m_fifo</code>:"
#. type: Plain text
#: train703-help/tremote5.txt:27
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|synchro>synchronized</a> void put(order a)"
msgstr "<c/><s/>\t<a cbot|synchro>synchronized</a> void put(order a)"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:30
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\tm_fifo[sizeof(m_fifo)] = a;\n"
"\t}"
msgstr ""
"\t{\n"
"\t\tm_fifo[sizeof(m_fifo)] = a;\n"
"\t}"
#. type: Plain text
#: train703-help/tremote5.txt:32
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Another method <code>get</code> will be used by the slave to retrieve the "
"orders. This method returns the order to be executed. If the list is empty, "
@ -229,25 +181,16 @@ msgid ""
"remaining orders must be \"scrolled up\". As an array can not be "
"\"shortened\" we use a temporary array <code>copy</code>¦:"
msgstr ""
"Другой метод <code>get</code> может быть использован ведомым ботом для "
"получения задания. Этот метод возвращает выполненную заявку. Если лист "
"пустой, будет возвращено значение <code>null</code> и бот будет ждать "
"следующих команд. В противном случае первая заявка в списке будет "
"возвращена, а оставшиеся будут \"продвинуты вверх\". Если массив не может "
"быть \"укорочен\", то мы будем использовать временной массив "
"<code>copy</code>¦:"
#. type: Plain text
#: train703-help/tremote5.txt:34
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|synchro>synchronized</a> order get()"
msgstr "<c/><s/>\t<a cbot|synchro>synchronized</a> order get()"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:46
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\tif ( sizeof(m_fifo) == 0 ) return null;\n"
@ -262,78 +205,51 @@ msgid ""
"\t\treturn a;\n"
"\t}"
msgstr ""
"\t{\n"
"\t\tif ( sizeof(m_fifo) == 0 ) return null;\n"
"\n"
"\t\torder a = m_fifo[0];\n"
"\t\torder copy[] = null;\n"
"\t\tfor ( int i=1 ; i<sizeof(m_fifo) ; i++ )\n"
"\t\t{\n"
"\t\t\tcopy[i-1] = m_fifo[i];\n"
"\t\t}\n"
"\t\tm_fifo = copy;\n"
"\t\treturn a;\n"
"\t}"
#. type: Plain text
#: train703-help/tremote5.txt:48
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The main program of the slave contains an instance of the class "
"<code>exchange</code> called <code>list</code>. We put () after the word "
"<code>list</code> in order to create an instance of the class "
"<code>exchange</code>."
msgstr ""
"Основная программа в ведомом боте содержит класс <code>exchange</code> "
"вызываемый через <code>list</code>."
#. type: Plain text
#: train703-help/tremote5.txt:50
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/><a cbot|extern>extern</a> void object::Slave5( )"
msgstr "<c/><s/><a cbot|extern>extern</a> void object::Slave5( )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:53
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\texchange list();\n"
"\torder todo;"
msgstr ""
"{\n"
"\texchange list();\n"
"\torder todo;"
#. type: Plain text
#: train703-help/tremote5.txt:55
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"The outer <code>while</code> loop lasts for ever. The inner "
"<code>while</code> loop waits for an order by using the <code>get</code> "
"method of the <code>exchange</code> class. As soon as <code>get</code> "
"returns a value different from <code>null</code>, the while loop stops."
msgstr ""
"Внешний <code>цикл</code> длится вечно. Внутренний <code>цикл</code> ждет "
"заявку с помощью метода <code>get</code> и <code>exchange</code> класса. Как "
"только метод <code>get</code> вернет значение, отличное от <code>null</code>"
", цикл остановится."
#. type: Plain text
#: train703-help/tremote5.txt:57
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t<a cbot|while>while</a> ( true )"
msgstr "<c/><s/>\t<a cbot|while>while</a> ( true )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:64
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t{\n"
"\t\t<a cbot|while>while</a> ( true )\n"
@ -343,36 +259,24 @@ msgid ""
"\t\t\twait(1);\n"
"\t\t}"
msgstr ""
"\t{\n"
"\t\t<a cbot|while>while</a> ( true )\n"
"\t\t{\n"
"\t\t\ttodo = list.get();\n"
"\t\t\tif ( todo != null ) break;\n"
"\t\t\twait(1);\n"
"\t\t}"
#. type: Plain text
#: train703-help/tremote5.txt:66
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"Now we have received the order in the <code>todo</code> variable. All we "
"have to do is execute it:"
msgstr ""
"Теперь мы получили заявку в переменную <code>todo</code>. Значит нам нужно "
"выполнить заказ:"
#. type: Plain text
#: train703-help/tremote5.txt:68
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>\t\tif ( todo.m_type == 1 )"
msgstr "<c/><s/>\t\tif ( todo.m_type == 1 )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:81
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"\t\t{\n"
"\t\t\tmove(todo.m_param);\n"
@ -388,49 +292,30 @@ msgid ""
"\t}\n"
"}"
msgstr ""
"\t\t{\n"
"\t\t\tmove(todo.m_param);\n"
"\t\t}\n"
"\t\telse if ( todo.m_type == 2 )\n"
"\t\t{\n"
"\t\t\tturn(todo.m_param);\n"
"\t\t}\n"
"\t\telse\n"
"\t\t{\n"
"\t\t\tmessage(\"Unknown order\");\n"
"\t\t}\n"
"\t}\n"
"}"
#. type: \b; header
#: train703-help/tremote5.txt:82
#, no-wrap
#, fuzzy, no-wrap
msgid "The master"
msgstr "Ведущий"
msgstr ""
#. type: Plain text
#: train703-help/tremote5.txt:84
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"In the master we write a function called <code>SendOrder</code> which will "
"send an order to the slave:"
msgstr ""
"В ведущем боте создадим функцию <code>SendOrder</code>, которая будет "
"отправлять заказы к ведомому боту:"
#. type: Plain text
#: train703-help/tremote5.txt:86
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>void object::SendOrder(float order, float param)"
msgstr "<c/><s/>void object::SendOrder(float order, float param)"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:94
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\texchange list();\n"
@ -441,33 +326,22 @@ msgid ""
"\tlist.put(todo);\n"
"}"
msgstr ""
"{\n"
"\texchange list();\n"
"\torder todo();\n"
"\t\n"
"\ttodo.m_type = order;\n"
"\ttodo.m_param = param;\n"
"\tlist.put(todo);\n"
"}"
#. type: Plain text
#: train703-help/tremote5.txt:96
#, no-wrap
#, fuzzy, no-wrap
msgid "Now the main program of the master is very simple:"
msgstr "Пока программа для ведущего бота довольно проста:"
msgstr ""
#. type: Plain text
#: train703-help/tremote5.txt:98
#, no-wrap
#, fuzzy, no-wrap
msgid "<c/><s/>extern void object::Remote5( )"
msgstr "<c/><s/>extern void object::Remote5( )"
msgstr ""
#. type: \s; block (usually verbatim code)
#: train703-help/tremote5.txt:109
#, no-wrap
#, fuzzy, no-wrap
msgid ""
"{\n"
"\tSendOrder(1, 20); // move(20);\n"
@ -481,39 +355,21 @@ msgid ""
"\tSendOrder(1, 10); // move(10);\n"
"}"
msgstr ""
"{\n"
"\tSendOrder(1, 20); // move(20);\n"
"\tSendOrder(2, 90); // turn(90);\n"
"\tSendOrder(1, 20); // move(20);\n"
"\tSendOrder(2, 90); // turn(90);\n"
"\tSendOrder(1, 10); // move(10);\n"
"\tSendOrder(2, 90); // turn(90);\n"
"\tSendOrder(1, 10); // move(10);\n"
"\tSendOrder(2,-90); // turn(-90);\n"
"\tSendOrder(1, 10); // move(10);\n"
"}"
#. type: Plain text
#: train703-help/tremote5.txt:111
#, no-wrap
#, fuzzy, no-wrap
msgid "<format key><key help/></format> show these instruction at any time."
msgstr ""
"Клавиша <format key><key help/></format> показывает эту инструкцию в любое "
"время."
#. type: \t; header
#: train703-help/tremote5.txt:112
#, no-wrap
#, fuzzy, no-wrap
msgid "See also"
msgstr "Смотри также"
msgstr ""
#. type: Plain text
#: train703-help/tremote5.txt:113
#, no-wrap
#, fuzzy, no-wrap
msgid "<a command>Controls</a> and <a cbot>programming</a>."
msgstr ""
"<a cbot>Язык CBOT</a>, <a cbot|type>Переменные</a> и <a "
"cbot|category>Категории</a>."