Skip to content

Commit

Permalink
Added NotShadowCaster to grids
Browse files Browse the repository at this point in the history
  • Loading branch information
romenjelly committed Jan 27, 2024
1 parent 7f8eaf2 commit 7abf315
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "bevy_debug_grid"
description = "A bevy plugin for creating grids, for debugging purposes"
version = "0.4.0"
version = "0.4.1"
repository = "https://github.com/romenjelly/bevy_debug_grid"
edition = "2021"
license = "MIT OR Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ Adding a `RenderLayers` component to an entity with a `Grid` will ensure that al

| Bevy Version | Plugin Version |
|:------------:|:--------------:|
| `0.12` | `0.3.0-0.4.0` |
| `0.12` | `0.3.0-0.4.1` |
| `0.11` | `0.2.0-0.2.1` |
| `0.10` | `0.1.0-0.1.1` |

Expand Down
7 changes: 7 additions & 0 deletions src/systems.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
use bevy::prelude::*;
use bevy::render::render_resource::PrimitiveTopology;
use bevy::render::view::RenderLayers;
use bevy::pbr::NotShadowCaster;
use bevy::utils::HashMap;

use crate::*;
Expand Down Expand Up @@ -83,6 +84,7 @@ pub fn main_grid_mesher_untracked(
let mut commands = children.spawn((
GridChild,
meshes.add(mesh),
NotShadowCaster,
TransformBundle::default(),
VisibilityBundle::default(),
simple_materials.add(SimpleLineMaterial::new(
Expand Down Expand Up @@ -123,6 +125,7 @@ pub fn main_grid_mesher_tracked(
let mut commands = children.spawn((
GridChild,
meshes.add(mesh),
NotShadowCaster,
TransformBundle::default(),
VisibilityBundle::default(),
clipped_materials.add(ClippedLineMaterial::new(
Expand All @@ -144,6 +147,7 @@ pub fn main_grid_mesher_tracked(
let mut commands = children.spawn((
GridChild,
meshes.add(axis_mesh),
NotShadowCaster,
GlobalTransform::default(),
VisibilityBundle::default(),
clipped_materials.add(ClippedLineMaterial::new(
Expand Down Expand Up @@ -198,6 +202,7 @@ pub fn sub_grid_mesher(
let mut child_commands = children.spawn((
SubGridChild,
meshes.add(mesh),
NotShadowCaster,
TransformBundle::from_transform(Transform::from_translation(
alignment.shift_vec3(-Vec3::Y * SUB_GRID_VERTICAL_OFFSET),
)),
Expand Down Expand Up @@ -253,6 +258,7 @@ pub fn grid_axis_mesher(
let mut commands = children.spawn((
GridAxisChild,
meshes.add(mesh),
NotShadowCaster,
TransformBundle::default(),
VisibilityBundle::default(),
simple_materials.add(SimpleLineMaterial::new(
Expand All @@ -278,6 +284,7 @@ pub fn grid_axis_mesher(
let mut commands = children.spawn((
GridAxisChild,
meshes.add(mesh),
NotShadowCaster,
TransformBundle::default(),
VisibilityBundle::default(),
simple_materials.add(SimpleLineMaterial::new(
Expand Down

0 comments on commit 7abf315

Please sign in to comment.