unificats els resources en un namespace

This commit is contained in:
2025-11-11 10:04:57 +01:00
parent 1821b84e73
commit 54fc6d2902
35 changed files with 356 additions and 341 deletions

View File

@@ -11,7 +11,7 @@
#include "core/rendering/surface.hpp" // Para Surface
#include "core/rendering/surface_sprite.hpp" // Para SSprite
#include "core/rendering/text.hpp" // Para Text, TEXT_STROKE
#include "core/resources/resource.hpp" // Para Resource
#include "core/resources/resource_cache.hpp" // Para Resource
#include "core/system/global_events.hpp" // Para check
#include "game/options.hpp" // Para Options, options, OptionsGame, SectionS...
#include "game/scene_manager.hpp" // Para SceneManager
@@ -209,7 +209,7 @@ void Ending::iniTexts() {
sprite_texts_.clear();
for (const auto& txt : texts) {
auto text = Resource::get()->getText("smb2");
auto text = Resource::Cache::get()->getText("smb2");
const float WIDTH = text->lenght(txt.caption, 1) + 2 + 2;
const float HEIGHT = text->getCharacterSize() + 2 + 2;
@@ -284,7 +284,7 @@ void Ending::iniPics() {
EndingSurface sp;
// Crea la texture
sp.image_surface = Resource::get()->getSurface(pic.caption);
sp.image_surface = Resource::Cache::get()->getSurface(pic.caption);
sp.image_surface->setTransparentColor();
const float WIDTH = sp.image_surface->getWidth();
const float HEIGHT = sp.image_surface->getHeight();