Skip to content
This repository has been archived by the owner on Jun 19, 2021. It is now read-only.

Commit

Permalink
Merge pull request #186 from jonas-schievink/master
Browse files Browse the repository at this point in the history
load more chunks again
  • Loading branch information
jonas-schievink authored Aug 5, 2016
2 parents 42972c6 + c73df96 commit 53a1347
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion client/src/world_manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ impl WorldManager {
AxialVector::new(CHUNK_SIZE as i32 / 2, CHUNK_SIZE as i32 / 2);
let player_center = player_chunk * CHUNK_SIZE as i32 +
AxialVector::new(CHUNK_SIZE as i32 / 2, CHUNK_SIZE as i32 / 2);
(chunk_center - player_center).to_real().distance(Vector2f::zero()) < load_distance
(chunk_center - player_center).to_real().distance(Vector2f::zero()) <
load_distance * CHUNK_SIZE as f32
};

// Load new range
Expand Down

0 comments on commit 53a1347

Please sign in to comment.