Jump to content

Access Transformers and Mod Compatibility


Reika

Recommended Posts

I used access transformers for the first time today to avoid the need to reflectively call or set fields or methods, to avoid the performance overhead of reflection (as the code is called very frequently).

This became a problem when changing an EntityLivingBase method (dropFewItems(ZI)V) from protected to public. When running the gradle script, I was spammed with errors as it tried to apply my changes, as the subclasses of EntityLivingBase all override that method and keep it as protected. Since a protected field cannot override a public one ("cannot reduce visibility" error), this is not unexpected, but poses a serious problem:

Even if I were to patch all of the vanilla entity classes to use the method as public, what happens with mods, who likely also override the method and keep it protected? Is there some handler in Forge to fix this and avoid a crash, or to change the visibility for all subclasses of a given class?

Link to comment
Share on other sites

You may have to use reflection as I think you hit a hard point of ATs.

I would expect that there is some way to mark a method to be modified in all subclasses; this system is old enough, and I am surely not the only one to need something like this.

 

I can use reflection, but I am concerned with the performance; this method (used by a mob harvesting machine) is going to be invoked on every mob that passes over it, a number which can be in the hundreds per second.

Link to comment
Share on other sites

Some modders have used a cached reflection field without suffering lag penalties. You should only have to do this once for any field in a class and cache the accessor.

Link to comment
Share on other sites

Some modders have used a cached reflection field without suffering lag penalties. You should only have to do this once for any field in a class and cache the accessor.

I already do that, but profiling has in the past indicated that method.invoke() and field.get() are still about 5-20x slower than direct access.

Link to comment
Share on other sites

One thing I sometimes use to access methods I cannot get to with reflection and am burdened by efficiency is code redundancy.

 

Basically partially recreating the method you need that is private or protected in your own class or subclass and use that one. Now I know that EntityLivingBase is quite complex but what you can do is create a new EntityLivingBase class, invoke it on load time to take from the original class the data it needs, build in a timer and at regular intervals adjust the data again. That way you can use that class and use it on maximum efficiency. The downside is that it produces duplicate code, reduces transparency, and depending on wether you need it or not, speed of updating it can weigh it down a bit, but still, it should be faster than reflection. And if you tweak it to fit your situation I believe you can just about do anything you need to do.

 

This isn't really a wrapper class as such since it creates its own methods but it can be used like that.

 

Just a note though, I wouldn't call this proper coding practice, but it works when it has to.

Link to comment
Share on other sites

One thing I sometimes use to access methods I cannot get to with reflection and am burdened by efficiency is code redundancy.

 

Basically partially recreating the method you need that is private or protected in your own class or subclass and use that one. Now I know that EntityLivingBase is quite complex but what you can do is create a new EntityLivingBase class, invoke it on load time to take from the original class the data it needs, build in a timer and at regular intervals adjust the data again. That way you can use that class and use it on maximum efficiency. The downside is that it produces duplicate code, reduces transparency, and depending on wether you need it or not, speed of updating it can weigh it down a bit, but still, it should be faster than reflection. And if you tweak it to fit your situation I believe you can just about do anything you need to do.

 

This isn't really a wrapper class as such since it creates its own methods but it can be used like that.

 

Just a note though, I wouldn't call this proper coding practice, but it works when it has to.

 

I am not trying to do this on custom entity classes. This is for vanilla and other modded mobs, like Creepers, Slime Beetles, and Wisps.

Link to comment
Share on other sites

Well to be honest, I have no idea what you are trying to do, apart from making another nice machine, but from your previous reply I deduce a mob grinder.

If this is the case, how about this:

 

List<Entity> entities = ParWorld.getEntitiesWithinAABBExcludingEntity(player, player.boundingBox.expand(5.0D, 5.0D, 5.0D));
	for(Entity Ent: entities)
	{
		Ent.setDead();
	}

 

If you call this every say, quarter or half a second you should easily get them all without needing to cast, although that function too takes some time. player.boundingbox can obviously be substituted by your blocks boundingbox or coords.

 

And if you're trying something more interesting, please enlighten us.

Link to comment
Share on other sites

Well to be honest, I have no idea what you are trying to do, apart from making another nice machine, but from your previous reply I deduce a mob grinder.

If this is the case, how about this:

 

List<Entity> entities = ParWorld.getEntitiesWithinAABBExcludingEntity(player, player.boundingBox.expand(5.0D, 5.0D, 5.0D));
	for(Entity Ent: entities)
	{
		Ent.setDead();
	}

 

If you call this every say, quarter or half a second you should easily get them all without needing to cast, although that function too takes some time. player.boundingbox can obviously be substituted by your blocks boundingbox or coords.

 

And if you're trying something more interesting, please enlighten us.

This is for the mob harvester. Depending on the enchantments and power supplied, it modifies the drop counts of the mobs it kills. I do that by watching the LivingDropsEvent:

@SubscribeEvent
public void enforceHarvesterLooting(LivingDropsEvent ev) {
	if (ev.source instanceof HarvesterDamage) {
		HarvesterDamage dmg = (HarvesterDamage)ev.source;
		int looting = dmg.getLootingLevel();
		EntityLivingBase e = ev.entityLiving;
		ArrayList<EntityItem> li = ev.drops;
		li.clear();
		e.captureDrops = true;
		try {
			ReikaObfuscationHelper.getMethod("dropFewItems").invoke(e, true, looting);
			ReikaObfuscationHelper.getMethod("dropEquipment").invoke(e, true, dmg.hasInfinity() ? 100 : looting*4);
			int rem = RotaryCraft.rand.nextInt(200) - looting*4;
			if (rem <= 5 || dmg.hasInfinity())
				ReikaObfuscationHelper.getMethod("dropRareDrop").invoke(e, 1);
		}
		catch (Exception ex) {
			RotaryCraft.logger.debug("Could not process harvester drops event!");
			if (RotaryCraft.logger.shouldDebug())
				ex.printStackTrace();
		}
		e.captureDrops = false;
	}
}

This is a mob whose type is only known at runtime and will be different for whatever the player decides to kill (including potentially exotic mobs like Withers and Minotaurs).

Link to comment
Share on other sites

Well, how about this then.

 

