Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_player_npc_Create_0

(view raw script w/o annotations or w/e)
1
event_inherited()
2
scr_cutscene_start
scr_cutscene_start

function scr_cutscene_start() //gml_Script_scr_cutscene_start { global.cutscene = true obj_pl.state = gml_Script_scr_frozen_state obj_pl.image_index = 0 obj_pl.image_speed = 0 }
()
3
depth = obj_pl.depth
4
up_sprite = obj_pl.usprite_walk
5
right_sprite = obj_pl.rsprite_walk
6
down_sprite = obj_pl.dsprite_walk
7
left_sprite = obj_pl.lsprite_walk
8
up_sprite_idle = obj_pl.usprite_walk
9
right_sprite_idle = obj_pl.rsprite_walk
10
down_sprite_idle = obj_pl.dsprite_walk
11
left_sprite_idle = obj_pl.lsprite_walk
12
action_sprite = false
13
scene = 0
14
with (obj_pl)
15
    image_alpha = 0
16
switch obj_pl.direction
17
{
18
    case 0:
19
        npc_direction = "right"
20
        sprite_index = right_sprite
21
        break
22
    case 90:
23
        npc_direction = "up"
24
        sprite_index = up_sprite
25
        break
26
    case 180:
27
        npc_direction = "left"
28
        sprite_index = left_sprite
29
        break
30
    case 270:
31
        npc_direction = "down"
32
        sprite_index = down_sprite
33
        break
34
}
35
36
actor_speed = 2
37
axis_override = "nothing"
38
walk_collider = -4
39
destination_count = 0
40
can_walk = false
41
player_fade_out = false
42
end_direction = "down"
43
x_dest[0] = 0
44
y_dest[0] = 0
45
scr_load_palette_shader
scr_load_palette_shader

function scr_load_palette_shader() //gml_Script_scr_load_palette_shader { shader_on = false shader_sprite = spr_final_palette palette_sampler = sprite_get_texture(shader_sprite, 0) u_palette_tex = shader_get_sampler_index(sh_palette_swap, "palette_tex") u_palette_index = shader_get_uniform(sh_palette_swap, "palette_index") u_palette_texel_height = shader_get_uniform(sh_palette_swap, "palette_texel_height") u_palette_texel_width = shader_get_uniform(sh_palette_swap, "palette_texel_width") u_palette_x_offset = shader_get_uniform(sh_palette_swap, "palette_x_offset") u_palette_y_offset = shader_get_uniform(sh_palette_swap, "palette_y_offset") u_color_vect = shader_get_uniform(sh_palette_swap, "color_vect") palette_tex = sprite_get_texture(shader_sprite, 0) uniform_info = [texture_get_texel_height(palette_tex), texture_get_texel_width(palette_tex), array_get(texture_get_uvs(palette_tex), 0), array_get(texture_get_uvs(palette_tex), 1), argument[0]] index = 0 }
(1)
46
palette_index = obj_pl.palette_index
47
shader_on = obj_pl.shader_on