Deltarune script viewer

← back to main script listing

gml_GlobalScript_scr_pivotonpoint

(view raw script w/o annotations or w/e)
1
function scr_pivotonpoint
scr_pivotonpoint

function scr_pivotonpoint(arg0, arg1, arg2) { var __theta = point_direction(sprite_xoffset, sprite_yoffset, arg0, arg1); var __radius = point_distance(sprite_xoffset, sprite_yoffset, arg0, arg1); __theta += direction; var __xx = x + lengthdir_x(__radius, __theta); var __yy = y + lengthdir_y(__radius, __theta); scr_rotatearoundpoint(__xx, __yy, arg2); }
(arg0, arg1, arg2)
2
{
3
    var __theta = point_direction(sprite_xoffset, sprite_yoffset, arg0, arg1);
4
    var __radius = point_distance(sprite_xoffset, sprite_yoffset, arg0, arg1);
5
    __theta += direction;
6
    var __xx = x + lengthdir_x(__radius, __theta);
7
    var __yy = y + lengthdir_y(__radius, __theta);
8
    scr_rotatearoundpoint
scr_rotatearoundpoint

function scr_rotatearoundpoint(arg0, arg1, arg2) { scr_orbitaroundpoint(arg0, arg1, arg2); direction += arg2; }
(__xx, __yy, arg2);
9
}