<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
	<channel>
		<title><![CDATA[Maratis forum - Mouse Look question]]></title>
		<link>http://forum.maratis3d.com/viewtopic.php?id=464</link>
		<description><![CDATA[The most recent posts in Mouse Look question.]]></description>
		<lastBuildDate>Thu, 06 Dec 2012 23:49:47 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Mouse Look question]]></title>
			<link>http://forum.maratis3d.com/viewtopic.php?pid=3009#p3009</link>
			<description><![CDATA[<p>Final Update on this chapter <img src="http://forum.maratis3d.com/img/smilies/big_smile.png" width="15" height="15" alt="big_smile" /> it truns out i did not need to add the timer to the cursor update, what needed to do was to disable the compositor features of xfce (i use xubuntu) it seems that when compositing is enabled, the centercursor function does not work as expected. </p><p>this may or may not apply to other compositors</p>]]></description>
			<author><![CDATA[dummy@example.com (damvcoool)]]></author>
			<pubDate>Thu, 06 Dec 2012 23:49:47 +0000</pubDate>
			<guid>http://forum.maratis3d.com/viewtopic.php?pid=3009#p3009</guid>
		</item>
		<item>
			<title><![CDATA[Re: Mouse Look question]]></title>
			<link>http://forum.maratis3d.com/viewtopic.php?pid=2836#p2836</link>
			<description><![CDATA[<p>i think i solved my problem, and this might be a bug in linux (not sure) but it seems that the mouse update was not as quick as the scene update hence it would seem to not register the move of the mouse.</p><p>I use this&nbsp; see below (stole the idea from another thread that was asking how to add timers), i still need to tweak the time it takes to update so it does not look so jumpy.</p><p>-- center cursor<br />&nbsp; &nbsp; if t == 20&nbsp; then<br />&nbsp; &nbsp; centerCursor()<br />&nbsp; &nbsp; t = 0<br />&nbsp; &nbsp; end<br />t = t + 1</p>]]></description>
			<author><![CDATA[dummy@example.com (damvcoool)]]></author>
			<pubDate>Mon, 29 Oct 2012 05:36:41 +0000</pubDate>
			<guid>http://forum.maratis3d.com/viewtopic.php?pid=2836#p2836</guid>
		</item>
		<item>
			<title><![CDATA[Re: Mouse Look question]]></title>
			<link>http://forum.maratis3d.com/viewtopic.php?pid=2835#p2835</link>
			<description><![CDATA[<p>Thanks for the suggestion, however, i now remember why i commented the centerCursor() function, if i enable it, there is no mouse look at al :S.<br />I am 100% new to game dev (to be honest even to programming at all) just trying to learn using all these incredibly useful tools.</p><p>I added a print to the text the output mx and noticed it only changes from 0 to close to 1 (0.9999) so i am guessing MOUSE_X is float that only accepts 0 to 1.</p><p>to expliain a bit more, my camera is attached to Head much like in the video tutorial, however my function does not reside directly in onScreenUpdate, it&#039;s a separate function (for organization and learning experience).</p><p>I also tried moving the centerCursor() to the onScreenUpdate main function, but same result, moving the mouse does nothing :S a bug on Maratis on linux? or just my newbie issues?</p>]]></description>
			<author><![CDATA[dummy@example.com (damvcoool)]]></author>
			<pubDate>Mon, 29 Oct 2012 02:27:22 +0000</pubDate>
			<guid>http://forum.maratis3d.com/viewtopic.php?pid=2835#p2835</guid>
		</item>
		<item>
			<title><![CDATA[Re: Mouse Look question]]></title>
			<link>http://forum.maratis3d.com/viewtopic.php?pid=2833#p2833</link>
			<description><![CDATA[<p>Thanks (: The problem here is that you have quoted out the centerCursor() function; just remove the -- in front of it and it should work fine (assuming that this is just an extract from your script).</p>]]></description>
			<author><![CDATA[dummy@example.com (special_ops)]]></author>
			<pubDate>Sun, 28 Oct 2012 16:31:32 +0000</pubDate>
			<guid>http://forum.maratis3d.com/viewtopic.php?pid=2833#p2833</guid>
		</item>
		<item>
			<title><![CDATA[Mouse Look question]]></title>
			<link>http://forum.maratis3d.com/viewtopic.php?pid=2832#p2832</link>
			<description><![CDATA[<p>Hello I have used this script (look below) for mouse look on my game(test), however i am faced with a problem where i can only move side ways so far, and I cannot do a 360 view. can i get some help here? </p><p>by the way I took this example from the Video tutorials from special_ops (great tutorials by the way)</p><p>&lt;code&gt;<br />-- Global Variables<br />dx = 0.0<br />dy = 0.0<br />centerCursor()<br />my = getAxis(&quot;MOUSE_Y&quot;)<br />mx = getAxis(&quot;MOUSE_X&quot;)<br />-- stuff<br />hideCursor()</p><p>function MoveAround()</p><p>&nbsp; &nbsp; -- look around<br />&nbsp; &nbsp; -- X Axis<br />&nbsp; &nbsp; rotate(Player, {0, 0, -1}, dx*100)</p><p>&nbsp; &nbsp; -- Y Axis<br />&nbsp; &nbsp; rotate(Head, {1, 0, 0}, dy*100, &quot;local&quot;)<br />&nbsp; &nbsp; rotation = getRotation(Head)<br />&nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; if rotation[1]&gt;90 then<br />&nbsp; &nbsp; &nbsp; &nbsp; rotation[1] = 90<br />&nbsp; &nbsp; elseif rotation[1] &lt; -90 then<br />&nbsp; &nbsp; &nbsp; &nbsp; rotation[1] = -90<br />&nbsp; &nbsp; end&nbsp; &nbsp; <br />&nbsp; &nbsp; &nbsp; &nbsp; <br />&nbsp; &nbsp; -- get new mouse position<br />&nbsp; &nbsp; dx = getAxis(&quot;MOUSE_X&quot;) - mx<br />&nbsp; &nbsp; dy = getAxis(&quot;MOUSE_Y&quot;) - my<br />&nbsp; &nbsp; <br />&nbsp; &nbsp; -- center cursor<br />&nbsp; &nbsp; --centerCursor()<br />&nbsp; &nbsp; <br />&nbsp; &nbsp; mx = getAxis(&quot;MOUSE_X&quot;)<br />&nbsp; &nbsp; my = getAxis(&quot;MOUSE_Y&quot;)<br />&lt;/code&gt;</p>]]></description>
			<author><![CDATA[dummy@example.com (damvcoool)]]></author>
			<pubDate>Sun, 28 Oct 2012 15:51:22 +0000</pubDate>
			<guid>http://forum.maratis3d.com/viewtopic.php?pid=2832#p2832</guid>
		</item>
	</channel>
</rss>
