Undertale Yellow script viewer

← back to main script listing

gml_Object_obj_ceroba_follower_Create_0

(view raw script w/o annotations or w/e)
1
if live_call()
2
    return global.live_result;
3
with (obj_ceroba_follower)
4
{
5
    up_sprite = 67
6
    right_sprite = 68
7
    down_sprite = 66
8
    left_sprite = 69
9
    up_sprite_idle = 61
10
    right_sprite_idle = 65
11
    down_sprite_idle = 60
12
    left_sprite_idle = 63
13
    up_sprite_run = 81
14
    right_sprite_run = 80
15
    down_sprite_run = 78
16
    left_sprite_run = 79
17
    npc_move_delay_max = 10
18
    npc_move_current = 0
19
    last_player_dir = obj_pl.direction
20
    for (var i = npc_move_delay_max; i > 0; i--)
21
    {
22
        x_new[i] = -1
23
        y_new[i] = -1
24
        dir_new[i] = obj_pl.direction
25
        sprinting_new[i] = false
26
    }
27
    image_index = 0
28
    image_speed = 0
29
    npc_reset = false
30
    is_talking = false
31
    follower_idle = true
32
    npc_actor = 1161
33
    if (x != obj_pl.x || y != obj_pl.y)
34
    {
35
        var player_distance = (point_distance(x, y, obj_pl.x, obj_pl.y)) / 10
36
        for (i = 0; i <= npc_move_delay_max; i++)
37
        {
38
            x_new[i] = x + (obj_pl.x - x) / npc_move_delay_max * i
39
            y_new[i] = y + (obj_pl.y - y) / npc_move_delay_max * i
40
            npc_move_current += 1
41
        }
42
    }
43
}
44
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 }
(0)
45
palette_index = 0
46
event_perform(ev_step, ev_step_normal)