<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
		<id>https://zedwork.co.uk/w/index.php?action=history&amp;feed=atom&amp;title=Optimizing_command_block_systems_using_functions</id>
		<title>Optimizing command block systems using functions - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://zedwork.co.uk/w/index.php?action=history&amp;feed=atom&amp;title=Optimizing_command_block_systems_using_functions"/>
		<link rel="alternate" type="text/html" href="https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;action=history"/>
		<updated>2026-04-18T05:16:08Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.26.3</generator>

	<entry>
		<id>https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;diff=3809&amp;oldid=prev</id>
		<title>Mellori: Category</title>
		<link rel="alternate" type="text/html" href="https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;diff=3809&amp;oldid=prev"/>
				<updated>2020-10-11T12:44:20Z</updated>
		
		<summary type="html">&lt;p&gt;Category&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;' lang='en-GB'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 12:44, 11 October 2020&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l17&quot; &gt;Line 17:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 17:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More to follow...&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More to follow...&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[category:&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;tutorial&lt;/del&gt;]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[category:&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Minecraft_Tutorial&lt;/ins&gt;]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Mellori</name></author>	</entry>

	<entry>
		<id>https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;diff=1802&amp;oldid=prev</id>
		<title>Mellori: Added category</title>
		<link rel="alternate" type="text/html" href="https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;diff=1802&amp;oldid=prev"/>
				<updated>2018-10-03T10:17:13Z</updated>
		
		<summary type="html">&lt;p&gt;Added category&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;' lang='en-GB'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 10:17, 3 October 2018&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l16&quot; &gt;Line 16:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 16:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More to follow...&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More to follow...&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[category:tutorial]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Mellori</name></author>	</entry>

	<entry>
		<id>https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;diff=848&amp;oldid=prev</id>
		<title>Dax23333: Created page with &quot;'''This tutorial covers ways to use functions to make command block systems more efficent in cpu usage''' Every single command block running in the world will create load, and...&quot;</title>
		<link rel="alternate" type="text/html" href="https://zedwork.co.uk/w/index.php?title=Optimizing_command_block_systems_using_functions&amp;diff=848&amp;oldid=prev"/>
				<updated>2017-08-16T17:22:13Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;&amp;#039;&amp;#039;&amp;#039;This tutorial covers ways to use functions to make command block systems more efficent in cpu usage&amp;#039;&amp;#039;&amp;#039; Every single command block running in the world will create load, and...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;'''This tutorial covers ways to use functions to make command block systems more efficent in cpu usage'''&lt;br /&gt;
Every single command block running in the world will create load, and with many commands running at once can cause constant lag and excessive cpu usage. While most command block minigames will run fine without these methods, very complex ones may need them to run well.&lt;br /&gt;
&lt;br /&gt;
==Causes of command block load==&lt;br /&gt;
Command block chains need to figure out which command block should be executed next, so that the chain happens in the right order. Functions don't need to do this and so have an immediate benifit even if the commands are the same. Entity selectors have to check the list of entities on the server to find the ones that match. More entities to check increases this (already significant) load. Using the @s selector means a list of one entity (the executer) is checked rather than a long one of other entities. Location checks in selectors also give notable load, with large ones being worse. Every command run will have some load, regardless of what it is. This gives us some goals to aim for when optimizing command block systems.&lt;br /&gt;
*Use functions rather than command block chains&lt;br /&gt;
*Reduce the number of selectors, replacing with @s where possible&lt;br /&gt;
*Reduce number of commands running every tick&lt;br /&gt;
*Reduce number of location checks in selectors&lt;br /&gt;
&lt;br /&gt;
==Functions==&lt;br /&gt;
A function is a plain text file with commands in it, one per line, that are executed top to bottom. It has the file extension .mcfunction and needs to use UTF-8 encoding. Notepad++ is a free editor that can do this. For the dungeon dash abilities, the functions are placed in data/functions/dungeondash/abilities. dungeondash is the namespace, abilities is the sub folder containing the function files themselves. &lt;br /&gt;
&lt;br /&gt;
==The Tutorial==&lt;br /&gt;
In order to lower the cpu usage of our commands we will primarily use functions and the @s selector.&lt;br /&gt;
&lt;br /&gt;
More to follow...&lt;/div&gt;</summary>
		<author><name>Dax23333</name></author>	</entry>

	</feed>