summaryrefslogtreecommitdiffstats
path: root/src/ChunkSender.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Prepare ChunkData for BlockState storage (#5105)Tiger Wang2021-03-051-2/+2
| | | | | | | | | | | | | | | | | | | | | | | * Rename ChunkData Creatable test * Add missing Y-check in RedstoneWireHandler * Remove ChunkDef.h dependency in Scoreboard * Prepare ChunkData for BlockState storage + Split chunk block, meta, block & sky light storage + Load the height map from disk - Reduce duplicated code in ChunkData - Remove saving MCSBiomes, there aren't any - Remove the allocation pool, ref #4315, #3864 * fixed build * fixed test * fixed the debug compile Co-authored-by: 12xx12 <44411062+12xx12@users.noreply.github.com>
* Clarify cClientHandle, cPlayer ownership semanticsTiger Wang2021-01-121-6/+4
| | | | | | | | + A cPlayer, once created, has a strong pointer to the cClientHandle. The player ticks the clienthandle. If he finds the handle destroyed, he destroys himself in turn. Nothing else can kill the player. * The client handle has a pointer to the player. Once a player is created, the client handle never outlasts the player, nor does it manage the player's lifetime. The pointer is always safe to use after FinishAuthenticate, which is also the point where cProtocol is put into the Game state that allows player manipulation. + Entities are once again never lost by constructing a chunk when they try to move into one that doesn't exist. * Fixed a forgotten Super invocation in cPlayer::OnRemoveFromWorld. * Fix SaveToDisk usage in destructor by only saving things cPlayer owns, instead of accessing cWorld.
* Reverse order of ChunkSender priorities (#4858)Tiger Wang2020-09-121-18/+15
| | | | | * Reduces confusion when using overloaded operator< and priority_queue Co-authored-by: peterbell10 <peterbell10@live.co.uk>
* ChunkDataSerializer: don't repeatedly mallocateTiger Wang2020-08-211-0/+4
| | | | + Store an instance of the class, the way it seems it is meant to be used.
* Precompile unordered_map/setTiger Wang2020-07-191-3/+0
| | | | | | + Add inclusions to Globals.h * Sort Globals.h - Remove sys/stat.h from Globals.h
* Send entities in cChunkSender (#4532)Mat2020-06-241-1/+1
| | | Confer issue #3696
* Using Super.Mattes D2020-04-161-1/+3
|
* Broadcast refactor (#4264)peterbell102018-07-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | * Move Broadcast functions from cChunkMap to cBroadcaster - Remove cBroadcastInterface in favour of cBroadcaster. - cChunk: Remove broadcast functions. * resurect broadcast interface * Absorb cBroadcaster into cWorld. Removes the need for forwarding the function calls. * Improve const-correctness * Use Int8 instead of char + Comment `ForClients` functions * Improve comments * Broadcaster: Rename ForClients functions
* cIsThread: Reset m_ShouldTerminate after the thread has stopped (#4258)peterbell102018-07-221-2/+0
| | | | | This allows threads to be restarted after stopping. Fixes #4257
* Removed UTF-8 BOM (#4033)Lukas Pioch2017-09-191-1/+1
|
* Implement protocol level chunk sparsing (#3864)peterbell102017-08-211-1/+1
|
* Remove double includes part 2 (#3890)peterbell102017-08-031-1/+0
|
* Clang 5.0 fixesLukas Pioch2017-05-211-1/+1
| | | | | - Added override keyword - Removed inherited member variables
* Bulk clearing of whitespaceLogicParrot2016-02-051-11/+11
|
* Unified the doxy-comment format.Mattes D2015-07-311-4/+4
|
* Fixed minor errors in Tycho's codeTiger Wang2015-06-221-7/+16
| | | | Everything should work now :)
* Reinstate "Chunk queue collapsing"Tiger Wang2015-06-101-51/+30
| | | | | This reinstates commit f36acb683594daff5af3971dcbe3c3a171628b78 and reverts commit adfbc42c021e1bcfcb355933c0fd784306ce0e18.
* Revert "Chunk queue collapsing"worktycho2015-06-071-30/+51
|
* Rewrote ChunkSending queue for significantly improved performancetycho2015-06-051-45/+26
|
* Moved Chunk Broadcasts over to the regular queuetycho2015-06-051-8/+6
|
* Made cLightingThread own its callbackstycho2015-05-301-22/+0
|
* CheckBasicStyle: checks spaces around * and &.Mattes D2015-05-091-1/+1
|
* Use 3 priorities.Howaner2014-10-231-1/+3
|
* Merge branch 'master' into ChunkLoaderHowaner2014-10-231-1/+1
|\ | | | | | | | | | | | | Conflicts: src/ChunkSender.cpp src/ClientHandle.cpp src/World.h
| * En masse NULL -> nullptr replaceTiger Wang2014-10-231-1/+1
| |
* | Use two lists and 2 chunk send prioritys.Howaner2014-10-211-11/+4
| |
* | Stream 4 chunks per tick. Added priority.Howaner2014-10-061-2/+16
|/
* remove y-coord from chunksLO1ZB2014-08-281-5/+2
|
* Style: Normalized to no spaces before closing parenthesis.madmaxoft2014-07-211-1/+1
|
* Fixed basic whitespace problems.madmaxoft2014-07-171-5/+5
| | | | Indenting by spaces and alignment by spaces, as well as trailing whitespace on non-empty lines.
* Fixed issue with types not being defined for an unused parameterTycho2014-05-181-1/+1
|
* Implemented Chunk Sparsing with segmentsTycho2014-04-261-0/+1
|
* Moved source to srcAlexander Harkness2013-11-241-0/+169