1 |
if (dontdraw == 0) |
2 |
{ |
3 |
if (type == 0) |
4 |
{ |
5 |
draw_sprite_ext(sprite_index, 0, x, y, 2, 2, 0, c_white, 1); |
6 |
timer++; |
7 |
for (i = 0; i < count; i++) |
8 |
{ |
9 |
myx = ((timer * 4) + (i * 50)) % 152; |
10 |
myy = -sin(myx / 36) * 10; |
11 |
draw_sprite_ext(spr_traffic_car_side_legs_small, timer / 4, x + myx, y + myy, 2, 2, 0, c_white, 1); |
12 |
} |
13 |
} |
14 |
if (type == 1) |
15 |
{ |
16 |
draw_sprite_ext(sprite_index, 0, x, y, 2, 2, 0, c_white, 1); |
17 |
if (movemode == 0) |
18 |
{ |
19 |
timer++; |
20 |
image = timer / 4; |
21 |
} |
22 |
if (movemode == 1) |
23 |
{ |
24 |
image = 0; |
25 |
btimer++; |
26 |
timeradd = (sin(btimer / 3) * 1.2) + 0.8; |
27 |
if (timeradd > -0.6) |
28 |
timer += timeradd; |
29 |
if (timeradd < 0.4) |
30 |
image = 0; |
31 |
else |
32 |
image = 1; |
33 |
image = timer / 8; |
34 |
} |
35 |
for (i = 0; i < count; i++) |
36 |
{ |
37 |
myx = ((timer * 4) + (i * 60)) % 236; |
38 |
myy = (-sin(myx / 60) * 10) + 10; |
39 |
if (orientation == "r") |
40 |
draw_sprite_ext(spr_traffic_car_side_legs_small, image, (x + myx) - 40, y + myy, 2, 2, 0, c_white, 1); |
41 |
if (orientation == "l") |
42 |
draw_sprite_ext(spr_traffic_car_side_legs_small, image, (x - myx) + 240, y + myy, -2, 2, 0, c_white, 1); |
43 |
} |
44 |
} |
45 |
} |
46 |
else |
47 |
{ |
48 |
if (type == 0) |
49 |
draw_sprite_ext(sprite_index, 0, x, y, 2, 2, 0, c_white, 1); |
50 |
if (type == 1) |
51 |
draw_sprite_ext(sprite_index, 0, x, y, 2, 2, 0, c_white, 1); |
52 |
} |