<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://g1r-mp.com/wiki/index.php?action=history&amp;feed=atom&amp;title=MoveCameraTo</id>
	<title>MoveCameraTo - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://g1r-mp.com/wiki/index.php?action=history&amp;feed=atom&amp;title=MoveCameraTo"/>
	<link rel="alternate" type="text/html" href="https://g1r-mp.com/wiki/index.php?title=MoveCameraTo&amp;action=history"/>
	<updated>2026-09-19T06:25:19Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>https://g1r-mp.com/wiki/index.php?title=MoveCameraTo&amp;diff=820&amp;oldid=prev</id>
		<title>QCherry: Update 0.1.3 camera world placement, streaming safety and far camera test</title>
		<link rel="alternate" type="text/html" href="https://g1r-mp.com/wiki/index.php?title=MoveCameraTo&amp;diff=820&amp;oldid=prev"/>
		<updated>2026-09-09T00:07:51Z</updated>

		<summary type="html">&lt;p&gt;Update 0.1.3 camera world placement, streaming safety and far camera test&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw-interface=&quot;&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 00:07, 9 September 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l59&quot;&gt;Line 59:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 59:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Rotation interpolation uses shortest-angle transitions; FOV is interpolated as part of the pose.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Rotation interpolation uses shortest-angle transitions; FOV is interpolated as part of the pose.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Only the owning resource may change an already controlled camera. Server and client ownership are distinct, even when resource names match; use one side consistently for a camera sequence.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Only the owning resource may change an already controlled camera. Server and client ownership are distinct, even when resource names match; use one side consistently for a camera sequence.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Camera positions and &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;complete paths/&lt;/del&gt;orbits must &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;stay &lt;/del&gt;within &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;100 &lt;/del&gt;metres &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;of &lt;/del&gt;the &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;local character&lt;/del&gt;. Camera control does not move the character, change replication distance, freeze input, or enable remote-player spectating.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Camera positions&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;, paths &lt;/ins&gt;and orbits &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;have no distance limit relative to the local character. All world coordinates &lt;/ins&gt;must &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;remain finite and &lt;/ins&gt;within &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;-1,000,000 to 1,000,000 &lt;/ins&gt;metres&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;; &lt;/ins&gt;the &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;complete orbit extent is validated too&lt;/ins&gt;. Camera control does not move the character, change replication distance, freeze input, or enable remote-player spectating.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Use [[resetCameraPos]] to restore gameplay view. Resource stop, disconnect and world/character changes release camera ownership; see [[onClientCameraReset]].&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* Use [[resetCameraPos]] to restore gameplay view. Resource stop, disconnect and world/character changes release camera ownership; see [[onClientCameraReset]].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* An applied acknowledgement confirms command handling, not &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;that the resulting view has rendered&lt;/del&gt;. For a fresh read-back, request state after another frame or a short timer. See [[Scripted camera]] for lifecycle, acknowledgement and state-cache details.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;* An applied acknowledgement confirms command handling, not &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;rendering or completion of world streaming&lt;/ins&gt;. For a fresh read-back, request state after another frame or a short timer. See [[Scripted camera]] for &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;distant scenes, &lt;/ins&gt;lifecycle, acknowledgement and state-cache details.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Lua Functions]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Lua Functions]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Shared Functions]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Shared Functions]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Camera Functions]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Camera Functions]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>QCherry</name></author>
	</entry>
	<entry>
		<id>https://g1r-mp.com/wiki/index.php?title=MoveCameraTo&amp;diff=803&amp;oldid=prev</id>
		<title>QCherry: Document scripted camera API and events available from G1R:MP 0.1.3</title>
		<link rel="alternate" type="text/html" href="https://g1r-mp.com/wiki/index.php?title=MoveCameraTo&amp;diff=803&amp;oldid=prev"/>
		<updated>2026-09-08T23:50:55Z</updated>

		<summary type="html">&lt;p&gt;Document scripted camera API and events available from G1R:MP 0.1.3&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= moveCameraTo =&lt;br /&gt;
