itsapi / pycraft

A Minecraft-inspired game for the terminal
GNU General Public License v2.0
197 stars 21 forks source link

Unloading Chunks #125

Closed olls closed 7 years ago

olls commented 8 years ago

We need to implement unloading chunks in the server when no player in using those chunks (maybe with a larger threshold than the player needs). This will reduce memory usage when exploring large amounts (minimally), and allow mobs to despawn.

geraintwhite commented 8 years ago

We could store each player's extended edges on the server, then use those to figure out which chunks can be unloaded.

olls commented 8 years ago

Yes, and use the get_chunks and unload_chunks to update them

On Thu, 29 Sep 2016 at 11:53 Geraint White notifications@github.com wrote:

We could store each player's extended edges on the server, then use those to figure out which chunks can be unloaded.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/itsapi/pycraft/issues/125#issuecomment-250433795, or mute the thread https://github.com/notifications/unsubscribe-auth/AA4WyMdlNLBbUCzKM1GnDBBdrHAKl9S6ks5qu5ixgaJpZM4J_GfM .

geraintwhite commented 8 years ago

There's a little problem with respawning in my current implementation. Which is now fixed 5ebe4af13055aad293f0c71ff77140db4503618b