diff options
Diffstat (limited to 'src/game/client/resource')
| -rw-r--r-- | src/game/client/resource/sound_effect.cc | 7 | ||||
| -rw-r--r-- | src/game/client/resource/sound_effect.hh | 9 | ||||
| -rw-r--r-- | src/game/client/resource/texture_gui.cc | 9 | ||||
| -rw-r--r-- | src/game/client/resource/texture_gui.hh | 9 |
4 files changed, 31 insertions, 3 deletions
diff --git a/src/game/client/resource/sound_effect.cc b/src/game/client/resource/sound_effect.cc index 4cc5b70..6b87dcc 100644 --- a/src/game/client/resource/sound_effect.cc +++ b/src/game/client/resource/sound_effect.cc @@ -1,3 +1,8 @@ +// SPDX-License-Identifier: BSD-2-Clause +// Copyright (c) 2025 Kirill Dmitrievich +// File: sound_effect.cc +// Description: Sound effect resource + #include "client/pch.hh" #include "client/resource/sound_effect.hh" @@ -35,7 +40,7 @@ static const void* sound_effect_load_func(const char* name, std::uint32_t flags) auto file = PHYSFS_openRead(name); if(file == nullptr) { - spdlog::warn("sfx: {}: {}", name, physfs_error()); + spdlog::warn("sfx: {}: {}", name, physfs::last_error()); return nullptr; } diff --git a/src/game/client/resource/sound_effect.hh b/src/game/client/resource/sound_effect.hh index f2db33b..602293c 100644 --- a/src/game/client/resource/sound_effect.hh +++ b/src/game/client/resource/sound_effect.hh @@ -1,3 +1,10 @@ +// SPDX-License-Identifier: BSD-2-Clause +// Copyright (c) 2025 Kirill Dmitrievich +// File: sound_effect.hh +// Description: Sound effect resource + +#ifndef CLIENT_RESOURCE_SOUND_EFFECT_HH +#define CLIENT_RESOURCE_SOUND_EFFECT_HH #pragma once struct SoundEffect final { @@ -6,3 +13,5 @@ struct SoundEffect final { std::string name; ALuint buffer; }; + +#endif diff --git a/src/game/client/resource/texture_gui.cc b/src/game/client/resource/texture_gui.cc index beb2f54..b87a244 100644 --- a/src/game/client/resource/texture_gui.cc +++ b/src/game/client/resource/texture_gui.cc @@ -1,3 +1,8 @@ +// SPDX-License-Identifier: BSD-2-Clause +// Copyright (c) 2025 Kirill Dmitrievich +// File: texture_gui.cc +// Description: GUI texture resource + #include "client/pch.hh" #include "client/resource/texture_gui.hh" @@ -12,11 +17,11 @@ static const void* texture_gui_load_func(const char* name, std::uint32_t flags) unsigned int image_load_flags = 0U; if(flags & TEXTURE_GUI_LOAD_VFLIP) { - image_load_flags |= IMAGE_LOAD_FLIP; + image_load_flags |= IMGFLAG_FLIP; } if(flags & TEXTURE_GUI_LOAD_GRAYSCALE) { - image_load_flags |= IMAGE_LOAD_GRAY; + image_load_flags |= IMGFLAG_GRAY; } if(auto image = resource::load<Image>(name, image_load_flags)) { diff --git a/src/game/client/resource/texture_gui.hh b/src/game/client/resource/texture_gui.hh index 2d42c83..2487a77 100644 --- a/src/game/client/resource/texture_gui.hh +++ b/src/game/client/resource/texture_gui.hh @@ -1,3 +1,10 @@ +// SPDX-License-Identifier: BSD-2-Clause +// Copyright (c) 2025 Kirill Dmitrievich +// File: texture_gui.hh +// Description: GUI texture resource + +#ifndef CLIENT_RESOURCE_TEXTURE_GUI_HH +#define CLIENT_RESOURCE_TEXTURE_GUI_HH #pragma once constexpr static unsigned int TEXTURE_GUI_LOAD_CLAMP_S = 0x0001; @@ -13,3 +20,5 @@ struct TextureGUI final { ImTextureID handle; glm::ivec2 size; }; + +#endif |
