1 |
palette_index = obj_pl.palette_index |
2 |
shader_on = obj_pl.shader_on |
3 |
with (other) |
4 |
{ |
5 |
switch state |
6 |
{ |
7 |
case 0: |
8 |
obj_pl.x = x |
9 |
obj_pl.y = y |
10 |
audio_sound_gain(obj_radio.current_song, 0, 0) |
11 |
if ((room == rm_dunes_22 && x >= 290) || (room == rm_dunes_20 && x <= 310)) |
12 |
{ |
13 |
audio_play_sound(snd_rock_break, 1, 0) |
14 |
audio_stop_sound(snd_rock_roll) |
15 |
hspeed = 0 |
16 |
image_speed = 0 |
17 |
if (room == rm_dunes_22) |
18 |
x = 290 |
19 |
else |
20 |
x = 310 |
21 |
timer = 50 |
22 |
state++ |
23 |
} |
24 |
break |
25 |
case 1: |
26 |
if (!scr_timerscr_timerfunction scr_timer() //gml_Script_scr_timer
{
if (timer > 0)
{
timer--
return false;
}
else
return true;
} ()) |
27 |
return; |
28 |
audio_sound_gain(obj_radio.current_song, 1, 500) |
29 |
scr_audio_fade_outscr_audio_fade_outfunction scr_audio_fade_out(argument0, argument1) //gml_Script_scr_audio_fade_out
{
var snd = argument0
var fade_len = argument1
if (!audio_is_playing(snd))
return false;
audio_sound_gain(snd, 0, fade_len)
if instance_exists(obj_audio_fade_helper)
{
with (obj_audio_fade_helper)
{
if (audio_to_fade == snd)
return false;
}
}
with (instance_create(0, 0, obj_audio_fade_helper))
audio_to_fade = snd
} (mus_shimmer, 250) |
30 |
instance_destroy() |
31 |
instance_create(x, y, obj_player_cart) |
32 |
var clovjump = instance_create(x, y, obj_clover_minesjump) |
33 |
if (room == rm_dunes_20) |
34 |
clovjump.hsp *= -1 |
35 |
state++ |
36 |
break |
37 |
} |
38 |
|
39 |
if (hspeed > 0) |
40 |
image_xscale = sign(hspeed) |
41 |
} |