Comments (10)
Would this be the correct way to handle these methods? 2xsaiko@8c2f076
from mcmultipart.
No. markAndNotifyBlock needs to call all of them, and notifyBlockUpdate only the ones traditionally handled by IWorldEventListeners. getActualWorld() will not backtrack!
from mcmultipart.
Huh? World's markAndNotifyBlock works the same way with it calling notifyBlockUpdate, I copied that if block straight from World. Other than that, vanilla World.markAndNotifyBlock specifically only handles flags 1 and 16 itself. I did notice that the condition for flag 16 was inverted though, that needs to be fixed
Only IWorldEventListener I could find that did anything with the flags was RenderGlobal, and that only handles flag 8, which isn't handled at all in MCMP's code. Should I handle every flag in markAndNotifyBlock then?
from mcmultipart.
Huh? World's markAndNotifyBlock works the same way with it calling notifyBlockUpdate, I copied that if block straight from World. Other than that, vanilla World.markAndNotifyBlock specifically only handles flags 1 and 16 itself. I did notice that the condition for flag 16 was inverted though, that needs to be fixed
Yes, but the ActualWorld's markAndNotifyBlock will call the ActualWorld's notifyBlockUpdate, which won't then handle the multipart stuff.
from mcmultipart.
But I'm also calling the wrapped world's notifyBlockUpdate under the same conditions that the actual world's notifyBlockUpdate will get called in markAndNotifyBlock, so the multipart stuff is already handled. Right? I feel like I'm missing something here, haha
from mcmultipart.
notifyBlockUpdate(pos, iblockstate, newState, flags);
okay, i'm stupid
HOWEVER! This will cause getActualWorld().notifyBlockUpdate() to be called twice. Not as bad, but could still impact performance a little
from mcmultipart.
HOWEVER! This will cause getActualWorld().notifyBlockUpdate() to be called twice. Not as bad, but could still impact performance a little
do not forget
from mcmultipart.
yeah, the last commit should fix that.
from mcmultipart.
Aha! Seems like it. Thanks!
from mcmultipart.
I'll push a release before going to bed :)
from mcmultipart.
Related Issues (20)
- breakBlock call resets RS nodes HOT 3
- New API Questions HOT 3
- Multipart rotation and recoloring hooks HOT 5
- TileMultipartContainer.Ticking doesn't call update() on client side. HOT 12
- Crash with RefinedStorge and Mekanism HOT 4
- 1.12.2 Can't place mekanism cables Chisel&Bits HOT 3
- Ladder support HOT 1
- Clicking with multiparts HOT 2
- isLadder doesn't nullcheck getCollisionBoundingBox
- TileEntity#Invalidate is not fired on Client Side.
- IMultipart#getDrops does not wrap the world HOT 1
- Crash after player broke a multipart with generous amounts of Charset wires HOT 1
- [1.10.2] Crash when breaking Mekanism cables HOT 5
- Refined Storage Cables HOT 5
- java.lang.NullPointerException: Ticking block entity with Mekanism/MCMultipart (Universal Cable) HOT 3
- Crash w/ Structure Blocks
- MCMP3 API Specification Discussion HOT 1
- I WILL PAY FOR 1.16 SUPPORT HOT 2
- Bug: Incompability with CTM .mcmeta
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mcmultipart.