public WithMakeAnimation(ActorInitializer init, WithMakeAnimationInfo info) { this.info = info; var self = init.Self; renderBuilding = self.Trait <RenderBuilding>(); var building = self.Trait <Building>(); if (!building.SkipMakeAnimation) { renderBuilding.PlayCustomAnimThen(self, info.Sequence, () => { building.NotifyBuildingComplete(self); }); } }
public WithMakeAnimation(ActorInitializer init, WithMakeAnimationInfo info) { this.info = info; var self = init.Self; wsb = self.Trait <WithSpriteBody>(); var building = self.TraitOrDefault <Building>(); if (building != null && !building.SkipMakeAnimation) { wsb.PlayCustomAnimation(self, info.Sequence, () => { building.NotifyBuildingComplete(self); }); } }