# SOME DESCRIPTIVE TITLE # Copyright (C) YEAR Free Software Foundation, Inc. # This file is distributed under the same license as the PACKAGE package. # FIRST AUTHOR , YEAR. msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: DATE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "Language: ru\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Translate Toolkit 1.11.0\n" #. type: Title-text #: ../scene.txt:1 #, no-wrap msgid "Radar" msgstr "Радар" #. type: Resume-text #: ../scene.txt:2 #, no-wrap msgid "Use the radar to find lots of stupid blue crosses." msgstr "С помощью радара найдите множество синих крестов." #. type: ScriptName-text #: ../scene.txt:3 #, no-wrap msgid "Find" msgstr "Find" #. type: \b; header #: ../help/help.E.txt:1 #, no-wrap msgid "Exercise" msgstr "Упражнение" #. type: Plain text #: ../help/help.E.txt:2 #, no-wrap msgid "Let the bot find all the blue crosses on the ground. As soon as the bot passed over one of the crosses, it will disappear. Here is the general principle that you will apply:" msgstr "Пусть бот отыщет на земле все синие кресты. Как только бот пройдет над одним из крестов, он исчезнет. Вот общий принцип, который вы должны применить:" #. type: Plain text #: ../help/help.E.txt:4 #, no-wrap msgid "Repeat forever:" msgstr "Повторять всегда:" #. type: Bullet: 'o' #: ../help/help.E.txt:5 #, no-wrap msgid "Look for a cross" msgstr "Искать крест" #. type: Bullet: 'o' #: ../help/help.E.txt:6 #, no-wrap msgid "If there is none, stop the program." msgstr "Если креста нет, остановить программу." #. type: Bullet: 'o' #: ../help/help.E.txt:7 #, no-wrap msgid "Calculate the direction of the cross." msgstr "Рассчитать направление к кресту." #. type: Bullet: 'o' #: ../help/help.E.txt:8 #, no-wrap msgid "Set the speed of the motors in such a way that they will find their way to the cross." msgstr "Установить скорость моторов таким способом, чтобы они могли найти путь к кресту." #. type: \b; header #: ../help/help.E.txt:10 #, no-wrap msgid "The program" msgstr "Программа" #. type: Plain text #: ../help/help.E.txt:11 #, no-wrap msgid "Use a while loop in order to repeat several instructions over and over:" msgstr "Используйте цикл while, чтобы повторять несколько инструкций снова и снова:" #. type: Source code #: ../help/help.E.txt:12 #, no-wrap msgid "" "while ( true )\n" "{\n" "\tinstructions...\n" "}" msgstr "" "while ( true )\n" "{\n" "\tинструкции...\n" "}" #. type: Plain text #: ../help/help.E.txt:17 #, no-wrap msgid "The instruction radar will detect the blue crosses and put their description into a variable, for example spot. In this case, radar() needs only one parameter, i.e. the category of the object that it must look for:" msgstr "Инструкция radar будет искать синие кресты и переводить направление к ним в переменную, например spot. В этом случае инструкции radar() необходим всего один параметр, т.е. категория объекта, который он должен искать:" #. type: Source code #: ../help/help.E.txt:18 #, no-wrap msgid "spot = radar(WayPoint);" msgstr "spot = radar(WayPoint);" #. type: Plain text #: ../help/help.E.txt:20 #, no-wrap msgid "Once all the crosses have been found, radar will return the value null. You will have to test this case and react accordingly with the instruction if:" msgstr "Когда будут найдены все кресты, radar возвратит значение null. Вы должны будете все это проверить и действовать согласно инструкции if:" #. type: Source code #: ../help/help.E.txt:21 #, no-wrap msgid "" "if ( spot == null ) // no more ?\n" "{\n" "\tmotor(0, 0); // stops the motors\n" "\tbreak; // stops the loop\n" "}" msgstr "" "if ( spot == null ) // no more ?\n" "{\n" "\tmotor(0, 0); // stops the motors\n" "\tbreak; // stops the loop\n" "}" #. type: Plain text #: ../help/help.E.txt:26 #, no-wrap msgid "The instruction break will stop the infinite loop while (true)." msgstr "Инструкция break остановит бесконечный цикл while (true)." #. type: Plain text #: ../help/help.E.txt:28 #, no-wrap msgid "Use the instruction direction() to calculate the angle of the rotation that the bot must perform in order to turn towards the blue cross. The coordinates of the object are given by spot.position. The following line will put the angle of the necessary rotation into the variable dir:" msgstr "Используйте инструкцию direction() чтобы рассчитать угол, на который должен развернуться бот, чтобы повернуться в направлении синего креста. Координаты объекта задаются spot.position. Следующие строки устанавливают угол необходимого поворота в переменную dir:" #. type: Source code #: ../help/help.E.txt:29 #, no-wrap msgid "dir = direction(spot.position);" msgstr "dir = direction(spot.position);" #. type: Plain text #: ../help/help.E.txt:31 #, no-wrap msgid "The value of the angle is positive if the blue cross is on your left hand, and negative if it is on your right hand. If the cross to be reached is on your left hand, you must set the right-hand motor to full speed, and set the left-hand motor to a lower speed, according to the angle:" msgstr "Значение угла положительное, если синий крест расположен слева от вас, и отрицательное, если он справа. Если крест расположен слева, вы должны установить максимальную скорость правостороннего мотора и установить левосторонний мотор на более низкие обороты, в соответствии с углом:" #. type: Plain text #: ../help/help.E.txt:33 #, no-wrap msgid "" " direction = 0 -> speed = 1.0\n" " direction = 45 -> speed = 0.5\n" " direction = 90 -> speed = 0.0\n" " direction = 135 -> speed = -0.5\n" " direction = 180 -> speed = -1.0" msgstr "" " направлние = 0 -> скорость = 1.0\n" " направлние = 45 -> скорость = 0.5\n" " направлние = 90 -> скорость = 0.0\n" " направлние = 135 -> скорость = -0.5\n" " направлние = 180 -> скорость = -1.0" #. type: Plain text #: ../help/help.E.txt:39 #, no-wrap msgid "The graphic below shows the speed of the left-hand and right-hand motor as set by the instruction motor, according to the angle:" msgstr "График внизу отображает скорость левостороннего и правостороннего мотора, как было задано инструкцией motor, в соответствии с углом:" #. type: Image filename #: ../help/help.E.txt:41 #, no-wrap msgid "radar2" msgstr "radar2" #. type: Plain text #: ../help/help.E.txt:42 #, no-wrap msgid "If the cross is straight ahead, the angle is 0 degrees. The motors will get the speeds 1 and 1, which means full speed ahead. If the cross is behind, the right motor will be set to speed -1: it will turn around. You can use the expression 1+dir/90 in order to calculate the necessary speed of the motors:" msgstr "Если крест расположен прямо впереди, угол равен 0 градусов. Моторы будут работать на скорости 1 и 1, что означает полный вперед. Если крест сзади, правый мотор будет работать на скорости -1: бот развернется. Вы можете использовать выражение 1+dir/90 чтобы рассчитать необходимую скорость моторов:" #. type: Source code #: ../help/help.E.txt:43 #, no-wrap msgid "" "if ( dir < 0 ) // on the right side?\n" "{\n" "\tmotor(1, 1+dir/90); // turns more or less\n" "}" msgstr "" "if ( dir < 0 ) // справа?\n" "{\n" "\tmotor(1, 1+dir/90); // поворачивает\n" "}" #. type: Plain text #: ../help/help.E.txt:48 #, no-wrap msgid "Use the same principle if the angle has got a positive value, ranging between 0 and 180 degrees. It is up to you to work out the exact instructions to be performed:" msgstr "Используйте тот же принцип, если угол принимает положительное значение между 0 и 180 градусами. Вы можете использовать или не использовать в точности эти инструкции:" #. type: Source code #: ../help/help.E.txt:49 #, no-wrap msgid "" "else // on the left side?\n" "{\n" "\tup to you to fill in here...\n" "}" msgstr "" "else // слева?\n" "{\n" "\tздесь идет код, написанный вами...\n" "}" #. type: Plain text #: ../help/help.E.txt:54 #, no-wrap msgid "At the beginning of the program, you must still declare all the variables. spot is of type object, whereas dir is of type float." msgstr "В самом начале программы вы должны задать переменные. spot относится к типу object, а dir к типу float." #. type: \t; header #: ../help/help.E.txt:56 #, no-wrap msgid "See also" msgstr "См. также" #. type: Plain text #: ../help/help.E.txt:57 #, no-wrap msgid "Programming, types and categories." msgstr "Программирование, типы и категории."