<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.crumbledworld.com/index.php?action=history&amp;feed=atom&amp;title=ComUnit</id>
	<title>ComUnit - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.crumbledworld.com/index.php?action=history&amp;feed=atom&amp;title=ComUnit"/>
	<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=ComUnit&amp;action=history"/>
	<updated>2026-04-21T23:08:42Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.41.4</generator>
	<entry>
		<id>https://wiki.crumbledworld.com/index.php?title=ComUnit&amp;diff=104&amp;oldid=prev</id>
		<title>Anders: Created page with &quot;{{:ComUnitExampleCode}}   ==Functions== {| class=&quot;wikitable&quot; !|return !|function !|description |- | |setPos(Vec3 position) | |- | |setScriptGroup(ScriptGroup group) | |- | |setName(string name) | |- | |setCanReceiveTargeted(bool canRecive) | |- | |ComUnit:setCanReceiveBroadcast(bool canRecive)|set...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.crumbledworld.com/index.php?title=ComUnit&amp;diff=104&amp;oldid=prev"/>
		<updated>2025-07-05T14:21:00Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{:ComUnitExampleCode}}   ==Functions== {| class=&amp;quot;wikitable&amp;quot; !|return !|function !|description |- | |&lt;a href=&quot;/index.php?title=ComUnit:setPos(Vec3_position)&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;ComUnit:setPos(Vec3 position) (page does not exist)&quot;&gt;setPos&lt;/a&gt;(&lt;a href=&quot;/index.php/Vec3&quot; title=&quot;Vec3&quot;&gt;Vec3&lt;/a&gt; position) | |- | |&lt;a href=&quot;/index.php?title=ComUnit:setScriptGroup(ScriptGroup_group)&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;ComUnit:setScriptGroup(ScriptGroup group) (page does not exist)&quot;&gt;setScriptGroup&lt;/a&gt;(&lt;a href=&quot;/index.php?title=ScriptGroup&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;ScriptGroup (page does not exist)&quot;&gt;ScriptGroup&lt;/a&gt; group) | |- | |&lt;a href=&quot;/index.php?title=ComUnit:setName(string_name)&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;ComUnit:setName(string name) (page does not exist)&quot;&gt;setName&lt;/a&gt;(&lt;a href=&quot;/index.php/String&quot; title=&quot;String&quot;&gt;string&lt;/a&gt; name) | |- | |&lt;a href=&quot;/index.php?title=ComUnit:setCanReceiveTargeted(bool_canRecive)&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;ComUnit:setCanReceiveTargeted(bool canRecive) (page does not exist)&quot;&gt;setCanReceiveTargeted&lt;/a&gt;(bool canRecive) | |- | |ComUnit:setCanReceiveBroadcast(bool canRecive)|set...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{:ComUnitExampleCode}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
!|return&lt;br /&gt;
!|function&lt;br /&gt;
!|description&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:setPos(Vec3 position)|setPos]]([[Vec3]] position)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:setScriptGroup(ScriptGroup group)|setScriptGroup]]([[ScriptGroup]] group)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:setName(string name)|setName]]([[string]] name)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:setCanReceiveTargeted(bool canRecive)|setCanReceiveTargeted]](bool canRecive)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:setCanReceiveBroadcast(bool canRecive)|setCanReceiveBroadcast]](bool canRecive)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendTo(int targetIndex, string message, object parameters)|sendTo]](int targetIndex, [[string]] message, object parameters)&lt;br /&gt;
|sends a message to another ComUnit with id targetIndex. the message will be delivered next frame. RTT=2frames.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendTo(string targetName, string message, object parameters)|sendTo]]([[string]] targetName, [[string]] message, object parameters)&lt;br /&gt;
|sends a message to another ComUnit with name targetName. the message will be delivered next frame. RTT=2frames.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendNetworkSync(string message, string parameter)|sendNetworkSync]]([[string]] message, [[string]] parameter)&lt;br /&gt;
|sends a message to to all other connected clients. to sync this script. May not reach reciver&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendNetworkSyncTo(string networkName, string message, string parameter)|sendNetworkSyncTo]]([[string]] message, [[string]] parameter)&lt;br /&gt;
|sends a message to to all connected clients to the script using networkName. May not reach reciver&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendNetworkSyncSafe(string message, string parameter)|sendNetworkSyncSafe]]([[string]] message, [[string]] parameter)&lt;br /&gt;
|sends a message to to all other connected clients. to sync this script. It is guaranteed to be delivered if networkName is connected to active script&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendNetworkSyncSafeTo(string networkName, string message, string parameter)|sendNetworkSyncSafeTo]]([[string]] message, [[string]] parameter)&lt;br /&gt;
|sends a message to to all other connected clients to the script using networkName. It is guaranteed to be delivered if networkName is connected to active script&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:sendToSpoof(int fromIndex, int targetIndex, string message, object parameters)|sendToSpoof]](int fromIndex, int targetIndex, [[string]] message, object parameters)&lt;br /&gt;
|This allow you to send a message from one script pretending to be another.&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:broadCast(Vec3 position, float range, string message, object parameters)|broadCast]]([[Vec3]] position, float range, [[string]] message, object parameters)&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:broadCastSpoof(int fromIndex, Vec3 position, float range, string message, object parameters)|broadCastSpoof]](int fromIndex, [[Vec3]] position, float range, [[string]] message, object parameters)&lt;br /&gt;
|This allow you to broadcast a message from one script pretending to be another.&lt;br /&gt;
|-&lt;br /&gt;
|[[Vec3]]&lt;br /&gt;
|[[ComUnit:getPos()|getPos]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|int&lt;br /&gt;
|[[ComUnit:getIndex()|getIndex]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[ScriptGroup]]&lt;br /&gt;
|[[ComUnit:getGroup()|getGroup]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|[[Billboard]]&lt;br /&gt;
|[[ComUnit:getBillboard()|getBillboard]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|bool&lt;br /&gt;
|[[ComUnit:hasMessage()|hasMessage]]()&lt;br /&gt;
|returns true if any message is in queue.&lt;br /&gt;
|-&lt;br /&gt;
|{frame=number, fromIndex=number, message=string, parameter=object}&lt;br /&gt;
|[[ComUnit:popMessage()|popMessage]]()&lt;br /&gt;
|return a table&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
|[[ComUnit:clearMessages()|clearMessages]]()&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>Anders</name></author>
	</entry>
</feed>