<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/wiki/MTA:Eir/functions/getEntitiesInRenderQueue?action=history&amp;feed=atom</id>
	<title>MTA:Eir/functions/getEntitiesInRenderQueue - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/wiki/MTA:Eir/functions/getEntitiesInRenderQueue?action=history&amp;feed=atom"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=MTA:Eir/functions/getEntitiesInRenderQueue&amp;action=history"/>
	<updated>2026-05-20T01:32:12Z</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=MTA:Eir/functions/getEntitiesInRenderQueue&amp;diff=37869&amp;oldid=prev</id>
		<title>The GTA: Created page with &quot;__NOTOC__  This function returns a table of all MTA entities that are currently added to the rendering queue. Entities on the rendering queue are rendered in a specific order per...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=MTA:Eir/functions/getEntitiesInRenderQueue&amp;diff=37869&amp;oldid=prev"/>
		<updated>2013-12-11T09:07:46Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;__NOTOC__  This function returns a table of all MTA entities that are currently added to the rendering queue. Entities on the rendering queue are rendered in a specific order per...&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;
This function returns a table of all MTA entities that are currently added to the rendering queue. Entities on the rendering queue are rendered in a specific order per frame. GTA:SA creates a new rendering queue every frame, so it is up to date all the time. This function should be called during '''onClientGameEntityPreRender''' as it is the time the lists are sure to be intact: the rendering lists are cleared at the end of the frame.&lt;br /&gt;
&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
table getEntitiesInRenderQueue ()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns a '''table''' with all entities that are rendering this frame.&lt;br /&gt;
&lt;br /&gt;
==Example== &lt;br /&gt;
&amp;lt;section name=&amp;quot;Client&amp;quot; class=&amp;quot;client&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
This snippet marks all entities on the rendering queue for deletion. Since the entities are referenced during the render process to prevent crashes due to invalid pointers, the entities are deleted at the end of the frame when the rendering lists are cleared.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
addEventHandler( &amp;quot;onClientGameEntityPreRender&amp;quot;, root,&lt;br /&gt;
    function()&lt;br /&gt;
        local renderingEntities = getEntitiesInRenderQueue();&lt;br /&gt;
&lt;br /&gt;
        for m,n in ipairs( renderingEntities ) do&lt;br /&gt;
            destroyElement( n );&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
);&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;/div&gt;</summary>
		<author><name>The GTA</name></author>
	</entry>
</feed>