Skip to content

Commit 58fe794

Browse files
committed
Implement feedback
1 parent 0941d20 commit 58fe794

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

crates/bevy_hierarchy/src/child_builder.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ impl Command for RemoveChildren {
198198

199199
/// Command that removes the parent of an entity, and removes that entity from the parent's [`Children`].
200200
pub struct RemoveParent {
201-
/// `Entity` which parent must be removed.
201+
/// `Entity` whose parent must be removed.
202202
pub child: Entity,
203203
}
204204

@@ -222,7 +222,7 @@ impl<'w, 's, 'a> ChildBuilder<'w, 's, 'a> {
222222
e
223223
}
224224

225-
/// Spawns an [`Entity`] with no components and inserts it into the children defined by the [`ChildBuilder`] which adds the [`Parent`] component to it.
225+
/// Spawns an [`Entity`] with no components and inserts it into the children defined by the [`ChildBuilder`] whose adds the [`Parent`] component to it.
226226
pub fn spawn_empty(&mut self) -> EntityCommands<'w, 's, '_> {
227227
let e = self.commands.spawn_empty();
228228
self.push_children.children.push(e.id());
@@ -360,7 +360,7 @@ impl<'w> WorldChildBuilder<'w> {
360360
self.world.entity_mut(entity)
361361
}
362362

363-
/// Spawns an [`Entity`] with no components and inserts it into the children defined by the [`WorldChildBuilder`] which adds the [`Parent`] component to it.
363+
/// Spawns an [`Entity`] with no components and inserts it into the children defined by the [`WorldChildBuilder`] whose adds the [`Parent`] component to it.
364364
pub fn spawn_empty(&mut self) -> EntityMut<'_> {
365365
let entity = self.world.spawn(Parent(self.parent)).id();
366366
push_child_unchecked(self.world, self.parent, entity);

crates/bevy_transform/src/commands.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use crate::{GlobalTransform, Transform};
1111
/// Command similar to [`AddChild`], but updating the child transform to keep
1212
/// it at the same [`GlobalTransform`].
1313
///
14-
/// You most likely want to use [`BuildChildrenTransformExt::set_parent_keep_global_transform`]
14+
/// You most likely want to use [`BuildChildrenTransformExt::set_parent_in_place`]
1515
/// method on [`EntityCommands`] instead.
1616
pub struct AddChildInPlace {
1717
/// Parent entity to add the child to.
@@ -40,11 +40,11 @@ impl Command for AddChildInPlace {
4040
/// Command similar to [`RemoveParent`], but updating the child transform to keep
4141
/// it at the same [`GlobalTransform`].
4242
///
43-
/// You most likely want to use [`BuildChildrenTransformExt::remove_parent_keep_global_transform`]
43+
/// You most likely want to use [`BuildChildrenTransformExt::remove_parent_in_place`]
4444
/// method on [`EntityCommands`] instead.
45-
struct RemoveParentInPlace {
46-
/// `Entity` which parent must be removed.
47-
child: Entity,
45+
pub struct RemoveParentInPlace {
46+
/// `Entity` whose parent must be removed.
47+
pub child: Entity,
4848
}
4949
impl Command for RemoveParentInPlace {
5050
fn write(self, world: &mut World) {

examples/transforms/global_vs_local_translation.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ fn setup(
7070
}),
7171
..default()
7272
},
73-
ChangeGlobal,
73+
ChangeLocal,
7474
Move,
7575
ToggledBy(KeyCode::Key1),
7676
))

0 commit comments

Comments
 (0)