Skip to content

Implement chunk save/load - #3

Open
harrynull wants to merge 23 commits into
Networkfrom
chunksave
Open

Implement chunk save/load#3
harrynull wants to merge 23 commits into
Networkfrom
chunksave

Conversation

@harrynull

Copy link
Copy Markdown
Member

Untested
Do not merge.

@harrynull
harrynull requested a review from DWVoid February 11, 2019 06:56
@DWVoid

DWVoid commented Feb 12, 2019

Copy link
Copy Markdown
Member

@harrynull only one question. Does it work properly or is this just a procedural practice?

@DWVoid

DWVoid commented Feb 12, 2019

Copy link
Copy Markdown
Member

And please consider async IO API as we are dealing with protentially tens of megabytes of data per second and it is not a good idea to jam the worker thread for this

@harrynull

Copy link
Copy Markdown
Member Author

It's totally untested as the game was crashing at the time I implemented it.
As for the Async IO, I thought that the workers for read-only tasks are automatically multithreaded...

@DWVoid

DWVoid commented Feb 12, 2019

Copy link
Copy Markdown
Member

@harrynull Yes, they are multi-threaded, but the implementation does not take system calls into account, so it will block the execution thread. There is no good cross-platform solution for this, so better do it explicitly.
I did notice currently the game might crash upon startup, but I just cannot reproduce it often enough with the debugger attached so that the problem can be located. Maybe it could just be a timing issue, or it might be a problem with the network 'GetChunk' protocol

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