Freezing Scarpet
And the client
This commit is contained in:
10 files changed
+87
-5
No files matched your search
@@ -1,5 +1,6 @@
|
||||
package carpet.mixins;
|
||||
|
||||
import carpet.helpers.TickSpeed;
|
||||
import carpet.utils.CarpetProfiler;
|
||||
import net.minecraft.server.function.CommandFunctionManager;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
@@ -12,9 +13,11 @@ public class CommandFunctionManager_tickMixin
|
||||
{
|
||||
CarpetProfiler.ProfilerToken currentSection;
|
||||
|
||||
@Inject(method = "tick", at = @At("HEAD"))
|
||||
@Inject(method = "tick", at = @At("HEAD"), cancellable = true)
|
||||
private void beforeDatapacks(CallbackInfo ci)
|
||||
{
|
||||
if (!TickSpeed.process_entities && TickSpeed.deepFreeze) ci.cancel();
|
||||
else
|
||||
currentSection = CarpetProfiler.start_section(null, "Datapacks", CarpetProfiler.TYPE.GENERAL);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user