Undertale Yellow script viewer

← back to main script listing

gml_GlobalScript___view_set_internal

(view raw script w/o annotations or w/e)
1
function __view_set_internal(argument0, argument1, argument2) //gml_Script___view_set_internal
2
{
3
    var __prop = argument0
4
    var __index = argument1
5
    var __val = argument2
6
    switch __prop
7
    {
8
        case (0 << 0):
9
            var __cam = view_get_camera(__index)
10
            camera_set_view_pos(__cam, __val, camera_get_view_y(__cam))
11
            break
12
        case (1 << 0):
13
            __cam = view_get_camera(__index)
14
            camera_set_view_pos(__cam, camera_get_view_x(__cam), __val)
15
            break
16
        case (2 << 0):
17
            __cam = view_get_camera(__index)
18
            camera_set_view_size(__cam, __val, camera_get_view_height(__cam))
19
            break
20
        case (3 << 0):
21
            __cam = view_get_camera(__index)
22
            camera_set_view_size(__cam, camera_get_view_width(__cam), __val)
23
            break
24
        case (4 << 0):
25
            __cam = view_get_camera(__index)
26
            camera_set_view_angle(__cam, __val)
27
            break
28
        case (5 << 0):
29
            __cam = view_get_camera(__index)
30
            camera_set_view_border(__cam, __val, camera_get_view_border_y(__cam))
31
            break
32
        case (6 << 0):
33
            __cam = view_get_camera(__index)
34
            camera_set_view_border(__cam, camera_get_view_border_x(__cam), __val)
35
            break
36
        case (7 << 0):
37
            __cam = view_get_camera(__index)
38
            camera_set_view_speed(__cam, __val, camera_get_view_speed_y(__cam))
39
            break
40
        case (8 << 0):
41
            __cam = view_get_camera(__index)
42
            camera_set_view_speed(__cam, camera_get_view_speed_x(__cam), __val)
43
            break
44
        case (9 << 0):
45
            __cam = view_get_camera(__index)
46
            camera_set_view_target(__cam, __val)
47
            break
48
        case (10 << 0):
49
            __res = view_set_visible(__index, __val)
50
            break
51
        case (11 << 0):
52
            __res = view_set_xport(__index, __val)
53
            break
54
        case (12 << 0):
55
            __res = view_set_yport(__index, __val)
56
            break
57
        case (13 << 0):
58
            __res = view_set_wport(__index, __val)
59
            break
60
        case (14 << 0):
61
            __res = view_set_hport(__index, __val)
62
            break
63
        case (15 << 0):
64
            __res = view_set_camera(__index, __val)
65
            break
66
        case (16 << 0):
67
            __res = view_set_surface_id(__index, __val)
68
            break
69
        default:
70
            break
71
    }
72
73
    return 0;
74
}