Subversion Repositories svnkaklik

Rev

Rev 280 | Details | Compare with Previous | Last modification | View Log

Rev Author Line No. Line
280 kaklik 1
#navaznost na verzi 277
2
 
3
program Orbis;
4
 
5
var line, movement, Rychlost;
6
 
7
#define L 1
8
#define S 2
9
#define R 3
10
 
11
line:=2;
12
 
13
Rychlost:=15;		# omezeni rychlosti (hlavne pro ladici ucely)
14
 
15
while true
16
do
281 kaklik 17
  if (LEYE = 0 and REYE = 0 and CEYE = 0) then 
18
    LMOT:=Rychlost;RMOT:=0;
19
    line:=2;
20
    movement:=3;
280 kaklik 21
    continue;
281 kaklik 22
  end;
23
 
24
  if (LEYE = 0 and REYE = 0) then 
280 kaklik 25
    LMOT:=Rychlost;RMOT:=Rychlost;
281 kaklik 26
    line:=2;
280 kaklik 27
    movement:=2;
28
    continue;
281 kaklik 29
  end;
30
 
31
  if LEYE = 1 then 
280 kaklik 32
    LMOT:=0;RMOT:=Rychlost;			# jed rovne
33
    line:=1;		# zaznamenej, kdes videl caru
34
    movement:=1;
35
    continue;
36
  end;
37
 
281 kaklik 38
  if REYE = 1 then 
280 kaklik 39
    LMOT:=Rychlost;RMOT:=0;
40
    line:=3;
41
    movement:=3;
42
    continue;
281 kaklik 43
  end;
280 kaklik 44
 
45
end;