Fix Spectating Part Entity (MC-46486) (#8206)

This commit is contained in:
uSkizzik authored and GitHub committed 2021-11-25 12:17:15 -08:00
1 parent 34ec627457
commit 8a552136a2
1 file changed
+8
@@ -150,6 +150,14 @@
}
public boolean m_143432_() {
@@ -1265,6 +_,7 @@
public void m_9213_(Entity p_9214_) {
Entity entity = this.m_8954_();
this.f_8926_ = (Entity)(p_9214_ == null ? this : p_9214_);
+ while (this.f_8926_ instanceof net.minecraftforge.entity.PartEntity<?> partEntity) this.f_8926_ = partEntity.getParent(); // FORGE: fix MC-46486
if (entity != this.f_8926_) {
this.f_8906_.m_141995_(new ClientboundSetCameraPacket(this.f_8926_));
this.m_6021_(this.f_8926_.m_20185_(), this.f_8926_.m_20186_(), this.f_8926_.m_20189_());
@@ -1294,7 +_,11 @@
@Nullable