<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Infinity Code Forum — NGUI Rotate the camera on a compass]]></title>
		<link>https://forum.infinity-code.com/viewtopic.php?id=195</link>
		<atom:link href="https://forum.infinity-code.com/extern.php?action=feed&amp;tid=195&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in NGUI Rotate the camera on a compass.]]></description>
		<lastBuildDate>Tue, 26 Jul 2016 00:41:12 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=928#p928</link>
			<description><![CDATA[<p>Thank you for quick response.</p><p>It works fine.</p>]]></description>
			<author><![CDATA[null@example.com (mininox)]]></author>
			<pubDate>Tue, 26 Jul 2016 00:41:12 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=928#p928</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=921#p921</link>
			<description><![CDATA[<p>Hello.</p><p>I can see on the video that you have problems with custom marker system for NGUI, right?<br />We fixed it. Now it will work correctly.<br />Please update Online Maps.</p>]]></description>
			<author><![CDATA[null@example.com (Alex Vertax)]]></author>
			<pubDate>Mon, 25 Jul 2016 19:56:35 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=921#p921</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=914#p914</link>
			<description><![CDATA[<p>Hello.</p><p>private void OnCompassChanged(float compass)<br />&nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; Debug.Log(&quot;compass : &quot; + compass);<br />&nbsp; &nbsp; &nbsp; &nbsp; int angle = (int)(compass * 360);<br />&nbsp; &nbsp; &nbsp; &nbsp; this.MainUI.t_Compass.text = angle.ToString();<br />&nbsp; &nbsp; &nbsp; &nbsp; this.Map.transform.rotation = Quaternion.Euler(0, 0, angle);<br />&nbsp; &nbsp; }</p><p>The map will rotate well.</p><p>but When dragging a rotated map, marker is problem.</p><p>link : <a href="https://dl.dropboxusercontent.com/u/164464635/IMG_0581.m4v">https://dl.dropboxusercontent.com/u/164 … G_0581.m4v</a></p>]]></description>
			<author><![CDATA[null@example.com (mininox)]]></author>
			<pubDate>Mon, 25 Jul 2016 08:48:34 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=914#p914</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=911#p911</link>
			<description><![CDATA[<p>Hello.</p><p>What is «angle» in your script?<br />The parameter is called «f».</p><p>The code that I tested, and that works for NGUI:<br /></p><div class="codebox"><pre><code>using UnityEngine;

public class RotateNGUITextureByCompass : MonoBehaviour
{
    private void Start()
    {
        OnlineMapsLocationService.instance.OnCompassChanged += OnCompassChanged;
    }

    private void OnCompassChanged(float f)
    {
        transform.rotation = Quaternion.Euler(0, 0, f * 360);
    }
}</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (Alex Vertax)]]></author>
			<pubDate>Mon, 25 Jul 2016 07:50:38 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=911#p911</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=909#p909</link>
			<description><![CDATA[<p>Answer Thank you</p><p>I was late for an answer.</p><p>How use?</p><p>my version v2.4.0.53.</p><p>I&#039;ve written to the code above</p><p>private void OnCompassChanged(float f)<br />{<br />&nbsp; &nbsp; &nbsp; &nbsp; this.transform.rotation = Quaternion.Euler(0,0,angle); //(UITexture GameObject)<br />}</p><p>There are still problems (Marker Position problems) when Drag.</p>]]></description>
			<author><![CDATA[null@example.com (mininox)]]></author>
			<pubDate>Mon, 25 Jul 2016 05:34:35 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=909#p909</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=898#p898</link>
			<description><![CDATA[<p>Hello.</p><p>Update is now available.</p>]]></description>
			<author><![CDATA[null@example.com (Alex Vertax)]]></author>
			<pubDate>Fri, 22 Jul 2016 10:55:09 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=898#p898</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=894#p894</link>
			<description><![CDATA[<p>Thank you. Answer.</p><p>I look forward to solutions.</p>]]></description>
			<author><![CDATA[null@example.com (mininox)]]></author>
			<pubDate>Fri, 22 Jul 2016 05:34:17 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=894#p894</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=889#p889</link>
			<description><![CDATA[<p>That&#039;s funny.<br />I wrote previous post and immediately found a way how to do it.<br />Within 24 hours we will release update (through the built-in update system), which will support the rotation of NGUI map.</p>]]></description>
			<author><![CDATA[null@example.com (Alex Vertax)]]></author>
			<pubDate>Thu, 21 Jul 2016 13:26:26 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=889#p889</guid>
		</item>
		<item>
			<title><![CDATA[Re: NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=888#p888</link>
			<description><![CDATA[<p>Hello.</p><p>This example is created for Tileset.<br />NGUI control does not support rotation of map.<br />If you want to rotate the camera / map, use Tileset control.</p><p>At the moment I have no idea how to convert the screen coordinate to relative point of rotated widget.<br />I&#039;ll try to ask NGUI creators. If they give me some advice, we will add this feature.</p>]]></description>
			<author><![CDATA[null@example.com (Alex Vertax)]]></author>
			<pubDate>Thu, 21 Jul 2016 12:15:33 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=888#p888</guid>
		</item>
		<item>
			<title><![CDATA[NGUI Rotate the camera on a compass]]></title>
			<link>https://forum.infinity-code.com/viewtopic.php?pid=877#p877</link>
			<description><![CDATA[<p>Hello</p><p>using UnityEngine;</p><p>namespace InfinityCode.OnlineMapsExamples<br />{<br />&nbsp; &nbsp; [AddComponentMenu(&quot;Infinity Code/Online Maps/Examples (API Usage)/RoteteCameraByGPSExample&quot;)]<br />&nbsp; &nbsp; public class RoteteCameraByGPSExample : MonoBehaviour<br />&nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; private void Start()<br />&nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OnlineMapsLocationService.instance.OnCompassChanged += OnCompassChanged;<br />&nbsp; &nbsp; &nbsp; &nbsp; }</p><p>&nbsp; &nbsp; &nbsp; &nbsp; private void OnCompassChanged(float f)<br />&nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; OnlineMapsTileSetControl.instance.cameraRotation.y = f * 360;<br />&nbsp; &nbsp; &nbsp; &nbsp; }<br />&nbsp; &nbsp; }<br />}</p><p>NGUI Only Texture. The above source does not operate.</p><p>&nbsp; &nbsp; &nbsp; &nbsp; private void OnCompassChanged(float f)<br />&nbsp; &nbsp; &nbsp; &nbsp; {<br />&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; this.transform.rotation = Quaternion.Euler(0,0,angle); //(UITexture GameObject)<br />&nbsp; &nbsp; &nbsp; &nbsp; }</p><p>The above source, rotate well. But there is a problem with touch and drag the marker.</p><p>Please NGUI Rotate the camera on a compass.</p><p>I&#039;m sorry that I can not speak English.</p><p>Thank you.</p>]]></description>
			<author><![CDATA[null@example.com (mininox)]]></author>
			<pubDate>Thu, 21 Jul 2016 05:17:43 +0000</pubDate>
			<guid>https://forum.infinity-code.com/viewtopic.php?pid=877#p877</guid>
		</item>
	</channel>
</rss>
