Rehti MMORPG  1.0.0
Rehti MMORPG is a free and open source MMORPG game.
TextureReader.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include <map>
4 #include <string>
5 
6 #include "AssetTypes.hpp"
7 #include "CharacterReader.hpp"
8 #include "ObjectReader.hpp"
9 
20 std::map<std::string, ImageData> loadObjectTextures(const GameObjects& gameObjects);
21 
28 std::map<std::string, ImageData> loadCharacterTextures(const GameCharacters& gameCharacters);
29 
36 std::map<std::string, ImageData> loadItemTextures(const GameItems& gameItems);
37 
43 std::map<int, ImageData> loadMapTextures();
44 
50 std::vector<std::vector<int>> loadMapTexturePositions();
51 
62 ImageData createAreaBlendMap(const std::vector<std::vector<int>>& mapTexturePositionMatrix, int rowOffset, int columnOffset);
63 
ImageData loadDefaultTexture()
Loads default texture into memory.
Definition: TextureReader.cpp:285
std::map< int, ImageData > loadMapTextures()
Reads all different the map texture files.
Definition: TextureReader.cpp:170
ImageData createAreaBlendMap(const std::vector< std::vector< int >> &mapTexturePositionMatrix, int rowOffset, int columnOffset)
Creates a blend map for one area. Blend map shows which texture is used on each tile.
Definition: TextureReader.cpp:232
std::vector< std::vector< int > > loadMapTexturePositions()
Loads map texture positions. E.g. which tile contains which texture.
Definition: TextureReader.cpp:214
std::map< std::string, ImageData > loadItemTextures(const GameItems &gameItems)
Reads all the item object textures and item icons into a map (key=filename, value=ImageData)
Definition: TextureReader.cpp:98
std::map< std::string, ImageData > loadObjectTextures(const GameObjects &gameObjects)
Reads all the object's textures + character textures into a map (key=filename, value=ImageData)
Definition: TextureReader.cpp:13
std::map< std::string, ImageData > loadCharacterTextures(const GameCharacters &gameCharacters)
Reads all the character's textures into a map (key=filename, value=ImageData)
Definition: TextureReader.cpp:60
Contains all the character data. This is used to load character assets into memory and spawn characte...
Definition: CharacterReader.hpp:62
Contains all the item data in the game. This is used to load item assets into memory and create item ...
Definition: ItemReader.hpp:87
Contains all the objects defined in the objects.json file.
Definition: ObjectReader.hpp:101
Definition: BasicTypes.hpp:161