&amp;lt;div style=&amp;quot;background:#fff5f5; border:1px solid #d13b3b; border-left:5px solid #d13b3b; color:#111111; padding:0.85rem 1rem; margin:0.75rem 0 1rem;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;color:#111111; font-weight:bold; letter-spacing:0.04em;&amp;quot;&amp;gt;AVAILABLE FROM UPDATE 0.1.3&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;div style=&amp;quot;color:#111111; margin-top:0.25rem;&amp;quot;&amp;gt;This function is available in G1R:MP 0.1.3 and later. The contract below includes the compatibility guarantees introduced in that update.&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Interpolates the scripted camera from its current pose to a target position, rotation and FOV.&lt;br /&gt;
&lt;br /&gt;
== Syntax ==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
-- Client-side&lt;br /&gt;
number|false moveCameraTo(table pose, number durationMs [, string easing = &amp;quot;smooth&amp;quot;])&lt;br /&gt;
-- Server-side&lt;br /&gt;
bool moveCameraTo(int playerId, table pose, number durationMs [, string easing = &amp;quot;smooth&amp;quot;])&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Parameters ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Name !! Type !! Required !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;playerId&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;int&amp;lt;/code&amp;gt; || yes || Server-side only: the connected player whose local camera receives the command.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;pose&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;table&amp;lt;/code&amp;gt; || yes || Target pose using x/y/z, pitch/yaw/roll and fov. See side-specific defaults below.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;durationMs&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;int&amp;lt;/code&amp;gt; || yes || Whole milliseconds from 0 to 600,000; 0 performs an immediate transition.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;easing&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;string&amp;lt;/code&amp;gt; || no || One of linear, smooth, in or out. Defaults to smooth.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Returns ==&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Client-side:&amp;#039;&amp;#039;&amp;#039; a positive &amp;lt;code&amp;gt;requestId&amp;lt;/code&amp;gt;, or &amp;lt;code&amp;gt;false&amp;lt;/code&amp;gt; when validation or queuing fails. Wait for [[onClientCameraCommandResult]] to learn the execution result. &amp;#039;&amp;#039;&amp;#039;Server-side:&amp;#039;&amp;#039;&amp;#039; &amp;lt;code&amp;gt;true&amp;lt;/code&amp;gt; only means validated and queued for the connected player; &amp;lt;code&amp;gt;false&amp;lt;/code&amp;gt; means rejected. A server return value is not a client acknowledgement.&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
Read the local camera/player state before issuing the command. The command&amp;#039;s own result arrives separately in onClientCameraCommandResult.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot; line&amp;gt;&lt;br /&gt;
-- Client-side: run after the local world and player camera are ready.&lt;br /&gt;
local query&lt;br /&gt;
addEventHandler(&amp;quot;onClientCameraCommandResult&amp;quot;, resourceRoot,&lt;br /&gt;
    function(requestId, ok, phase, errorText, stateJson)&lt;br /&gt;
        if requestId ~= query then return end&lt;br /&gt;
        query = nil&lt;br /&gt;
        if not ok or phase ~= &amp;quot;state&amp;quot; then&lt;br /&gt;
            outputDebugString(&amp;quot;Camera query failed: &amp;quot; .. tostring(errorText), 2)&lt;br /&gt;
            return&lt;br /&gt;
        end&lt;br /&gt;
        local state = getCameraState()&lt;br /&gt;
        if not state or not state.ready then return end&lt;br /&gt;
        moveCameraTo({x=state.playerX - 5, y=state.playerY + 3, z=state.playerZ + 3,&lt;br /&gt;
            pitch=-15, yaw=-30, roll=0, fov=70}, 3000, &amp;quot;smooth&amp;quot;)&lt;br /&gt;
    end)&lt;br /&gt;
query = requestCameraState()&lt;br /&gt;
if not query then outputDebugString(&amp;quot;Camera query was not queued&amp;quot;, 2) end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Notes ==&lt;br /&gt;
* Available in client-side and server-side resource scripts. Equivalent PascalCase spelling: &amp;lt;code&amp;gt;MoveCameraTo&amp;lt;/code&amp;gt;.&lt;br /&gt;
* Client-side pose fields omitted after a ready acknowledged state inherit that resource&amp;#039;s cached pose. Without such a cache, all seven fields (x, y, z, pitch, yaw, roll, fov) are required. Server-side x/y/z are required and omitted angles default to 0, FOV to 90; there is no server camera cache.&lt;br /&gt;
* Client success phases are &amp;lt;code&amp;gt;applied&amp;lt;/code&amp;gt; followed by &amp;lt;code&amp;gt;completed&amp;lt;/code&amp;gt;. A replacement movement, stop or reset can cancel the earlier movement; correlate results by requestId.&lt;br /&gt;
* Rotation interpolation uses shortest-angle transitions; FOV is interpolated as part of the pose.&lt;br /&gt;
* Only the owning resource may change an already controlled camera. Server and client ownership are distinct, even when resource names match; use one side consistently for a camera sequence.&lt;br /&gt;
* Camera positions and complete paths/orbits must stay within 100 metres of the local character. Camera control does not move the character, change replication distance, freeze input, or enable remote-player spectating.&lt;br /&gt;
* Use [[resetCameraPos]] to restore gameplay view. Resource stop, disconnect and world/character changes release camera ownership; see [[onClientCameraReset]].&lt;br /&gt;
* An applied acknowledgement confirms command handling, not that the resulting view has rendered. For a fresh read-back, request state after another frame or a short timer. See [[Scripted camera]] for lifecycle, acknowledgement and state-cache details.&lt;br /&gt;
&lt;br /&gt;
[[Category:Lua Functions]]&lt;br /&gt;
[[Category:Shared Functions]]&lt;br /&gt;
[[Category:Camera Functions]]&lt;/div&gt;</summary>
		<author><name>QCherry</name></author>
	</entry>
</feed>