Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] CSL在24w21b中崩溃 #295

Closed
3 tasks done
TorkenLaber opened this issue May 23, 2024 · 4 comments · Fixed by #297
Closed
3 tasks done

[Bug] CSL在24w21b中崩溃 #295

TorkenLaber opened this issue May 23, 2024 · 4 comments · Fixed by #297
Labels

Comments

@TorkenLaber
Copy link

TorkenLaber commented May 23, 2024

描述问题

CSL在1.21快照版本24w21b中不可用,使用模组加入服务器或是进入一个世界会导致客户端崩溃
在上一个快照24w20a中仍然可用

复现步骤

1. 加入一个服务器或者一个单人世界存档
2. 游戏崩溃

崩溃报告查看地址

https://mclo.gs/zbBoVhP

CustomSkinLoader.log 查看地址

https://mclo.gs/FfDcpku

latest.log 查看地址

https://mclo.gs/aUUw7JD

[仅Forge用户] Forge Log 查看地址

No response

模组版本

CustomSkinLoader_Fabric-14.19.1

Minecraft游戏版本

24w21b

Minecraft启动器 名称 及 版本

PCL

模组加载器

Fabric

操作系统

Windows

在提交错误报告之前,有没有做到...

  • 先尝试搜索issues里面, 查看并确认打开或关闭的工单, 是否搜索不到

  • 确认你的模组版本是最新的开发版本,且文件下载正确,没有出现类似forge下载了fabric版的这类基础问题

  • 这个问题是在最新的mod版本触发(若不是最新的请先升级mod)

@paulzzh
Copy link

paulzzh commented Jun 14, 2024

从24w21a开始,net/minecraft/util/Identifier的Constructor变成private了,因此不能用new ResourceLocation(java.lang.String)

private static final ResourceLocation TEXTURE_ELYTRA = new ResourceLocation("textures/entity/elytra.png");

24w20a 24w21a 1.21

可以改用Identifier.tryParse(String id)(Lnet/minecraft/class_2960;method_12829(Ljava/lang/String;)Lnet/minecraft/class_2960;),大概能解决24w21a开始到1.21存在的这个崩溃问题
但是我不太会修。。本人水平低看不太懂这个项目

@paulzzh
Copy link

paulzzh commented Jun 15, 2024

通过一些Bytecode编辑确定只需把
private static final ResourceLocation TEXTURE_ELYTRA = new ResourceLocation("textures/entity/elytra.png");
改成
private static final ResourceLocation TEXTURE_ELYTRA = ResourceLocation.tryParse("textures/entity/elytra.png");
就能解决1.21上的NoSuchMethodError崩溃问题并正常工作
在有人来修之前,可以尝试自行用Recaf编辑<clinit>解决
image
因为LICENSE限制我无法分发修改后的文件

@Deniz1433
Copy link

Deniz1433 commented Jun 15, 2024

通过一些Bytecode编辑确定只需把 private static final ResourceLocation TEXTURE_ELYTRA = new ResourceLocation("textures/entity/elytra.png"); 改成 private static final ResourceLocation TEXTURE_ELYTRA = ResourceLocation.tryParse("textures/entity/elytra.png"); 就能解决1.21上的NoSuchMethodError崩溃问题并正常工作 在有人来修之前,可以尝试自行用Recaf编辑解决 image 因为LICENSE限制我无法分发修改后的文件

Thanks, this works. However, since we modify the bytecode of the class, I had to re-sign the jar file, or else I'd get a SHA-256 Digest Error

谢谢,这可行。但是,由于我们修改了类的字节码,我必须重新签名 jar 文件,否则我会收到 SHA-256 摘要错误

@yuji521
Copy link

yuji521 commented Jun 24, 2024

能不能手把手教我啊

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants