Simple Shelves

Simple Shelves

238k Downloads

Unsafe cast crashes with Create

TropheusJ opened this issue ยท 6 comments

commented

This line is not safe and you should use instanceof instead. This causes a crash with Create: Fabricators-of-Create/Create#643

commented

Changes are live on CF.

commented

That is interesting. I'll make the change, but I'm curious as to why this crashes with Create, when nothing else seems to care.

commented

Change made in 1.17, 1.18, and master.

commented

Thanks! This crash happens because when schematics are loaded, they use structures to be placed into the fake schematic world. During structure loading, the block entity will be loaded and marked as dirty, where this cast happens, causing the crash.

commented
commented

Thanks! This crash happens because when schematics are loaded, they use structures to be placed into the fake schematic world. During structure loading, the block entity will be loaded and marked as dirty, where this cast happens, causing the crash.

Also, thanks for taking the time to narrow this down instead of just dumping it on me. It was really helpful and made this much quicker to fix.