int Minuti xsold ysold Minyti int gdriver gmode errorcode int midx mid

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
int Minuti(xsold, ysold)
//[Minyti]
{
int gdriver = 0, gmode, errorcode;
int midx, midy;
int radius = 100;
float alpha;
int xs;
int ys;
int i;
midx = getmaxx() / 2;
midy = getmaxy() / 2;
struct time t;
gettime(&t);
// cleardevice();
setcolor(BLACK);
line(midx, midy, xsold, ysold );
alpha = (6*t.ti_min+t.ti_sec/10)*acos(-1)/180;
xs = midx + (radius-20) * sin(alpha);
ys = midy - (radius-20) * cos(alpha);
setcolor(YELLOW);
line(midx, midy, xs, ys );
xsold = xs;
ysold = ys;
return xsold, ysold;
}
//[/Minyti]