mirror of
https://github.com/FyroxEngine/Fyrox.git
synced 2026-10-12 02:02:20 +00:00
fixed grid blending issues
This commit is contained in:
@@ -170,6 +170,7 @@ impl CameraController {
|
||||
)
|
||||
.build(graph);
|
||||
|
||||
graph.link_nodes(grid, camera);
|
||||
graph.link_nodes(pivot, root);
|
||||
|
||||
Self {
|
||||
|
||||
@@ -203,7 +203,6 @@ impl GameScene {
|
||||
.build()])
|
||||
.with_render_path(RenderPath::Forward)
|
||||
.build(&mut scene.graph);
|
||||
scene.graph.link_nodes(grid, editor_objects_root);
|
||||
|
||||
let (settings_sender, settings_receiver) = mpsc::channel();
|
||||
settings.subscribers.push(settings_sender);
|
||||
@@ -968,6 +967,11 @@ impl SceneController for GameScene {
|
||||
|
||||
grid_material.set_property("scale", scale);
|
||||
|
||||
let grid_offset = projection.z_far() - projection.z_near();
|
||||
scene.graph[self.grid]
|
||||
.local_transform_mut()
|
||||
.set_position(Vector3::new(0.0, 0.0, grid_offset));
|
||||
|
||||
self.camera_controller.update(
|
||||
&mut scene.graph,
|
||||
settings,
|
||||
|
||||
Reference in New Issue
Block a user