<patchGroups>
	<minecraft>
		<class id="net.minecraft.world.World">
			<clone to="updateEntities_withProfiling">updateEntities</clone>
			<insertCodeBefore
				code="if (nallar.tickprofiler.minecraft.TickProfiler.shouldProfile(this)) { updateEntities_withProfiling(); return; }">
				updateEntities
			</insertCodeBefore>
			<replaceMethodCall method="^method:ITickable/update^"
							   code="nallar.tickprofiler.minecraft.profiling.EntityTickProfiler.INSTANCE.profileTickable($0);">
				updateEntities_withProfiling
			</replaceMethodCall>
			<replaceMethodCall method="^method:World/updateEntity^"
							   code="nallar.tickprofiler.minecraft.profiling.EntityTickProfiler.INSTANCE.profileEntity(this, $1);">
				updateEntities_withProfiling
			</replaceMethodCall>
		</class>
		<class id="net.minecraft.util.MessageSerializer">
			<replaceMethodCall method="^method:Packet/writePacketData^"
							   code="$_ = $0.^method:Packet/writePacketData^($1); nallar.tickprofiler.minecraft.profiling.PacketProfiler.record($0, $1);">
				encode
			</replaceMethodCall>
			<insertCodeBefore code="nallar.tickprofiler.minecraft.TickProfiler.handlePacket($1);">
				scheduleOutboundPacket
			</insertCodeBefore>
		</class>
	</minecraft>
</patchGroups>

<patchGroups>
	<minecraft>
		<class id="net.minecraft.world.World">
			<clone to="updateEntities_withProfiling">updateEntities</clone>
			<insertCodeBefore
				code="if (nallar.tickprofiler.minecraft.TickProfiler.shouldProfile(this)) { updateEntities_withProfiling(); return; }">
				updateEntities
			</insertCodeBefore>
			<replaceMethodCall method="^method:ITickable/update^"
							   code="nallar.tickprofiler.minecraft.profiling.EntityTickProfiler.INSTANCE.profileTickable($0);">
				updateEntities_withProfiling
			</replaceMethodCall>
			<replaceMethodCall method="^method:World/updateEntity^"
							   code="nallar.tickprofiler.minecraft.profiling.EntityTickProfiler.INSTANCE.profileEntity(this, $1);">
				updateEntities_withProfiling
			</replaceMethodCall>
		</class>
		<!-- TODO: update packet profiling for 1.8.9
		<class id="net.minecraft.util.MessageSerializer">
			<replaceMethodCall method="^method:Packet/writePacketData^"
							   code="$_ = $0.^method:Packet/writePacketData^($1); nallar.tickprofiler.minecraft.profiling.PacketProfiler.record($0, $1);">
				encode
			</replaceMethodCall>
			<insertCodeBefore code="nallar.tickprofiler.minecraft.TickProfiler.handlePacket($1);">
				scheduleOutboundPacket
			</insertCodeBefore>
		</class>
		-->
	</minecraft>
</patchGroups>

Disable packet profiling for now - hook needs updated for 1.8.9
Disable packet profiling for now - hook needs updated for 1.8.9
