feat✨(rules): 添加 fakePlayerInteractLikeClient 规则以修复假人交互与客户端行为的不一致 #136
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
本规则将把假人的行为与正常客户端行为同步
详细解析
在假人的use命令中调用interact()和interactAt()函数并获取其ActionResult,但是部分实体(本次主要是盔甲架、船和矿车)的交互结果在客户端和服务器端存在不一致(客户端会判断并直接提前返回认为是成功的结果,但服务器端会进行详细的判断)。
说明
在未来遇到任何类似问题时,同样可以在本规则下添加代码。