1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-18 13:12:50 +00:00
OpenMW/components/fallback/fallback.hpp

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

28 lines
733 B
C++
Raw Normal View History

2016-01-06 12:46:06 +01:00
#ifndef OPENMW_COMPONENTS_FALLBACK_H
#define OPENMW_COMPONENTS_FALLBACK_H
2013-03-15 10:26:04 +01:00
#include <map>
#include <string>
2022-08-28 17:20:49 +02:00
#include <string_view>
2013-03-15 10:26:04 +01:00
#include <osg/Vec4f>
2013-03-15 10:26:04 +01:00
2016-01-06 12:46:06 +01:00
namespace Fallback
{
2016-01-06 12:46:06 +01:00
/// @brief contains settings imported from the Morrowind INI file.
class Map
{
2022-08-28 17:20:49 +02:00
static std::map<std::string, std::string, std::less<>> mFallbackMap;
2016-01-06 12:58:36 +01:00
2022-09-22 21:26:05 +03:00
public:
static void init(const std::map<std::string, std::string>& fallback);
2022-09-22 21:26:05 +03:00
2022-08-28 17:20:49 +02:00
static std::string_view getString(std::string_view fall);
static float getFloat(std::string_view fall);
static int getInt(std::string_view fall);
static bool getBool(std::string_view fall);
static osg::Vec4f getColour(std::string_view fall);
};
}
#endif