This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
4rpl:commands:rplcamtween [2024/07/01 21:08] – Grammar, syntax and spelling Karsten75 | 4rpl:commands:rplcamtween [2025/02/14 14:57] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 8: | Line 8: | ||
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 are using multiple instances of this API in succession, be aware that when the elapsed time completes for any use of this API, the camera will switch to it. In other words, if you run this API for one case that takes 6 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 |
- | One way to avoid this issue is to ensure that each call to this API takes at least as long as the previous call. | + | 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 17: | 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) | + | |
</ | </ | ||
< | < | ||