
Crash When Player is Touching Another Player's Fence
Darkosto opened this issue ยท 7 comments
Hello!
It looks like when I use recurrent complex to generate structures uses fences I placed, other players will load up their own world and crash when touching the fence.
Log: https://gist.github.com/rgtexa/6a89909ec89a49744e5786271a994d5c
MC: 1.10.2
Forge: 2221
OMPD: 3.0.0-16
OMLib: 3.0.0-45
Thank you for checking this out!
Darkosto
And another here: http://pastebin.com/yYdyrpYt
This is caused here https://github.com/OpenModularTurretsTeam/OMLib/blob/1.10.2/src/main/java/omtteam/omlib/util/PlayerUtil.java#L78, from near as I can tell because the client tries to get a list of opped players. This can be fixed by changing the client side config to false as shown below to short circuit the conditional, also this will be a multiplayer issue as it happens whenever someone touches a fence that isn't the owner.
B:"Enable OPs to access all owned blocks."=false
Does this still happen with the latest omlib builds from curseforge?
One thing to note: if you use any outside tools to place these blocks, they probably will not be placed correctly. You have to set the owner on them on creating them, since they have tile entities attached to them. If you do not add an owner, it will be null and people will crash on that. So ask the mod authors of the mods you use to copy these to structures, that they should copy the tile entities contents, too. And set the variables the copied tile entities has to the newly created ones.
It would much simpler to have a default behavior when 'owner' isn't defined. Or even drop the block on placement is owner wasn't defined.
You can expect every single block placement tool to special case your mod unless you go through a standard 'Forge based' behavior.