Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[no sq] Fix some common SAO methods to not generate useless update packets #14419

Merged
merged 3 commits into from Mar 6, 2024

Conversation

sfan5
Copy link
Member

@sfan5 sfan5 commented Feb 29, 2024

fixes #9934

To do

This PR is Ready for Review.

How to test

There's test code in 9934 for set_object_properties but you have to make up your own for the rest.

Copy link
Member

@SmallJoker SmallJoker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testing whether the updates still work properly:

☑️ Object properties (devtest testtools:object_editor), binoculars (zoom_fov)
☑️ FoV player:set_fov(11, false, 1)
☑️ Formspec (inventory)
☑️ setTextureMod -> self.object:set_texture_mod("^[transform1")

Minor code style remarks. Feel free to fix if wanted.

src/server.cpp Outdated Show resolved Hide resolved
src/server/unit_sao.cpp Outdated Show resolved Hide resolved
@sfan5 sfan5 merged commit badd427 into minetest:master Mar 6, 2024
13 checks passed
@sfan5 sfan5 deleted the lessprop branch March 6, 2024 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

object:set_properties() should not generate packet if call did not change properties
2 participants