mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-05 11:01:49 +00:00
update Assets container - template-based now
This commit is contained in:
parent
848d121099
commit
d54b6b2e58
20 changed files with 68 additions and 143 deletions
|
|
@ -30,7 +30,7 @@ LevelFrontend::LevelFrontend(LevelController* controller, Assets* assets)
|
|||
}
|
||||
|
||||
if (type == BlockInteraction::step) {
|
||||
auto sound = assets->getSound(material->stepsSound);
|
||||
auto sound = assets->get<audio::Sound>(material->stepsSound);
|
||||
audio::play(
|
||||
sound,
|
||||
glm::vec3(),
|
||||
|
|
@ -45,10 +45,10 @@ LevelFrontend::LevelFrontend(LevelController* controller, Assets* assets)
|
|||
audio::Sound* sound = nullptr;
|
||||
switch (type) {
|
||||
case BlockInteraction::placing:
|
||||
sound = assets->getSound(material->placeSound);
|
||||
sound = assets->get<audio::Sound>(material->placeSound);
|
||||
break;
|
||||
case BlockInteraction::destruction:
|
||||
sound = assets->getSound(material->breakSound);
|
||||
sound = assets->get<audio::Sound>(material->breakSound);
|
||||
break;
|
||||
case BlockInteraction::step:
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue