<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/wiki/RO/setCameraTarget?action=history&amp;feed=atom</id>
	<title>RO/setCameraTarget - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/wiki/RO/setCameraTarget?action=history&amp;feed=atom"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=RO/setCameraTarget&amp;action=history"/>
	<updated>2026-05-18T08:31:01Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=RO/setCameraTarget&amp;diff=73908&amp;oldid=prev</id>
		<title>Vinyard: Removed the issues section of this page in accordance to the removal of the issues section on the English page.</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=RO/setCameraTarget&amp;diff=73908&amp;oldid=prev"/>
		<updated>2022-01-30T13:05:12Z</updated>

		<summary type="html">&lt;p&gt;Removed the issues section of this page in accordance to the removal of the issues section on the English page.&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&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 13:05, 30 January 2022&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-l73&quot;&gt;Line 73:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 73:&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;&amp;lt;/syntaxhighlight&amp;gt;&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;&amp;lt;/syntaxhighlight&amp;gt;&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;&amp;lt;/section&amp;gt;&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;&amp;lt;/section&amp;gt;&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;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&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;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;== Probleme ==&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&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;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{RO/Issues|&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&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;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{Issue|7594|(Rezolvat în r11452) setCameraTarget asupra unui jucător aflat într-un vehicul cu hidraulice cauzează probleme camerei}}&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&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;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;}}&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&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;==Vizualizați de asemenea==&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;==Vizualizați de asemenea==&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key wiki-wiki_dev_:diff::1.12:old-67480:rev-73908 --&gt;
&lt;/table&gt;</summary>
		<author><name>Vinyard</name></author>
	</entry>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=RO/setCameraTarget&amp;diff=67480&amp;oldid=prev</id>
		<title>Vinyard: Created page with &quot;__NOTOC__ {{RO/Funcție comună}} Această funcție vă permite să setați camera jucătorului pentru a urmări alte elemente. Tipurile de element disponibile în acest momen...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=RO/setCameraTarget&amp;diff=67480&amp;oldid=prev"/>
		<updated>2020-10-10T08:39:40Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;__NOTOC__ {{RO/Funcție comună}} Această funcție vă permite să setați camera jucătorului pentru a urmări alte elemente. Tipurile de element disponibile în acest momen...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;__NOTOC__&lt;br /&gt;
{{RO/Funcție comună}}&lt;br /&gt;
Această funcție vă permite să setați camera jucătorului pentru a urmări alte elemente. Tipurile de element disponibile în acest moment:&lt;br /&gt;
*[[Player]]s&lt;br /&gt;
&lt;br /&gt;
==Sintaxă==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Server&amp;quot; class=&amp;quot;server&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool setCameraTarget(player thePlayer [, player target = nil])&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
{{OOP||[[player]]:setCameraTarget|cameraTarget|getCameraTarget}}&lt;br /&gt;
===Argumente Necesare=== &lt;br /&gt;
*'''thePlayer:''' Jucătorul a cărui cameră doriți să urmărească un element.&lt;br /&gt;
&lt;br /&gt;
===Argumente Opționale===&lt;br /&gt;
*'''target:''' Jucătorul pe care doriți să îl urmăriți cu camera. Dacă nici unul nu este specificat, camera va urmări jucătorul.&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client 1&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
bool setCameraTarget(player target)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Argumente Necesare=== &lt;br /&gt;
*'''target:''' Jucătorul a cărui cameră doriți să urmărească un element.&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{New feature/item|3.0132|1.3.1|5212|&lt;br /&gt;
&amp;lt;section name=&amp;quot;Client 2&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
Această sintaxă menține jucătorul țintit de către cameră, însă face camera să privească spre coordonatele specificate. Nu are efect atunci când camera nu are un target.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool setCameraTarget(float targetX, float targetY, float targetZ)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Argumente Necesare===&lt;br /&gt;
*'''targetX, targetY, targetZ:''' Poziția țintei (target-ului) spre care doriți să privească camera locală.&lt;br /&gt;
&amp;lt;/section&amp;gt;}}&lt;br /&gt;
&lt;br /&gt;
===Redare===&lt;br /&gt;
Redă ''true'' dacă funcția a avut succes. În caz contrar, ''false''.&lt;br /&gt;
&lt;br /&gt;
==Exemplu==&lt;br /&gt;
Acesta este un exemplu despre cum se poate implementa o funcție de spectator. Folosind săgețile stânga și dreapta puteți vizualiza alți jucători. Aveți în vedere că acest cod nu este complete și nu ia în considerare jucătorii care se (de)conectează.&lt;br /&gt;
&amp;lt;section class=&amp;quot;client&amp;quot; name=&amp;quot;Client script&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
g_Players = getElementsByType(&amp;quot;player&amp;quot;) -- obține o listă cu jucătorii de pe server&lt;br /&gt;
for i,aPlayer in ipairs(g_Players) do -- descoperă ce index are jucătorul local din listă&lt;br /&gt;
    if aPlayer == localPlayer then&lt;br /&gt;
        g_CurrentSpectated = i&lt;br /&gt;
        break&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function spectatePrevious() -- scade respectivul index și urmărește jucătorul corespunzător&lt;br /&gt;
     if g_CurrentSpectated == 1 then&lt;br /&gt;
         g_CurrentSpectated = #g_Players&lt;br /&gt;
     else&lt;br /&gt;
         g_CurrentSpectated = g_CurrentSpectated - 1&lt;br /&gt;
     end&lt;br /&gt;
    setCameraTarget(g_Players[g_CurrentSpectated])&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
function spectateNext() -- crește respectivul index și urmărește jucătorul corespunzător&lt;br /&gt;
     if g_CurrentSpectated == #g_Players then&lt;br /&gt;
         g_CurrentSpectated = 1&lt;br /&gt;
     else&lt;br /&gt;
         g_CurrentSpectated = g_CurrentSpectated + 1&lt;br /&gt;
     end&lt;br /&gt;
    setCameraTarget(g_Players[g_CurrentSpectated])&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- atribuie un bind celor două funcții de mai sus&lt;br /&gt;
bindKey(&amp;quot;arrow_l&amp;quot;, &amp;quot;down&amp;quot;, spectatePrevious)&lt;br /&gt;
bindKey(&amp;quot;arrow_r&amp;quot;, &amp;quot;down&amp;quot;, spectateNext)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Probleme ==&lt;br /&gt;
{{RO/Issues|&lt;br /&gt;
{{Issue|7594|(Rezolvat în r11452) setCameraTarget asupra unui jucător aflat într-un vehicul cu hidraulice cauzează probleme camerei}}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Vizualizați de asemenea==&lt;br /&gt;
{{RO/Funcții cameră}}&lt;br /&gt;
&lt;br /&gt;
[[EN:setCameraTarget]]&lt;br /&gt;
[[hu:setCameraTarget]]&lt;/div&gt;</summary>
		<author><name>Vinyard</name></author>
	</entry>
</feed>