<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Maratis forum - setCurrentBehavior]]></title>
	<link rel="self" href="http://forum.maratis3d.com/extern.php?action=feed&amp;tid=547&amp;type=atom"/>
	<updated>2013-01-16T09:57:36Z</updated>
	<generator>PunBB</generator>
	<id>http://forum.maratis3d.com/viewtopic.php?id=547</id>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3448#p3448"/>
			<content type="html"><![CDATA[<p>yes setBehaviorVariable and getBehaviorVariable are only there to access a behavior variables that is already there.</p>]]></content>
			<author>
				<name><![CDATA[anael]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2</uri>
			</author>
			<updated>2013-01-16T09:57:36Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3448#p3448</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3437#p3437"/>
			<content type="html"><![CDATA[<p>Thank you Anael, I wasn&#039;t aware that I needed to set my model to lookAt already IN the editor, once again thanks. <img src="http://forum.maratis3d.com/img/smilies/smile.png" width="15" height="15" alt="smile" /></p>]]></content>
			<author>
				<name><![CDATA[Pär]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1252</uri>
			</author>
			<updated>2013-01-15T22:37:18Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3437#p3437</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3436#p3436"/>
			<content type="html"><![CDATA[<p>Ahhh I see I was wondering why when I was trying to do a billboarding deal with my plants and grass it got all weird.</p>]]></content>
			<author>
				<name><![CDATA[zester]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=516</uri>
			</author>
			<updated>2013-01-15T22:36:29Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3436#p3436</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3435#p3435"/>
			<content type="html"><![CDATA[<p>Did you add a LookAt behavior on your trylare model in the editor ?<br />and is it the first behavior in the list (0 in the function access the first behavior of the object)</p><p>if trylare having a parent it is linked to ? a parent link might conflict with the look-at.</p>]]></content>
			<author>
				<name><![CDATA[anael]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2</uri>
			</author>
			<updated>2013-01-15T22:35:12Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3435#p3435</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3433#p3433"/>
			<content type="html"><![CDATA[<p>Ok, my playername is player in the editor. And my sensor has a collisionshape in ghost mode.</p><p>Oh, there is collision detected. <img src="http://forum.maratis3d.com/img/smilies/smile.png" width="15" height="15" alt="smile" /></p><p>I write: setBehaviorVariable(trylare, 0, &quot;target&quot;, &quot;player&quot;) setBehaviorVariable(trylare_model, 0, &quot;target&quot;, &quot;player&quot;) in function onSceneUpdate() without any if statements but nothing happens, what&#039;s wrong?</p>]]></content>
			<author>
				<name><![CDATA[Pär]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1252</uri>
			</author>
			<updated>2013-01-15T22:27:48Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3433#p3433</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3430#p3430"/>
			<content type="html"><![CDATA[<p>Vegas : it&#039;s because the look at is using the Z axis (the one originally used by camera),<br />but to not have to re-export the character, use an invisible box and link your character to it.</p><p>Par : I&#039;m not sure I understand what you mean.<br />Check first if the collision is detected, then check if your player name is &quot;player&quot; in the editor,<br />and that sensor is having a collision shape (in ghost mode I guess).</p>]]></content>
			<author>
				<name><![CDATA[anael]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2</uri>
			</author>
			<updated>2013-01-15T22:21:38Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3430#p3430</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3422#p3422"/>
			<content type="html"><![CDATA[<p>I understand. <img src="http://forum.maratis3d.com/img/smilies/smile.png" width="15" height="15" alt="smile" /> Well, there is no problem if I set my player to lookAt in maratis and then execute it. But if I try to write it out in the console then nothing happens. And my robot is moving already, so maybe a bug?</p><p>Thanks for the reply.</p>]]></content>
			<author>
				<name><![CDATA[Pär]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1252</uri>
			</author>
			<updated>2013-01-15T21:39:06Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3422#p3422</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3421#p3421"/>
			<content type="html"><![CDATA[<p>To make characters look at another entity with the LookAt behavior (like the zombie in <a href="http://forum.maratis3d.com/viewtopic.php?id=174">This example</a>) personally i have to export the models in that position (or something similiar) :</p><p><span class="postimg"><img src="https://dl.dropbox.com/u/19970067/Questions/Mineworker.png" alt="PunBB bbcode test" /></span></p><p>Then if i need to move them ; addCentralForce(object, {0, 0, -1}, &quot;local&quot;) </p><p>That&#039;s a bit weird but it works =p</p>]]></content>
			<author>
				<name><![CDATA[Vegas]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=53</uri>
			</author>
			<updated>2013-01-15T21:35:10Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3421#p3421</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3409#p3409"/>
			<content type="html"><![CDATA[<p>Hm, I wrote it out just:</p><p> setBehaviorVariable(robot, 0, &quot;target&quot;, &quot;player&quot;)</p><p>In the console but nothing happened.</p>]]></content>
			<author>
				<name><![CDATA[Pär]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1252</uri>
			</author>
			<updated>2013-01-15T17:59:05Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3409#p3409</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3401#p3401"/>
			<content type="html"><![CDATA[<p>The setBehaviorVariable code is right, maybe the problem comes from the collision detection ?</p>]]></content>
			<author>
				<name><![CDATA[anael]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2</uri>
			</author>
			<updated>2013-01-15T09:02:00Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3401#p3401</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3395#p3395"/>
			<content type="html"><![CDATA[<p>I think that You has to disable the behaviour when the person goes away from the sensor.</p><p>if isCollisionBetween(player,sensor) then<br />&nbsp; &nbsp; &nbsp; --code to enable behaviour<br />else<br />&nbsp; &nbsp; &nbsp; --code to disable behaviour<br />end</p>]]></content>
			<author>
				<name><![CDATA[SadWolf]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1268</uri>
			</author>
			<updated>2013-01-14T23:06:28Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3395#p3395</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[setCurrentBehavior]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=3392#p3392"/>
			<content type="html"><![CDATA[<p>Hello, I would want to question about setCurrentBehavior.</p><p>When I set my robot to look at the person when he is in range of the robots sensor (a cylinder) it doesn&#039;t look that way.</p><p>This is my script:</p><p>if isCollisionBetween(player,sensor) then</p><p>&nbsp; &nbsp; &nbsp; &nbsp; setBehaviorVariable(robot, 0, &quot;target&quot;, &quot;player&quot;)</p><p>end</p>]]></content>
			<author>
				<name><![CDATA[Pär]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=1252</uri>
			</author>
			<updated>2013-01-14T20:54:05Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=3392#p3392</id>
		</entry>
</feed>
