1 |
if live_call() |
2 |
return global.live_result; |
3 |
if (!surface_exists(puzzle_surf)) |
4 |
puzzle_surf = surface_create(480, 320) |
5 |
draw_set_alpha(draw_alpha) |
6 |
draw_sprite(spr_chem_compound_puzzle_overlay, 0, (0 + x_offset), (0 + y_offset)) |
7 |
if (puzzle_draw_guide == true) |
8 |
{ |
9 |
draw_sprite(spr_chem_compound_puzzle_guide, 0, (0 + x_offset), (0 + y_offset)) |
10 |
return; |
11 |
} |
12 |
surface_set_target(puzzle_surf) |
13 |
draw_clear_alpha(c_black, 0) |
14 |
if (draw_puzzle_layer == true) |
15 |
{ |
16 |
draw_tilemap(puzzle_layer[puzzle_level_current], (26 + x_offset), (22 + y_offset)) |
17 |
if instance_exists(obj_chem_05_maze_puzzle_player) |
18 |
{ |
19 |
with (obj_chem_05_maze_puzzle_player) |
20 |
draw_sprite_ext(sprite_index, image_index, (x + other.x_offset), (y + other.y_offset), 1, 1, direction, c_white, other.draw_alpha) |
21 |
} |
22 |
if instance_exists(obj_chem_05_maze_puzzle_goal) |
23 |
{ |
24 |
with (obj_chem_05_maze_puzzle_goal) |
25 |
draw_sprite_ext(sprite_index, image_index, (x + other.x_offset), (y + other.y_offset), image_xscale, image_yscale, direction, c_white, other.draw_alpha) |
26 |
} |
27 |
draw_set_alpha(puzzle_alpha) |
28 |
draw_set_color(c_black) |
29 |
draw_rectangle((42 + x_offset), (38 + y_offset), 281, 197, false) |
30 |
draw_set_alpha(1) |
31 |
} |
32 |
else if (countdown_current > 0) |
33 |
{ |
34 |
draw_set_halign(fa_center) |
35 |
draw_set_valign(fa_middle) |
36 |
draw_set_font(fnt_main) |
37 |
draw_set_color(c_lime) |
38 |
if (countdown_current < 4) |
39 |
draw_text_transformed(160, 120, countdown_current, 4, 4, 0) |
40 |
else |
41 |
draw_text_transformed(160, 120, " INITIALIZING...", 1, 1, 0) |
42 |
draw_set_valign(fa_top) |
43 |
draw_set_halign(fa_left) |
44 |
} |
45 |
else if (puzzle_game_victory == true) |
46 |
{ |
47 |
draw_set_halign(fa_center) |
48 |
draw_set_valign(fa_middle) |
49 |
draw_set_font(fnt_main) |
50 |
draw_set_color(c_lime) |
51 |
draw_text_transformed(160, 120, "MIX SUCCESSFUL", 1, 1, 0) |
52 |
draw_set_valign(fa_top) |
53 |
draw_set_halign(fa_left) |
54 |
} |
55 |
surface_reset_target() |
56 |
draw_surface(puzzle_surf, 0, 0) |
57 |
draw_set_alpha(1) |