-
Notifications
You must be signed in to change notification settings - Fork 0
Code refactoring, bug fixes #37
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
Merged
Merged
Changes from 16 commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
8455487
Add chunk exists method
CuddlyBunion341 f6897ba
Optimize chunk batch handler, improve mutabilitty
CuddlyBunion341 ae69f01
Update mut
CuddlyBunion341 ec9a13f
Reorganize imports
CuddlyBunion341 5519ea6
Do something (it crashes now)
CuddlyBunion341 3155cab
Fix linter
CuddlyBunion341 7070e2a
Fix specs
CuddlyBunion341 2e19adc
Fix
CuddlyBunion341 ffe3598
Fix linter, refactor terrain
CuddlyBunion341 5d8e2e7
Attempt fix renet channel config
CuddlyBunion341 217492f
Make code compile again
CuddlyBunion341 c87b752
Drop lib namespacec in subsystems
CuddlyBunion341 65a499d
Fix linter
CuddlyBunion341 a3d6c0c
Improve compile times :))
CuddlyBunion341 6e64d22
Refactor, remove wrapper method for chunk instantiation
CuddlyBunion341 a326efc
Fix terrain requests??
CuddlyBunion341 439aae8
Update CHANGELOG.md
CuddlyBunion341 275b17d
Increase server render distance
CuddlyBunion341 0003dc9
Increase client world size
CuddlyBunion341 67d4313
Update dyn linking doc / cfg
CuddlyBunion341 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -39,7 +39,7 @@ pub fn setup_coliders_system(mut commands: Commands) { | |
pub fn handle_collider_update_events_system( | ||
mut collider_grid_events: EventReader<collider_events::ColliderUpdateEvent>, | ||
mut query: Query<(&mut Transform, &collider_components::BlockCollider)>, | ||
mut chunk_manager: ResMut<terrain_resources::ChunkManager>, | ||
mut chunk_manager: ResMut<ChunkManager>, | ||
) { | ||
for event in collider_grid_events.read() { | ||
let event_position = Vec3::new( | ||
|
@@ -102,7 +102,7 @@ mod tests { | |
|
||
app.add_event::<collider_events::ColliderUpdateEvent>(); | ||
app.add_systems(Update, handle_collider_update_events_system); | ||
app.insert_resource(terrain_resources::ChunkManager::new()); | ||
app.insert_resource(ChunkManager::new()); | ||
|
||
app.world_mut().spawn(( | ||
Transform { | ||
|
@@ -123,17 +123,14 @@ mod tests { | |
)); | ||
|
||
let block = BlockId::Dirt; | ||
let mut resource = app | ||
.world_mut() | ||
.get_resource_mut::<terrain_resources::ChunkManager>() | ||
.unwrap(); | ||
let chunks = terrain_resources::ChunkManager::instantiate_chunks( | ||
let mut resource = app.world_mut().get_resource_mut::<ChunkManager>().unwrap(); | ||
let chunks = ChunkManager::instantiate_chunks( | ||
Vec3 { | ||
x: 0.0, | ||
y: 0.0, | ||
z: 0.0, | ||
}, | ||
1, | ||
Vec3::new(1.0, 1.0, 1.0), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure if I like the method "overload" with the integer param for the render distance more than this vector definition.. |
||
); | ||
resource.insert_chunks(chunks); | ||
resource.set_block( | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.