<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<title type="html"><![CDATA[Maratis forum - How to delete clones?]]></title>
	<link rel="self" href="http://forum.maratis3d.com/extern.php?action=feed&amp;tid=925&amp;type=atom"/>
	<updated>2014-02-10T15:57:19Z</updated>
	<generator>PunBB</generator>
	<id>http://forum.maratis3d.com/viewtopic.php?id=925</id>
		<entry>
			<title type="html"><![CDATA[Re: How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6407#p6407"/>
			<content type="html"><![CDATA[<p>Thank you! When I am finished getting the graphical side of things figured out, I can dig deeper into the code side of things, and these posts will help a lot, thanks!.</p>]]></content>
			<author>
				<name><![CDATA[Tutorial Doctor]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2493</uri>
			</author>
			<updated>2014-02-10T15:57:19Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6407#p6407</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6396#p6396"/>
			<content type="html"><![CDATA[<p>oops i made a mistake, you don&#039;t need getObject nor getName to deactivate the clones in cloneList,<br />deactivate(cloneList[number]) is enough,</p><p>getName is to use with <a href="http://wiki.maratis3d.org/index.php?title=SetBehaviorVariable">SetBehaviorVariable</a><br />example, setBehaviorVariable(Camera, 0, &quot;target&quot;, &quot;cloneList[number]&quot;) : won&#039;t work, it&#039;s here <br />you have to getObject/getName</p>]]></content>
			<author>
				<name><![CDATA[Vegas]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=53</uri>
			</author>
			<updated>2014-02-10T09:47:23Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6396#p6396</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6334#p6334"/>
			<content type="html"><![CDATA[<p>Thanks Vegas. I am trying to get the speed bumps out of the way, I might need this functionality in the future. The code I posted on my post called &quot;Code snippets&quot; can clone a bunch of objects (get&#039;s slow when physics are turned on) but I wanted to use them as markers that delete the last clone one a certain number of clones has been created. Once I a decent animated test character I will start making more test levels and code snippets.</p>]]></content>
			<author>
				<name><![CDATA[Tutorial Doctor]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2493</uri>
			</author>
			<updated>2014-02-05T17:12:32Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6334#p6334</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6301#p6301"/>
			<content type="html"><![CDATA[<p>Yep that&#039;s it, well taking the example from the wiki,&nbsp; the very basic usage is :</p><div class="codebox"><pre><code>object = getObject(&quot;object&quot;)
cloneList = {}

function onSceneUpdate()
   
    if onKeyDown(&quot;1&quot;) then
        table.insert(cloneList, #cloneList + 1, getClone(object)) -- create a clone
    end

    if onKeyDown(&quot;2&quot;) then
        toDelete = getObject(getName(cloneList[3])) -- 3 is just for example
        deactivate(toDelete)
    end
   
end</code></pre></div><p>Hope it helps</p>]]></content>
			<author>
				<name><![CDATA[Vegas]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=53</uri>
			</author>
			<updated>2014-01-31T08:13:53Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6301#p6301</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6300#p6300"/>
			<content type="html"><![CDATA[<p>That looks like it would delete the third item in the cloneList table. </p><p>I just found out how to use the table.insert function and the table.remove function. But I don&#039;t know how to use it to do this.</p>]]></content>
			<author>
				<name><![CDATA[Tutorial Doctor]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2493</uri>
			</author>
			<updated>2014-01-31T03:01:50Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6300#p6300</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[Re: How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6291#p6291"/>
			<content type="html"><![CDATA[<p>If i remember correctly you must use something like</p><div class="codebox"><pre><code>toDelete = getObject(getName(cloneList[3])) -- 3 is just for example
deactivate(toDelete)</code></pre></div>]]></content>
			<author>
				<name><![CDATA[Vegas]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=53</uri>
			</author>
			<updated>2014-01-30T02:43:27Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6291#p6291</id>
		</entry>
		<entry>
			<title type="html"><![CDATA[How to delete clones?]]></title>
			<link rel="alternate" href="http://forum.maratis3d.com/viewtopic.php?pid=6289#p6289"/>
			<content type="html"><![CDATA[<p>How would I delete clones that have been added to a scene. In my Code snippets post I am able to create them, and I have a counter that can do something once it reaches a number (used it for tracking how many times a key was pressed). </p><p>But when I use the deactivate item on the original object from which the clones were made, maratis crashes. </p><p>How do I delete the clones individually? Would I have to use that clonelist thing from the wiki in some special way?</p><p><a href="http://wiki.maratis3d.org/index.php?title=GetClone">http://wiki.maratis3d.org/index.php?title=GetClone</a></p>]]></content>
			<author>
				<name><![CDATA[Tutorial Doctor]]></name>
				<uri>http://forum.maratis3d.com/profile.php?id=2493</uri>
			</author>
			<updated>2014-01-30T01:29:41Z</updated>
			<id>http://forum.maratis3d.com/viewtopic.php?pid=6289#p6289</id>
		</entry>
</feed>
