LegacyScriptEngine
LegacyScriptEngine copied to clipboard
[Bug]: some parameters of onBlockExplode are incorrect
Describe the bug
- onBlockExplode 爆炸来源的方块对象 source.type 每次打印都是"minecraft:air" 空气
- 补充:isDestroy一直是true 就算tnt在水里爆炸也是true
To Reproduce
在 onBlockExplode 监听事件中打印 source.type 每次都是空气
Expected behavior
正常工作
Screenshots
No response
Platform
Win10
BDS Version
1.21.60
LeviLamina Version
1.1.2
LegacyScriptEngine Version
0.10.8
Additional context
No response
大概是由于方块在调用Explosion::explode()之前就已经被删除了,我想想有没有什么更好点位
补充:isDestroy一直是true 就算tnt在水里爆炸也是true,isFire没测过不知道
实际测试 onBlockExplode 这个监听事件连苦力怕爆炸也可以拦截,苦力怕不是实体吗?
实际测试 onEntityExplode 中的 isDestroy 也一直都是 true 即使在水中引爆苦力怕
实际测试 onBlockExplode 和 onEntityExplode 都能同时触发并拦截方块和实体爆炸,比如、苦力怕爆炸会在 onBlockExplode 中触发并成功拦截,tnt爆炸会在 onEntityExplode 中触发并拦截,相似的示例还有:末地水晶、tnt矿车等等