mirror of
https://github.com/zoriya/Bomberman.git
synced 2026-05-27 08:13:18 +00:00
fix system name
This commit is contained in:
@@ -31,7 +31,7 @@ namespace BBM
|
||||
|
||||
//! @brief is music playing
|
||||
bool isPlaying(void);
|
||||
|
||||
//! @brief update music stream
|
||||
void updateMusicStream(void);
|
||||
//! @inherit
|
||||
WAL::Component *clone(WAL::Entity &entity) const override;
|
||||
|
||||
@@ -25,7 +25,7 @@ namespace BBM
|
||||
MusicSystem(const MusicSystem &) = default;
|
||||
//! @brief Default dtor
|
||||
~MusicSystem() override = default;
|
||||
//! @brief A SoundManager screen system can't be assigned.
|
||||
//! @brief A MusicManager screen system can't be assigned.
|
||||
MusicSystem &operator=(const MusicSystem &) = delete;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -7,18 +7,18 @@
|
||||
|
||||
namespace BBM {
|
||||
|
||||
SoundManagerSystem::SoundManagerSystem(WAL::Wal &wal)
|
||||
PlayerSoundManagerSystem::PlayerSoundManagerSystem(WAL::Wal &wal)
|
||||
: System(wal)
|
||||
{}
|
||||
|
||||
void SoundManagerSystem::onFixedUpdate(WAL::ViewEntity<SoundComponent, ControllableComponent, HealthComponent> &entity)
|
||||
void PlayerSoundManagerSystem::onFixedUpdate(WAL::ViewEntity<SoundComponent, ControllableComponent, HealthComponent> &entity)
|
||||
{
|
||||
const auto &controllable = entity.get<ControllableComponent>();
|
||||
auto &sound = entity.get<SoundComponent>();
|
||||
auto &health = entity.get<HealthComponent>();
|
||||
|
||||
sound.setVolume(sound.volume);
|
||||
std::map<bool, SoundComponent::soundIndex> soundIndex = {
|
||||
std::map<bool, SoundComponent::SoundIndex> soundIndex = {
|
||||
{controllable.bomb, SoundComponent::BOMB},
|
||||
{controllable.jump, SoundComponent::JUMP},
|
||||
{controllable.move.x != 0 || controllable.move.y != 0, SoundComponent::MOVE}
|
||||
|
||||
@@ -13,19 +13,19 @@
|
||||
|
||||
namespace BBM
|
||||
{
|
||||
class SoundManagerSystem : public WAL::System<SoundComponent, ControllableComponent, HealthComponent>
|
||||
class PlayerSoundManagerSystem : public WAL::System<SoundComponent, ControllableComponent, HealthComponent>
|
||||
{
|
||||
public:
|
||||
//! @inherit
|
||||
void onFixedUpdate(WAL::ViewEntity<SoundComponent, ControllableComponent, HealthComponent> &entity) override;
|
||||
|
||||
//! @brief ctor
|
||||
SoundManagerSystem(WAL::Wal &wal);
|
||||
PlayerSoundManagerSystem(WAL::Wal &wal);
|
||||
//! @brief Default copy ctor
|
||||
SoundManagerSystem(const SoundManagerSystem &) = default;
|
||||
PlayerSoundManagerSystem(const PlayerSoundManagerSystem &) = default;
|
||||
//! @brief Default dtor
|
||||
~SoundManagerSystem() override = default;
|
||||
~PlayerSoundManagerSystem() override = default;
|
||||
//! @brief A SoundManager screen system can't be assigned.
|
||||
SoundManagerSystem &operator=(const SoundManagerSystem &) = delete;
|
||||
PlayerSoundManagerSystem &operator=(const PlayerSoundManagerSystem &) = delete;
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user