Skip to content

Commit

Permalink
fix(actions,scorers): Transform/GlobalTransform are no longer needed …
Browse files Browse the repository at this point in the history
…for hierarchies.

Probably since bevyengine/bevy#4168
  • Loading branch information
zkat committed Sep 24, 2022
1 parent a32bc01 commit df10f03
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 14 deletions.
4 changes: 0 additions & 4 deletions src/actions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -186,8 +186,6 @@ impl ActionBuilder for StepsBuilder {
active_ent: Action(child_action),
steps: self.steps.clone(),
})
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&[child_action]);
}
}
Expand Down Expand Up @@ -360,8 +358,6 @@ impl ActionBuilder for ConcurrentlyBuilder {
.collect();
cmd.entity(action)
.insert(Name::new("Concurrent Action"))
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&children[..])
.insert(Concurrently {
actions: children.into_iter().map(Action).collect(),
Expand Down
10 changes: 0 additions & 10 deletions src/scorers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,6 @@ impl ScorerBuilder for AllOrNothingBuilder {
.collect();
cmd.entity(scorer)
.insert(Score::default())
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&scorers[..])
.insert(Name::new("Scorer"))
.insert(AllOrNothing {
Expand Down Expand Up @@ -374,8 +372,6 @@ impl ScorerBuilder for SumOfScorersBuilder {
.map(|scorer| spawn_scorer(&**scorer, cmd, actor))
.collect();
cmd.entity(scorer)
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&scorers[..])
.insert(SumOfScorers {
threshold: self.threshold,
Expand Down Expand Up @@ -513,8 +509,6 @@ impl ScorerBuilder for ProductOfScorersBuilder {
.map(|scorer| spawn_scorer(&**scorer, cmd, actor))
.collect();
cmd.entity(scorer)
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&scorers[..])
.insert(ProductOfScorers {
threshold: self.threshold,
Expand Down Expand Up @@ -629,8 +623,6 @@ impl ScorerBuilder for WinningScorerBuilder {
.map(|scorer| spawn_scorer(&**scorer, cmd, actor))
.collect();
cmd.entity(scorer)
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&scorers[..])
.insert(WinningScorer {
threshold: self.threshold,
Expand Down Expand Up @@ -716,8 +708,6 @@ impl ScorerBuilder for EvaluatingScorerBuilder {
let inner_scorer = spawn_scorer(&*self.scorer, cmd, actor);
let scorers = vec![inner_scorer];
cmd.entity(scorer)
.insert(Transform::default())
.insert(GlobalTransform::default())
.push_children(&scorers[..])
.insert(EvaluatingScorer {
evaluator: self.evaluator.clone(),
Expand Down

0 comments on commit df10f03

Please sign in to comment.