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

Sync world #40

Merged
merged 3 commits into from
Jul 13, 2020
Merged

Sync world #40

merged 3 commits into from
Jul 13, 2020

Conversation

rom1504
Copy link
Member

@rom1504 rom1504 commented Jul 13, 2020

new one because I don't have push rights to #39

I tried to put it common the methods that could be, but still keeping a mirror in some case in sync for convenience

I explained the logic in the README

I think this is not fully satisfying but it's a good start.

Can you please review @Karang ?

@rom1504 rom1504 requested a review from Karang July 13, 2020 21:23
this.async = world
}

initialize (iniFunc, length, width, height = 256, iniPos = new Vec3(0, 0, 0)) {
Copy link
Member Author

Choose a reason for hiding this comment

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

I kept a duplicated of this because actually this is quite different : this is using the sync primitive and might fail (do nothing) if columns are not loaded.
Also it might be much faster than the async version

Copy link
Contributor

Choose a reason for hiding this comment

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

ok

@rom1504
Copy link
Member Author

rom1504 commented Jul 13, 2020

checks pass in flying squid using this PrismarineJS/flying-squid#415

@rom1504
Copy link
Member Author

rom1504 commented Jul 13, 2020

going to try using it in mineflayer

Copy link
Contributor

@Karang Karang left a comment

Choose a reason for hiding this comment

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

Lgtm

@rom1504
Copy link
Member Author

rom1504 commented Jul 13, 2020

PrismarineJS/mineflayer#1145 to try using it in mineflayer

@rom1504 rom1504 merged commit 80ad0fc into master Jul 13, 2020
@rom1504 rom1504 deleted the sync_world branch July 13, 2020 22:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants