This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
4rpl:commands:rplcamtween [2023/09/27 23:56] – Provided advanced example preset Vertu | 4rpl:commands:rplcamtween [2025/02/14 14:57] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 7: | Line 7: | ||
===== Description ===== | ===== Description ===== | ||
Causes the camera, in rpl mode, to move to pos and rotate to rot (both vector3s) over the specified time in seconds. | Causes the camera, in rpl mode, to move to pos and rotate to rot (both vector3s) over the specified time in seconds. | ||
+ | |||
+ | :WARNING: If you use this again while it's still active, it keeps track of any movements that are still running, so if you start a long movement and then do a short movement, after the short movement finishes it will return to the long movement if that still had time remaining and hadn't yet reached its destination. (I.e. if you start a eight second movement, and then start a two second movement two seconds in, at the four second mark it will return to where it would have been four seconds into the eight second movement.) | ||
+ | |||
+ | One way to avoid this issue is to avoid overlap by calling interruptions too early and only interrupt things at the end of the movement, or at least close enough the duration doesn' | ||
===== Examples ===== | ===== Examples ===== | ||
Line 13: | Line 17: | ||
</ | </ | ||
<code 4rpl> | <code 4rpl> | ||
- | GetCameraPosition -> | + | RPLCamCopyPosAndRot #So when RPLCam is activated, we say the current camera is how the RPL cam should start as. |
- | GetCameraRotation -> | + | |
SetRPLCam(true) | SetRPLCam(true) | ||
- | SetRPLCamPosition(< | + | RPLCamTween(V3(40 20 30) V3(40 0 0) 1.5) #Have the RPLCam move to this position and rotate to this rotation. |
- | SetRPLCamRotation(< | + | |
- | + | ||
- | RPLCamTween(V3(40 20 30) V3(40 0 0) 1.5) | + | |
</ | </ | ||
< | < | ||