public final class KillMobs {

static ArrayList<EntityItem> ItemDropList;

public static void KillPresentMobs(World ParWorld, EntityPlayer player, int ItemDropAmount)
{
	List<Entity> entities = ParWorld.getEntitiesWithinAABBExcludingEntity(player, player.boundingBox.expand(5.0D, 5.0D, 5.0D));
	for(Entity Ent: entities)
	{	
		Ent.captureDrops = true;
		Ent.attackEntityFrom(DamageSource.fallingBlock, 100f);
		ItemDropList = Ent.capturedDrops;

		for(EntityItem DropItem: ItemDropList)
		{
			Ent.dropItem(DropItem.getEntityItem().itemID, ItemDropAmount);
		}

		ItemDropList.clear();
}}
}

 

It adds to the usual drops the amount you wish to add without reflection and displays the kill animation. It's not perfect yet, e.g. the arraylist should be replaced with something that can be modified more quickly, it doesn't modify the droprate(which you didn't ask) and it can't drop nothing(unless you destroy entities on the floor) but in general it works. And I don't think I need to tell you that the above is a static class so it is easy to test.

Link to comment
Share on other sites

Well, how about this then.

 

public final class KillMobs {

static ArrayList<EntityItem> ItemDropList;

public static void KillPresentMobs(World ParWorld, EntityPlayer player, int ItemDropAmount)
{
	List<Entity> entities = ParWorld.getEntitiesWithinAABBExcludingEntity(player, player.boundingBox.expand(5.0D, 5.0D, 5.0D));
	for(Entity Ent: entities)
	{	
		Ent.captureDrops = true;
		Ent.attackEntityFrom(DamageSource.fallingBlock, 100f);
		ItemDropList = Ent.capturedDrops;

		for(EntityItem DropItem: ItemDropList)
		{
			Ent.dropItem(DropItem.getEntityItem().itemID, ItemDropAmount);
		}

		ItemDropList.clear();
}}
}

 

It adds to the usual drops the amount you wish to add without reflection and displays the kill animation. It's not perfect yet, e.g. the arraylist should be replaced with something that can be modified more quickly, it doesn't modify the droprate(which you didn't ask) and it can't drop nothing(unless you destroy entities on the floor) but in general it works. And I don't think I need to tell you that the above is a static class so it is easy to test.

How does this allow me to control things like dropping armor and/or player-only drops?

Link to comment
Share on other sites

Excuse the fact that I am somewhat late but I needed to find the time to give the minecraft code a look.

In any case I wrote these few lines and they work splendidly, the only thing that they don't do is increase the chance for rare drops, which, unsurprisingly, are safely put away behind dumbly written methods and variables.

 

If you do want that, the best way I see is a wrapper class around EntityLivingBase, something which I believe you stated you didn't want so I avoided it.

The other possibility is creating a hashmap with the entities as keys and everytime an entity is encountered it doesn't know yet, spawn about a thousand of them, capture the drops, check which drop are below a certain amount and add those drops in a List<EntityItem> to the value in the hashmap.

A bit convoluted to say the least, although I don't think the mobs would show themselves so the temporary lag should be negligent.

 

Other than that, is just about regulates everything you could want.

 

public final class KillMobs {

public static void KillPresentMobs(World parWorld, EntityPlayer parPlayer, int parItemDropAmount, AxisAlignedBB parAxisAlignedBB, int parArmourDropChance)
{
	List<EntityItem> OldentityItems = parWorld.getEntitiesWithinAABBExcludingEntity(parPlayer, parAxisAlignedBB);

	Random rnd = new Random(); //Loops through current entities and selects the mobs.
	for(EntityLivingBase Ent: Iterables.filter(parWorld.getEntitiesWithinAABBExcludingEntity(parPlayer, parAxisAlignedBB), EntityLivingBase.class))
	{
		if(rnd.nextInt(100) <= parArmourDropChance)
		{	//drop armor if the conditions are right(random is below chance and selected slot has armor)
			Ent.entityDropItem(Ent.getCurrentItemOrArmor(rnd.nextInt(4)), 0);
		}
		//kills entities and captures their drops(it does not prevent them from falling)
		Ent.captureDrops = true;
		Ent.attackEntityFrom(DamageSource.causePlayerDamage(parPlayer), 100f);
		List<EntityItem> ItemDropList = Ent.capturedDrops;

		for(EntityItem DropItem: ItemDropList)
		{ //adds extras for the amount specified by parItemDropChance for each item dropped
			Ent.entityDropItem(new ItemStack(DropItem.getEntityItem().itemID, parItemDropAmount, DropItem.getEntityItem().getItemDamage()), 0);
		}
		ItemDropList.clear();
	}

	//Checks if mobdrops are on, if not it will delete the mobdrops.
	if(parItemDropAmount  == -1)
	{
		for(EntityItem OldItem: Iterables.filter(OldentityItems, EntityItem.class))
		{
			for(EntityItem EntItem: Iterables.filter(parWorld.getEntitiesWithinAABBExcludingEntity(parPlayer, parAxisAlignedBB), EntityItem.class))
			{
				if(EntItem == OldItem)
				{
					EntItem.setDead();
}}}}}}

 

And if you'll excuse me now, I need to go complain to my cat about how horrible the minecraft code is written.

Link to comment
Share on other sites

Excuse the fact that I am somewhat late but I needed to find the time to give the minecraft code a look.

In any case I wrote these few lines and they work splendidly, the only thing that they don't do is increase the chance for rare drops, which, unsurprisingly, are safely put away behind dumbly written methods and variables.

 

If you do want that, the best way I see is a wrapper class around EntityLivingBase, something which I believe you stated you didn't want so I avoided it.

The other possibility is creating a hashmap with the entities as keys and everytime an entity is encountered it doesn't know yet, spawn about a thousand of them, capture the drops, check which drop are below a certain amount and add those drops in a List<EntityItem> to the value in the hashmap.

A bit convoluted to say the least, although I don't think the mobs would show themselves so the temporary lag should be negligent.

 

Other than that, is just about regulates everything you could want.

 

public final class KillMobs {

public static void KillPresentMobs(World parWorld, EntityPlayer parPlayer, int parItemDropAmount, AxisAlignedBB parAxisAlignedBB, int parArmourDropChance)
{
	List<EntityItem> OldentityItems = parWorld.getEntitiesWithinAABBExcludingEntity(parPlayer, parAxisAlignedBB);

	Random rnd = new Random(); //Loops through current entities and selects the mobs.
	for(EntityLivingBase Ent: Iterables.filter(parWorld.getEntitiesWithinAABBExcludingEntity(parPlayer, parAxisAlignedBB), EntityLivingBase.class))
	{
		if(rnd.nextInt(100) <= parArmourDropChance)
		{	//drop armor if the conditions are right(random is below chance and selected slot has armor)
			Ent.entityDropItem(Ent.getCurrentItemOrArmor(rnd.nextInt(4)), 0);
		}
		//kills entities and captures their drops(it does not prevent them from falling)
		Ent.captureDrops = true;
		Ent.attackEntityFrom(DamageSource.causePlayerDamage(parPlayer), 100f);
		List<EntityItem> ItemDropList = Ent.capturedDrops;

		for(EntityItem DropItem: ItemDropList)
		{ //adds extras for the amount specified by parItemDropChance for each item dropped
			Ent.entityDropItem(new ItemStack(DropItem.getEntityItem().itemID, parItemDropAmount, DropItem.getEntityItem().getItemDamage()), 0);
		}
		ItemDropList.clear();
	}

	//Checks if mobdrops are on, if not it will delete the mobdrops.
	if(parItemDropAmount  == -1)
	{
		for(EntityItem OldItem: Iterables.filter(OldentityItems, EntityItem.class))
		{
			for(EntityItem EntItem: Iterables.filter(parWorld.getEntitiesWithinAABBExcludingEntity(parPlayer, parAxisAlignedBB), EntityItem.class))
			{
				if(EntItem == OldItem)
				{
					EntItem.setDead();
}}}}}}

 

And if you'll excuse me now, I need to go complain to my cat about how horrible the minecraft code is written.

 

While I greatly appreciate your efforts, this is a solution that, even if functional, will be nightmarish to debug and is likely slower than the reflection.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • My friends and I are trying to play with a custom modpack, it doesn't work, I was wondering if maybe anyone could help us because we've been trying to fix it and it doesn't work, the outversioned mod "NoOceans" doesn't seem to be a problem since it still doesn't work after removing it. Thank you in advance! (I would have pasted the pastebin, but the antispam feature blocked the post) ---- Minecraft Crash Report ---- // Don't do that. Time: 6/2/24 6:27 AM Description: Rendering overlay java.lang.NullPointerException: Rendering overlay     at cam72cam.immersiverailroading.registry.DefinitionManager.getDefinitions(DefinitionManager.java:368) ~[?:1.16.5-forge-1.10.0] {re:classloading}     at cam72cam.immersiverailroading.items.ItemRollingStock.getItemVariants(ItemRollingStock.java:51) ~[?:1.16.5-forge-1.10.0] {re:classloading}     at cam72cam.mod.render.ItemRender.lambda$register$5(ItemRender.java:125) ~[?:1.2.1] {re:classloading}     at cam72cam.mod.render.ItemRender$$Lambda$12333/1872169734.run(Unknown Source) ~[?:?] {}     at cam72cam.mod.event.ClientEvents$$Lambda$16688/835826095.accept(Unknown Source) ~[?:?] {}     at java.lang.Iterable.forEach(Iterable.java:75) ~[?:1.8.0_51] {}     at cam72cam.mod.event.Event.execute(Event.java:24) ~[?:1.2.1] {re:classloading}     at cam72cam.mod.event.ClientEvents.fireReload(ClientEvents.java:59) ~[?:1.2.1] {re:classloading}     at cam72cam.mod.ModCore$Internal$$Lambda$16443/1294650684.run(Unknown Source) ~[?:?] {}     at java.util.concurrent.CompletableFuture.uniRun(CompletableFuture.java:705) ~[?:1.8.0_51] {}     at java.util.concurrent.CompletableFuture$UniRun.tryFire(CompletableFuture.java:687) ~[?:1.8.0_51] {}     at java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474) ~[?:1.8.0_51] {}     at java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1624) ~[?:1.8.0_51] {}     at java.util.concurrent.CompletableFuture$AsyncRun.exec(CompletableFuture.java:1610) ~[?:1.8.0_51] {}     at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) ~[?:1.8.0_51] {}     at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056) ~[?:1.8.0_51] {}     at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1689) ~[?:1.8.0_51] {}     at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157) ~[?:1.8.0_51] {} A detailed walkthrough of the error, its code path and all known details is as follows: --------------------------------------------------------------------------------------- -- Head -- Thread: Render thread Stacktrace:     at cam72cam.immersiverailroading.registry.DefinitionManager.getDefinitions(DefinitionManager.java:368) ~[?:1.16.5-forge-1.10.0] {re:classloading}     at cam72cam.immersiverailroading.items.ItemRollingStock.getItemVariants(ItemRollingStock.java:51) ~[?:1.16.5-forge-1.10.0] {re:classloading}     at cam72cam.mod.render.ItemRender.lambda$register$5(ItemRender.java:125) ~[?:1.2.1] {re:classloading} -- Overlay render details -- Details:     Overlay name: net.minecraft.client.gui.ResourceLoadProgressGui Stacktrace:     at net.minecraft.client.renderer.GameRenderer.func_195458_a(GameRenderer.java:484) ~[?:?] {re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:classloading,pl:accesstransformer:B,pl:mixin:APP:rubidium.mixins.json:core.matrix.MixinGameRenderer,pl:mixin:APP:origins.mixins.json:GameRendererMixin,pl:mixin:APP:mixins.essential.json:client.renderer.MixinEntityRenderer,pl:mixin:APP:mixins.essential.json:client.renderer.MixinEntityRenderer_Zoom,pl:mixin:APP:cgm.mixins.json:client.GameRendererMixin,pl:mixin:APP:forge-mca.mixin.json:client.MixinGameRenderer,pl:mixin:APP:flywheel.mixins.json:StoreProjectionMatrixMixin,pl:mixin:APP:imm_ptl_mixins.json:client.block_manipulation.MixinGameRenderer_B,pl:mixin:APP:imm_ptl_mixins.json:client.debug.isometric.MixinGameRenderer_I,pl:mixin:APP:imm_ptl_mixins.json:client.render.MixinGameRenderer,pl:mixin:APP:securitycraft.mixins.json:camera.GameRendererMixin,pl:mixin:APP:mixins.essential.json:events.Mixin_GuiDrawScreenEvent_Priority,pl:mixin:A,pl:runtimedistcleaner:A}     at net.minecraft.client.Minecraft.func_195542_b(Minecraft.java:977) [?:?] {re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:classloading,pl:accesstransformer:B,pl:mixin:APP:rubidium.mixins.json:features.gui.fast_fps_pie.MixinMinecraftClient,pl:mixin:APP:rubidium.mixins.json:features.options.MixinMinecraftClient,pl:mixin:APP:architectury.mixins.json:MixinMinecraft,pl:mixin:APP:mixins.essential.json:client.Mixin_RunEssentialTasks,pl:mixin:APP:mixins.essential.json:client.MixinMinecraft,pl:mixin:APP:mixins.essential.json:client.gui.Mixin_FixKeybindUnpressedInEmoteWheel,pl:mixin:APP:mixins.essential.json:client.gui.Mixin_RecalculateMenuScale,pl:mixin:APP:mixins.essential.json:compatibility.forge.Mixin_FixInternalByteBufAccess,pl:mixin:APP:mixins.essential.json:compatibility.forge.Mixin_FixPrematureByteBufFree,pl:mixin:APP:mixins.essential.json:events.Mixin_RenderTickEvent,pl:mixin:APP:abnormals_core.mixins.json:client.MinecraftMixin,pl:mixin:APP:flywheel.mixins.json:ShaderCloseMixin,pl:mixin:APP:assets/botania/botania.mixins.json:AccessorMinecraft,pl:mixin:APP:imm_ptl_mixins.json:client.MixinMinecraftClient,pl:mixin:APP:imm_ptl_mixins.json:client.block_manipulation.MixinMinecraftClient_B,pl:mixin:APP:create.mixins.json:WindowResizeMixin,pl:mixin:APP:securitycraft.mixins.json:camera.MinecraftMixin,pl:mixin:A,pl:runtimedistcleaner:A}     at net.minecraft.client.Minecraft.func_99999_d(Minecraft.java:607) [?:?] {re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:mixin,pl:accesstransformer:B,pl:runtimedistcleaner:A,re:classloading,pl:accesstransformer:B,pl:mixin:APP:rubidium.mixins.json:features.gui.fast_fps_pie.MixinMinecraftClient,pl:mixin:APP:rubidium.mixins.json:features.options.MixinMinecraftClient,pl:mixin:APP:architectury.mixins.json:MixinMinecraft,pl:mixin:APP:mixins.essential.json:client.Mixin_RunEssentialTasks,pl:mixin:APP:mixins.essential.json:client.MixinMinecraft,pl:mixin:APP:mixins.essential.json:client.gui.Mixin_FixKeybindUnpressedInEmoteWheel,pl:mixin:APP:mixins.essential.json:client.gui.Mixin_RecalculateMenuScale,pl:mixin:APP:mixins.essential.json:compatibility.forge.Mixin_FixInternalByteBufAccess,pl:mixin:APP:mixins.essential.json:compatibility.forge.Mixin_FixPrematureByteBufFree,pl:mixin:APP:mixins.essential.json:events.Mixin_RenderTickEvent,pl:mixin:APP:abnormals_core.mixins.json:client.MinecraftMixin,pl:mixin:APP:flywheel.mixins.json:ShaderCloseMixin,pl:mixin:APP:assets/botania/botania.mixins.json:AccessorMinecraft,pl:mixin:APP:imm_ptl_mixins.json:client.MixinMinecraftClient,pl:mixin:APP:imm_ptl_mixins.json:client.block_manipulation.MixinMinecraftClient_B,pl:mixin:APP:create.mixins.json:WindowResizeMixin,pl:mixin:APP:securitycraft.mixins.json:camera.MinecraftMixin,pl:mixin:A,pl:runtimedistcleaner:A}     at net.minecraft.client.main.Main.main(Main.java:184) [?:?] {re:classloading,pl:runtimedistcleaner:A}     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_51] {}     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_51] {}     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_51] {}     at java.lang.reflect.Method.invoke(Method.java:497) ~[?:1.8.0_51] {}     at net.minecraftforge.fml.loading.FMLClientLaunchProvider.lambda$launchService$0(FMLClientLaunchProvider.java:37) [forge-1.16.5-36.2.41.jar:36.2] {}     at net.minecraftforge.fml.loading.FMLClientLaunchProvider$$Lambda$532/1700344615.call(Unknown Source) [forge-1.16.5-36.2.41.jar:36.2] {}     at cpw.mods.modlauncher.LaunchServiceHandlerDecorator.launch(LaunchServiceHandlerDecorator.java:37) [modlauncher-8.1.3.jar:?] {}     at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:54) [modlauncher-8.1.3.jar:?] {}     at cpw.mods.modlauncher.LaunchServiceHandler.launch(LaunchServiceHandler.java:72) [modlauncher-8.1.3.jar:?] {}     at cpw.mods.modlauncher.Launcher.run(Launcher.java:82) [modlauncher-8.1.3.jar:?] {re:classloading}     at cpw.mods.modlauncher.Launcher.main(Launcher.java:66) [modlauncher-8.1.3.jar:?] {re:classloading} -- System Details -- Details:     Minecraft Version: 1.16.5     Minecraft Version ID: 1.16.5     Operating System: Windows 10 (amd64) version 10.0     Java Version: 1.8.0_51, Oracle Corporation     Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation     Memory: 1668661432 bytes (1591 MB) / 3586654208 bytes (3420 MB) up to 3817865216 bytes (3641 MB)     CPUs: 12     JVM Flags: 4 total; -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump -Xss1M -Xmx4096m -Xms256m     ModLauncher: 8.1.3+8.1.3+main-8.1.x.c94d18ec     ModLauncher launch target: fmlclient     ModLauncher naming: srg     ModLauncher services:          /mixin-0.8.4.jar mixin PLUGINSERVICE          /eventbus-4.0.0.jar eventbus PLUGINSERVICE          /forge-1.16.5-36.2.41.jar object_holder_definalize PLUGINSERVICE          /forge-1.16.5-36.2.41.jar runtime_enum_extender PLUGINSERVICE          /accesstransformers-3.0.1.jar accesstransformer PLUGINSERVICE          /forge-1.16.5-36.2.41.jar capability_inject_definalize PLUGINSERVICE          /forge-1.16.5-36.2.41.jar runtimedistcleaner PLUGINSERVICE          /mixin-0.8.4.jar mixin TRANSFORMATIONSERVICE          /essential_1-3-0-6_forge_1-16-5.jar essential-loader TRANSFORMATIONSERVICE          /forge-1.16.5-36.2.41.jar fml TRANSFORMATIONSERVICE      FML: 36.2     Forge: net.minecraftforge:36.2.41     FML Language Providers:          [email protected]         minecraft@1         [email protected]     Mod List:          immersivecooking-1.2.0.jar                        |Immersive Cooking             |immersivecooking              |1.2.0               |CREATE_REG|Manifest: NOSIGNATURE         UnionLib-1.16.5-3.3.7.jar                         |UnionLib                      |unionlib                      |3.3.7               |CREATE_REG|Manifest: NOSIGNATURE         mcw-windows-2.2.1-mc1.16.5forge.jar               |Macaw's Windows               |mcwwindows                    |2.2.1               |CREATE_REG|Manifest: NOSIGNATURE         stalwart-dungeons-1.16.5-1.1.7.jar                |Stalwart Dungeons             |stalwart_dungeons             |1.1.7               |CREATE_REG|Manifest: NOSIGNATURE         macawsbridgesbyg-1.16.5-2.8.jar                   |Macaw's Bridges - BYG         |macawsbridgesbyg              |1.16.5-2.8          |ERROR     |Manifest: NOSIGNATURE         rubidium-mc1.16.5-0.2.13.jar                      |Rubidium                      |rubidium                      |0.2.13              |CREATE_REG|Manifest: NOSIGNATURE         NyfsQuiver-0.4.0.jar                              |Nyf's Quiver                  |nyfsquiver                    |0.4.0               |CREATE_REG|Manifest: NOSIGNATURE         macawsroofsbyg-1.16.5-1.7.jar                     |Macaw's Roofs - BYG           |macawsroofsbyg                |1.16.5-1.7          |CREATE_REG|Manifest: NOSIGNATURE         mcwfurnituresbop-1.16.5-1.3.jar                   |Macaw's Furnitures - BOP      |mcwfurnituresbop              |1.16.5-1.3          |CREATE_REG|Manifest: NOSIGNATURE         EnhancedVisuals_v1.3.32_mc1.16.5.jar              |EnhancedVisuals               |enhancedvisuals               |1.3.0               |CREATE_REG|Manifest: NOSIGNATURE         CTM-MC1.16.1-1.1.2.6.jar                          |ConnectedTexturesMod          |ctm                           |MC1.16.1-1.1.2.6    |CREATE_REG|Manifest: NOSIGNATURE         citadel-1.8.1-1.16.5.jar                          |Citadel                       |citadel                       |1.8.1               |CREATE_REG|Manifest: NOSIGNATURE         alexsmobs-1.12.1.jar                              |Alex's Mobs                   |alexsmobs                     |1.12.1              |CREATE_REG|Manifest: NOSIGNATURE         lootintegrations-1.2.jar                          |Lootintegrations mod          |lootintegrations              |1.2                 |CREATE_REG|Manifest: NOSIGNATURE         Horror_elements_mod_1.5.5_1.16.5.jar              |Horror Element Mod            |horror_element_mod            |1.5.5               |CREATE_REG|Manifest: NOSIGNATURE         additional-guns-0.8.0-1.16.5.jar                  |Additional Guns               |additionalguns                |0.8.0               |CREATE_REG|Manifest: NOSIGNATURE         upgradednetherite_items-1.16.5-1.1.0.2-release.jar|Upgraded Netherite : Items    |upgradednetherite_items       |1.16.5-1.1.0.2-relea|CREATE_REG|Manifest: NOSIGNATURE         MutantBeasts-1.16.4-1.1.3.jar                     |Mutant Beasts                 |mutantbeasts                  |1.16.4-1.1.3        |CREATE_REG|Manifest: d9:be:bd:b6:9a:e4:14:aa:05:67:fb:84:06:77:a0:c5:10:ec:27:15:1b:d6:c0:88:49:9a:ef:26:77:61:0b:5e         macawsbridgesbop-1.16.5-1.8.jar                   |Macaw's Bridges - Biome O' Ple|macawsbridgesbop              |1.16.5-1.8          |ERROR     |Manifest: NOSIGNATURE         sophisticatedbackpacks-1.16.5-3.15.20.755.jar     |Sophisticated Backpacks       |sophisticatedbackpacks        |1.16.5-3.15.20.755  |CREATE_REG|Manifest: NOSIGNATURE         mcw-doors-1.1.0forge-mc1.16.5.jar                 |Macaw's Doors                 |mcwdoors                      |1.1.0               |CREATE_REG|Manifest: NOSIGNATURE         carryon-1.16.5-1.15.5.22.jar                      |Carry On                      |carryon                       |1.15.5.22           |CREATE_REG|Manifest: NOSIGNATURE         macawsroofsbop-1.16.5-1.8.jar                     |Macaw's Roofs - BOP           |macawsroofsbop                |1.16.5-1.8          |CREATE_REG|Manifest: NOSIGNATURE         supplementaries-1.16.5-0.18.5.jar                 |Supplementaries               |supplementaries               |0.18.3              |CREATE_REG|Manifest: NOSIGNATURE         upgradednetherite-1.16.5-2.1.0.1-release.jar      |Upgraded Netherite            |upgradednetherite             |1.16.5-2.1.0.1-relea|CREATE_REG|Manifest: NOSIGNATURE         structure_gel-1.16.5-1.7.8.jar                    |Structure Gel API             |structure_gel                 |1.7.8               |CREATE_REG|Manifest: NOSIGNATURE         corpse-1.16.5-1.0.6.jar                           |Corpse                        |corpse                        |1.16.5-1.0.6        |CREATE_REG|Manifest: NOSIGNATURE         decocraft-3.0.0.3-beta.jar                        |Decocraft                     |decocraft                     |3.0.0.3-beta        |CREATE_REG|Manifest: NOSIGNATURE         mcw-bridges-2.1.0-mc1.16.5forge.jar               |Macaw's Bridges               |mcwbridges                    |2.1.0               |CREATE_REG|Manifest: NOSIGNATURE         FarmersDelight-1.16.5-0.6.0.jar                   |Farmer's Delight              |farmersdelight                |1.16.5-0.6.0        |CREATE_REG|Manifest: NOSIGNATURE         BiomesOPlenty-1.16.5-13.1.0.480-universal.jar     |Biomes O' Plenty              |biomesoplenty                 |1.16.5-13.1.0.480   |CREATE_REG|Manifest: NOSIGNATURE         mcw-trapdoors-1.1.3-mc1.16.5forge.jar             |Macaw's Trapdoors             |mcwtrpdoors                   |1.1.3               |CREATE_REG|Manifest: NOSIGNATURE         mcw-fences-1.1.1-mc1.16.5forge.jar                |Macaw's Fences and Walls      |mcwfences                     |1.1.1               |CREATE_REG|Manifest: NOSIGNATURE         Wild West Dimension 3.1.jar                       |Ace 51's Wild West Dimension  |ace_s_wild_west_dimension     |1.0.0               |CREATE_REG|Manifest: NOSIGNATURE         Botania-1.16.5-420.2.jar                          |Botania                       |botania                       |1.16.5-420.2        |CREATE_REG|Manifest: NOSIGNATURE         born_in_chaos_1.16_1.3.jar                        |Born in Chaos                 |born_in_chaos_v1              |1.0.0               |CREATE_REG|Manifest: NOSIGNATURE         dungeons_enhanced-1.16.5-1.8.1.jar                |Dungeons Enhanced             |dungeons_enhanced             |1.8.1               |CREATE_REG|Manifest: NOSIGNATURE         CNB-1.16.3_5-1.2.11.jar                           |Creatures and Beasts          |cnb                           |1.2.11              |CREATE_REG|Manifest: NOSIGNATURE         curios-forge-1.16.5-4.1.0.0.jar                   |Curios API                    |curios                        |1.16.5-4.1.0.0      |CREATE_REG|Manifest: NOSIGNATURE         Patchouli-1.16.4-53.3.jar                         |Patchouli                     |patchouli                     |1.16.4-53.3         |CREATE_REG|Manifest: NOSIGNATURE         Origins-1.16.5-0.7.3.9-forge.jar                  |Origins                       |origins                       |0.7.3.9             |CREATE_REG|Manifest: NOSIGNATURE         bettervillage-forge-1.16.5-3.2.0.jar              |Better village                |bettervillage                 |3.1.0               |CREATE_REG|Manifest: NOSIGNATURE         Survive-1.16.5-3.4.8.jar                          |Survive                       |survive                       |1.16.5-3.4.8        |CREATE_REG|Manifest: NOSIGNATURE         obfuscate-0.6.3-1.16.5.jar                        |Obfuscate                     |obfuscate                     |0.6.3               |CREATE_REG|Manifest: NOSIGNATURE         CustomNPCs-1.16.5.20220515.jar                    |Custom NPCs                   |customnpcs                    |1.16.5.20220515     |CREATE_REG|Manifest: NOSIGNATURE         SpartanWeaponry-1.16.5-2.2.0.jar                  |Spartan Weaponry              |spartanweaponry               |2.2.0               |CREATE_REG|Manifest: NOSIGNATURE         mcw-roofs-2.3.0-mc1.16.5forge.jar                 |Macaw's Roofs                 |mcwroofs                      |2.3.0               |CREATE_REG|Manifest: NOSIGNATURE         architectury-1.32.68.jar                          |Architectury                  |architectury                  |1.32.68             |CREATE_REG|Manifest: NOSIGNATURE         ImmersiveRailroading-1.16.5-forge-1.10.0.jar      |Immersive Railroading         |immersiverailroading          |1.16.5-forge-1.10.0 |CREATE_REG|Manifest: NOSIGNATURE         TrackAPI-1.16.4-forge-1.2.1.jar                   |TrackAPI                      |trackapi                      |1.2                 |CREATE_REG|Manifest: NOSIGNATURE         mcw-furniture-3.2.2-mc1.16.5forge.jar             |Macaw's Furniture             |mcwfurnitures                 |3.2.2               |CREATE_REG|Manifest: NOSIGNATURE         cloth-config-4.17.101-forge.jar                   |Cloth Config v4 API           |cloth-config                  |4.17.101            |CREATE_REG|Manifest: NOSIGNATURE         wings-2.1.0-1.16.5.jar                            |Wings                         |wings                         |2.1.0               |CREATE_REG|Manifest: NOSIGNATURE         DynamicTrees-1.16.5-0.10.0-Beta27.jar             |Dynamic Trees                 |dynamictrees                  |1.16.5-0.10.0-Beta27|CREATE_REG|Manifest: NOSIGNATURE         PlayerRevive_v2.0.0-pre04_mc1.16.5.jar            |PlayerRevive                  |playerrevive                  |2.0.0               |CREATE_REG|Manifest: NOSIGNATURE         mcw-lights-1.0.6b-mc1.16.5forge.jar               |Macaw's Lights and Lamps      |mcwlights                     |1.0.6               |CREATE_REG|Manifest: NOSIGNATURE         Essential (forge_1.16.5).jar                      |Essential                     |essential                     |1.3.0.6+g4dc55a95bd |CREATE_REG|Manifest: NOSIGNATURE         noocean-1.0.jar                                   |No Oceans                     |noocean                       |1.0                 |CREATE_REG|Manifest: NOSIGNATURE         archaicguns-1.0-1.16.5.jar                        |Archaic Guns                  |archaicguns                   |1.0                 |CREATE_REG|Manifest: NOSIGNATURE         mowziesmobs-1.5.27.jar                            |Mowzie's Mobs                 |mowziesmobs                   |1.5.27              |CREATE_REG|Manifest: NOSIGNATURE         geckolib-forge-1.16.5-3.0.106.jar                 |GeckoLib                      |geckolib3                     |3.0.106             |CREATE_REG|Manifest: NOSIGNATURE         cgm-1.2.6-1.16.5.jar                              |MrCrayfish's Gun Mod          |cgm                           |1.2.6               |CREATE_REG|Manifest: NOSIGNATURE         minecraft-comes-alive-7.3.23+1.16.5-universal.jar |Minecraft Comes Alive         |mca                           |7.3.23+1.16.5       |CREATE_REG|Manifest: NOSIGNATURE         Shrines-1.16.5-2.3.0.jar                          |Shrines                       |shrines                       |1.16.5-2.3.0        |CREATE_REG|Manifest: NOSIGNATURE         jei-1.16.5-7.7.1.110.jar                          |Just Enough Items             |jei                           |7.7.1.110           |CREATE_REG|Manifest: NOSIGNATURE         abnormals_core-1.16.5-3.3.1.jar                   |Abnormals Core                |abnormals_core                |3.3.1               |CREATE_REG|Manifest: NOSIGNATURE         libraryferret-forge-1.16.5-4.0.0.jar              |Library ferret                |libraryferret                 |4.0.0               |CREATE_REG|Manifest: NOSIGNATURE         caelus-forge-1.16.5-2.1.3.2.jar                   |Caelus API                    |caelus                        |1.16.5-2.1.3.2      |CREATE_REG|Manifest: NOSIGNATURE         UNDEADv.1.7.b.release+Biome.jar                   |UNDEAD                        |undead                        |2.2.2               |CREATE_REG|Manifest: NOSIGNATURE         Waystones_1.16.5-7.6.0.jar                        |Waystones                     |waystones                     |7.6.0               |CREATE_REG|Manifest: NOSIGNATURE         epicfight-16.6.5.jar                              |Epic Fight                    |epicfight                     |16.6.5              |CREATE_REG|Manifest: NOSIGNATURE         mcw-paintings-1.0.5-1.16.5forge.jar               |Macaw's Paintings             |mcwpaintings                  |1.0.5               |CREATE_REG|Manifest: NOSIGNATURE         comforts-forge-1.16.5-4.0.1.2.jar                 |Comforts                      |comforts                      |1.16.5-4.0.1.1      |CREATE_REG|Manifest: NOSIGNATURE         TravelersBackpack-1.16.5-5.4.51.jar               |Traveler's Backpack           |travelersbackpack             |5.4.51              |CREATE_REG|Manifest: NOSIGNATURE         iceandfire-2.1.12-1.16.5-patch-1.jar              |Ice and Fire                  |iceandfire                    |2.1.12-1.16.5-patch-|CREATE_REG|Manifest: NOSIGNATURE         walljump-forge-1.16.4-1.3.7.jar                   |Wall-Jump!                    |walljump                      |1.16.4-1.3.7        |CREATE_REG|Manifest: NOSIGNATURE         immersive-portals-0.17-mc1.16.5-forge.jar         |Immersive Portals             |immersive_portals             |0.14                |CREATE_REG|Manifest: NOSIGNATURE         forge-1.16.5-36.2.41-universal.jar                |Forge                         |forge                         |36.2.41             |CREATE_REG|Manifest: 22:af:21:d8:19:82:7f:93:94:fe:2b:ac:b7:e4:41:57:68:39:87:b1:a7:5c:c6:44:f9:25:74:21:14:f5:0d:90         culturaldelights-1.16.5-0.9.2.jar                 |Cultural Delights             |culturaldelights              |0.9.2               |CREATE_REG|Manifest: NOSIGNATURE         mcw-paths-1.0.5-1.16.5forge.jar                   |Macaw's Paths and Pavings     |mcwpaths                      |1.0.5               |CREATE_REG|Manifest: NOSIGNATURE         DynamicSurroundings-1.16.5-4.0.5.0.jar            |§3Dynamic Surroundings        |dsurround                     |4.0.5.0             |CREATE_REG|Manifest: NOSIGNATURE         selene-1.16.5-1.9.0.jar                           |Selene                        |selene                        |1.16.5-1.0          |CREATE_REG|Manifest: NOSIGNATURE         antiqueatlas-6.2.4-forge-mc1.16.5.jar             |Antique Atlas                 |antiqueatlas                  |6.2.4-forge-mc1.16.5|CREATE_REG|Manifest: NOSIGNATURE         UniversalModCore-1.16.5-forge-1.2.1.jar           |Universal Mod Core            |universalmodcore              |1.2.1               |CREATE_REG|Manifest: NOSIGNATURE         DungeonsArise-1.16.5-2.1.49-beta.jar              |When Dungeons Arise           |dungeons_arise                |2.1.49              |CREATE_REG|Manifest: NOSIGNATURE         forge-1.16.5-36.2.41-client.jar                   |Minecraft                     |minecraft                     |1.16.5              |CREATE_REG|Manifest: NOSIGNATURE         mcwfencesbop-1.16.5-1.3.jar                       |Macaw's Fences - BOP          |mcwfencesbop                  |1.16.5-1.3          |CREATE_REG|Manifest: NOSIGNATURE         Capsule-1.16.5-5.0.94.jar                         |Capsule                       |capsule                       |1.16.5-5.0.94       |CREATE_REG|Manifest: NOSIGNATURE         CreativeCore_v2.2.1_mc1.16.5.jar                  |CreativeCore                  |creativecore                  |2.0.0               |CREATE_REG|Manifest: NOSIGNATURE         astikorcarts-1.16.4-1.1.0.jar                     |AstikorCarts                  |astikorcarts                  |1.1.0               |CREATE_REG|Manifest: NOSIGNATURE         flywheel-1.16-0.2.5.jar                           |Flywheel                      |flywheel                      |1.16-0.2.5          |CREATE_REG|Manifest: NOSIGNATURE         create-mc1.16.5_v0.3.2g.jar                       |Create                        |create                        |v0.3.2g             |CREATE_REG|Manifest: NOSIGNATURE         SpartanShields-1.16.5-2.1.2.jar                   |Spartan Shields               |spartanshields                |2.1.2               |CREATE_REG|Manifest: NOSIGNATURE         rats-7.2.0-1.16.5.jar                             |Rats                          |rats                          |7.2.0               |CREATE_REG|Manifest: NOSIGNATURE         dragonseeker-1.1.jar                              |Dragonseeker                  |dragonseeker                  |1.1                 |CREATE_REG|Manifest: NOSIGNATURE         autumnity-1.16.5-2.1.2.jar                        |Autumnity                     |autumnity                     |2.1.2               |CREATE_REG|Manifest: NOSIGNATURE         [1.16.5] SecurityCraft v1.9.0.1.jar               |SecurityCraft                 |securitycraft                 |v1.9.0.1            |CREATE_REG|Manifest: NOSIGNATURE         upgradedcore-1.16.5-1.1.0.3-release.jar           |Upgraded Core                 |upgradedcore                  |1.16.5-1.1.0.3-relea|CREATE_REG|Manifest: NOSIGNATURE         nzgExpansion-1.3.2-1.16.5.jar                     |NineZero's Gun Expansion      |nzgexpansion                  |1.3.2               |CREATE_REG|Manifest: NOSIGNATURE         Vampirism-1.16.5-1.9.10.jar                       |Vampirism                     |vampirism                     |1.9.10              |CREATE_REG|Manifest: NOSIGNATURE         VampiresNeedUmbrellas-1.16.5-1.1.5.jar            |Vampires Need Umbrellas       |vampiresneedumbrellas         |1.1.5               |CREATE_REG|Manifest: NOSIGNATURE         GodlyVampirism-1.16.5-1.0.2.jar                   |Godly Vampirism               |godly-vampirism               |1.0.2               |CREATE_REG|Manifest: NOSIGNATURE         Werewolves-1.16.5-1.1.0.3.jar                     |Werewolves                    |werewolves                    |1.1.0.3             |CREATE_REG|Manifest: NOSIGNATURE         lootr-1.16.5-0.1.12.43.jar                        |Lootr                         |lootr                         |0.1.12.43           |CREATE_REG|Manifest: NOSIGNATURE         Chisel-MC1.16.5-2.0.1-alpha.4.jar                 |Chisel                        |chisel                        |MC1.16.5-2.0.1-alpha|CREATE_REG|Manifest: NOSIGNATURE         upgradednetherite_ultimate-1.16.5-1.1.0.3-release.|Upgraded Netherite : Ultimerit|upgradednetherite_ultimate    |1.16.5-1.1.0.3-relea|CREATE_REG|Manifest: NOSIGNATURE         largemeals-1.16.5-2.2.jar                         |Large Meals                   |largemeals                    |1.16.5-2.2          |CREATE_REG|Manifest: NOSIGNATURE         byg-1.3.5.jar                                     |Oh The Biomes You'll Go       |byg                           |1.3.4               |CREATE_REG|Manifest: NOSIGNATURE         mcwfencesbyg-1.16.5-1.2.jar                       |Macaw's Fences - BYG          |mcwfencesbyg                  |1.16.5-1.2          |CREATE_REG|Manifest: NOSIGNATURE         Aquaculture-1.16.5-2.1.23.jar                     |Aquaculture 2                 |aquaculture                   |1.16.5-2.1.23       |CREATE_REG|Manifest: NOSIGNATURE         mcwfurnituresbyg-1.16.5-1.2.jar                   |Macaw's Furnitures - BYG      |mcwfurnituresbyg              |1.16.5-1.2          |CREATE_REG|Manifest: NOSIGNATURE         createaddition-1.16.5-20220129a.jar               |Create Crafts & Additions     |createaddition                |1.16.5-20220129a    |CREATE_REG|Manifest: NOSIGNATURE     Crash Report UUID: 1c499886-aba0-4f79-8dfb-5087b1e4af58     Launched Version: forge-36.2.41     Backend library: LWJGL version 3.2.2 build 10     Backend API: Radeon RX 580 Series GL version 4.6.0 Compatibility Profile Context 24.1.1.231127, ATI Technologies Inc.     GL Caps: Using framebuffer using OpenGL 3.0     Using VBOs: Yes     Is Modded: Definitely; Client brand changed to 'forge'     Type: Client (map_client.txt)     Graphics mode: fancy     Resource Packs:      Current Language: English (US)     CPU: 12x Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz
    • Add crash-reports with sites like https://paste.ee/   Start with removing ReSkin
    • I have no idea - do other modpacks work?
    • I have a server that I own with my friend (we use a third-party server site like Akliz), and we play Cottage Witch on there, specifically version 1.16.6 as that's the newest version our server provider can support. We're having a great time, but we noticed a big issue: we can't make wool out of string. We have SO much string, but wool is trickier for us to get. Normally, on every other version of Minecraft we've played, we've been able to make wool from string. I even play a slightly older version of the modpack (1.16.0), and I'm able to make wool out of string and even string out of wool. However, in 1.16.6, we can't. I've looked through all of the mods I could think of (anything with tweak or craft in the name as well as the Create mod, JEI, farmers' mods, etc.), but I can't find anything that might be overriding the recipe. Is there something I'm missing? The recipe won't work with four pieces or even nine pieces of string. I've looked online for any sort of suggestions from someone else who might have a similar issue, but their issues were other mods that aren't in the Cottage Witch modpack. Any suggestions would be appreciated! Thank you. I just want to make the game enjoyable and relaxing for my friend, and this string/wool issue is getting really annoying in our adventures. I appreciate any tips or ideas. Thanks in advanced!
    • Solved! Here is my solution: Create my own RenderType.CompositeRenderType that does what i need it to. First you will need to add an access transfomer in your build.gradle (https://docs.minecraftforge.net/en/latest/advanced/accesstransformers/) and paste this there  public net.minecraft.client.renderer.RenderType$CompositeRenderType public net.minecraft.client.renderer.RenderType m_173209_(Ljava/lang/String;Lcom/mojang/blaze3d/vertex/VertexFormat;Lcom/mojang/blaze3d/vertex/VertexFormat$Mode;ILnet/minecraft/client/renderer/RenderType$CompositeState;)Lnet/minecraft/client/renderer/RenderType$CompositeRenderType; # create public net.minecraft.client.renderer.RenderStateShard$LineStateShard after that you just create your own CompositeRenderType, here is the code for mine  public static RenderType.CompositeRenderType myOutline = RenderType.CompositeRenderType.create("myLines", DefaultVertexFormat.POSITION_COLOR_NORMAL, VertexFormat.Mode.LINES, 256, RenderType.CompositeState.builder().setShaderState(new RenderStateShard.ShaderStateShard(GameRenderer::getRendertypeLinesShader)).setLineState(new RenderStateShard.LineStateShard(OptionalDouble.empty())).setLayeringState(new RenderStateShard.LayeringStateShard("view_offset_z_layering", () -> { PoseStack $$0 = RenderSystem.getModelViewStack(); $$0.pushPose(); $$0.scale(0.99975586F, 0.99975586F, 0.99975586F); RenderSystem.applyModelViewMatrix(); }, () -> { PoseStack $$0 = RenderSystem.getModelViewStack(); $$0.popPose(); RenderSystem.applyModelViewMatrix(); })).setTransparencyState(new RenderStateShard.TransparencyStateShard("translucent_transparency", () -> { RenderSystem.enableBlend(); RenderSystem.blendFuncSeparate(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA, GlStateManager.SourceFactor.ONE, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA); RenderSystem.disableDepthTest(); }, () -> { RenderSystem.disableBlend(); RenderSystem.defaultBlendFunc(); RenderSystem.enableDepthTest(); })).setOutputState(new RenderStateShard.OutputStateShard("item_entity_target", () -> { if (Minecraft.useShaderTransparency()) { Minecraft.getInstance().levelRenderer.getItemEntityTarget().bindWrite(false); } }, () -> { if (Minecraft.useShaderTransparency()) { Minecraft.getInstance().getMainRenderTarget().bindWrite(false); } })).setDepthTestState(new RenderStateShard.DepthTestStateShard("always", 519)).setWriteMaskState(new RenderStateShard.WriteMaskStateShard(true, false)).setCullState(new RenderStateShard.CullStateShard(false)).createCompositeState(false)); I hope this helped 🙏 if you have any questions dm me on discord .ducklett
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.