Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_parallax_background_steamworks_34_Draw_0

(view raw script w/o annotations or w/e)
1
var view_x = __view_get(e__VW.XView, 0);
2
draw_background(3506, (view_x + 200) / 1.75, 0);
3
var sin_offset = (sin(current_time / 1000) * 10) - 3;
4
draw_primitive_begin(pr_trianglelist);
5
draw_vertex_color(0, gradient_height + sin_offset, colors[2], 0);
6
draw_vertex_color(room_width, gradient_height + sin_offset, colors[2], 0);
7
draw_vertex_color(room_width, room_height, colors[0], 0.7);
8
draw_vertex_color(room_width, room_height, colors[0], 0.7);
9
draw_vertex_color(0, room_height, colors[0], 0.7);
10
draw_vertex_color(0, gradient_height + sin_offset, colors[2], 0);
11
draw_primitive_end();
12
draw_primitive_begin_texture(pr_trianglestrip, sprite_get_texture(spr_steamworks_34_liquidfalls, image));
13
draw_vertex_texture_color((view_x + 800) / 2, 0, 0, 0, colors[2], 1);
14
draw_vertex_texture_color(((view_x + 800) / 2) + info.width, 0, 1, 0, colors[2], 1);
15
draw_vertex_texture_color(((view_x + 800) / 2) + info.width, info.height, 1, 1, colors[0], 1);
16
draw_vertex_texture_color((view_x + 800) / 2, info.height, 0, 1, colors[0], 1);
17
draw_vertex_texture_color((view_x + 800) / 2, 0, 0, 0, colors[2], 1);
18
draw_primitive_end();
19
draw_primitive_begin_texture(pr_trianglestrip, sprite_get_texture(spr_steamworks_34_liquidfalls, image + spr_doorway));
20
draw_vertex_texture_color((view_x + 1200) / 2, 0, 0, 0, colors[2], 1);
21
draw_vertex_texture_color(((view_x + 1200) / 2) + info.width, 0, 1, 0, colors[2], 1);
22
draw_vertex_texture_color(((view_x + 1200) / 2) + info.width, info.height, 1, 1, colors[0], 1);
23
draw_vertex_texture_color((view_x + 1200) / 2, info.height, 0, 1, colors[0], 1);
24
draw_vertex_texture_color((view_x + 1200) / 2, 0, 0, 0, colors[2], 1);
25
draw_primitive_end();
26
draw_primitive_begin_texture(pr_trianglestrip, sprite_get_texture(spr_steamworks_34_liquidfalls, image + spr_shot_strong_nails));
27
draw_vertex_texture_color((view_x + 1500) / 2, 0, 0, 0, colors[2], 1);
28
draw_vertex_texture_color(((view_x + 1500) / 2) + info.width, 0, 1, 0, colors[2], 1);
29
draw_vertex_texture_color(((view_x + 1500) / 2) + info.width, info.height, 1, 1, colors[0], 1);
30
draw_vertex_texture_color((view_x + 1500) / 2, info.height, 0, 1, colors[0], 1);
31
draw_vertex_texture_color((view_x + 1500) / 2, 0, 0, 0, colors[2], 1);
32
draw_primitive_end();
33
image += 0.5;
34
image %= info.num_subimages;
35
36
enum e__VW
37
{
38
    XView,
39
    YView,
40
    WView,
41
    HView,
42
    Angle,
43
    HBorder,
44
    VBorder,
45
    HSpeed,
46
    VSpeed,
47
    Object,
48
    Visible,
49
    XPort,
50
    YPort,
51
    WPort,
52
    HPort,
53
    Camera,
54
    SurfaceID
55
}