The "vngen_perspective_modify_direct" Function


vngen_perspective_modify_direct(x, y, xoffset, yoffset, zoom, rot, strength);
xrealThe horizontal perspective position, where 0 is center
yrealThe vertical perspective position, where 0 is center
xoffsetrealThe horizontal perspective offset, or 'angle', where 0 is center
yoffsetrealThe vertical perspective offset, or 'angle', where 0 is center
zoomrealThe perspective zoom multiplier, where 1 is neutral
rotrealThe perspective rotation, in degrees
strengthrealThe parallax strength multiplier, or 'FOV', where 1 is default and 0 is no parallax


Applies a new position, orientation, and focal point to the global perspective directly, outside the qScript loop.

All modifications made with this script are permanent and will persist until another modification is performed.

As this script is not an action, care should be taken in deciding when and where to execute it. If both *_modify and *_modify_direct scripts are executed together, whichever is run last will override the other.


var mx = window_mouse_get_x() - (window_get_width()*0.5);
var my = window_mouse_get_y() - (window_get_height()*0.5);
vngen_perspective_modify_direct(0, 0, mx, my, 1, 0, 1);

This will map the perspective angle to the mouse, allowing the user to look around the scene.