1 |
var _segSpin = spin; |
2 |
if (mode != 0) |
3 |
{ |
4 |
_segSpin = 99999 + (y - heldAmount); |
5 |
if (held) |
6 |
{ |
7 |
adjustForCamera += (riseSpeed * camFollowMultiplier); |
8 |
_segSpin -= adjustForCamera; |
9 |
} |
10 |
else |
11 |
{ |
12 |
adjustForCamera = 0; |
13 |
} |
14 |
} |
15 |
var _bottomY = ystart + heldAmount; |
16 |
if (startOffset != undefined && startOffset > 0) |
17 |
_bottomY += startOffset; |
18 |
var _screwSegTotal = ((_bottomY - y) div screwSegHeight) + 1; |
19 |
var _screwSegStart = 0; |
20 |
for (i = _screwSegStart; i < _screwSegTotal; i++) |
21 |
{ |
22 |
if (i != _screwSegStart) |
23 |
draw_sprite_ext(spr_teacup_screw, 0, x, (_bottomY + 24) - (i * 30), 2, 2, 0, c_white, 1); |
24 |
else |
25 |
draw_sprite_ext(spr_teacup_screw_end, 0, x, (-2 + _bottomY + 24) - (i * 30), 2, 2, 0, c_white, 1); |
26 |
} |
27 |
draw_sprite_ext(spr_teacup_base, 0, x, _bottomY + 20, image_xscale, image_yscale, image_angle, image_blend, image_alpha); |
28 |
draw_sprite_ext(spr_teacup_platform, 0, x, y, image_xscale, image_yscale, image_angle, image_blend, image_alpha); |
29 |
draw_sprite_ext(spr_teacup_center, spin div 22.5, x, y, image_xscale, image_yscale, image_angle, image_blend, image_alpha); |
30 |
if (!surface_exists(shadowSurf)) |
31 |
shadowSurf = surface_create(sprite_width, sprite_height); |
32 |
surface_set_target(shadowSurf); |
33 |
draw_clear_alpha(c_black, 0); |
34 |
draw_set_color(c_black); |
35 |
gpu_set_blendmode_ext(bm_max, bm_zero); |
36 |
with (obj_teacup_bullet) |
37 |
{ |
38 |
if (master == other.id) |
39 |
{ |
40 |
closenessToRide = (ystart - (other.y - 300)) / 300; |
41 |
draw_sprite_ext(sprite_index, image_index, x - other.bbox_left, (other.y + circleY) - other.bbox_top, image_xscale, image_yscale * 0.5, 0, c_black, closenessToRide - (cutOff / spriteHeightRoot)); |
42 |
if (lineToCenter) |
43 |
{ |
44 |
draw_set_color(c_black); |
45 |
draw_set_alpha(closenessToRide - (cutOff / spriteHeightRoot)); |
46 |
draw_line_width(x - other.bbox_left, (other.y + circleY) - other.bbox_top, xstart - other.bbox_left, other.y - other.bbox_top, 4); |
47 |
draw_set_alpha(1); |
48 |
} |
49 |
} |
50 |
} |
51 |
gpu_set_blendmode(bm_normal); |
52 |
surface_reset_target(); |
53 |
draw_surface(shadowSurf, bbox_left, bbox_top); |
54 |
if (room == room_dw_cyber_battle_maze_1) |
55 |
{ |
56 |
if (drawtutorialarrows == true) |
57 |
drawtutorialarrows_alpha = lerp(drawtutorialarrows_alpha, 1, 0.15); |
58 |
else |
59 |
drawtutorialarrows_alpha = lerp(drawtutorialarrows_alpha, 0, 0.35); |
60 |
draw_sprite_ext(spr_teacuparrow, 0, -2 + x + 70, (y + 34) - (sin(idletimer / 3) * 2), 2, 2, 0, c_white, drawtutorialarrows_alpha); |
61 |
draw_sprite_ext(spr_teacuparrow, 0, (-2 + x) - 70, y + 34 + (sin(idletimer / 3) * 2), -2, 2, 0, c_white, drawtutorialarrows_alpha); |
62 |
} |
63 |
draw_set_color(c_red); |
64 |
if (cupCharExists) |
65 |
{ |
66 |
if (debugHitThisFrame) |
67 |
{ |
68 |
draw_circle(20, y, 64, false); |
69 |
debugHitThisFrame = false; |
70 |
} |
71 |
} |