1 |
if (characters < message_length && counter == 0) |
2 |
{ |
3 |
characters += increase |
4 |
if (characters > message_length) |
5 |
characters = message_length |
6 |
message_draw = string_copy(message[message_current], 0, characters) |
7 |
current_char = string_char_at(message_draw, characters) |
8 |
if (current_char != " ") |
9 |
audio_play_sound(sndfnt_default2, 20, false) |
10 |
} |
11 |
if (increase_message_count == true) |
12 |
{ |
13 |
if (message_current < message_end) |
14 |
{ |
15 |
message_current += 1 |
16 |
message_length = string_length(message[message_current]) |
17 |
characters = 0 |
18 |
message_draw = "" |
19 |
counter = 0 |
20 |
increase_message_count = false |
21 |
} |
22 |
} |
23 |
if (characters > 0 && characters < message_length) |
24 |
{ |
25 |
current_char = string_char_at(message_draw, characters) |
26 |
if (current_char == "." || current_char == ",") |
27 |
counter_max = 10 |
28 |
else |
29 |
counter_max = 2 |
30 |
counter += 1 |
31 |
if (counter >= counter_max) |
32 |
counter = 0 |
33 |
} |