1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-21 08:53:52 +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 11:46:06 +00:00
#ifndef OPENMW_COMPONENTS_FALLBACK_H
#define OPENMW_COMPONENTS_FALLBACK_H
2013-03-15 09:26:04 +00:00
#include <map>
#include <string>
2022-08-28 15:20:49 +00:00
#include <string_view>
2013-03-15 09:26:04 +00:00
#include <osg/Vec4f>
2013-03-15 09:26:04 +00:00
2016-01-06 11:46:06 +00:00
namespace Fallback
{
2016-01-06 11:46:06 +00:00
/// @brief contains settings imported from the Morrowind INI file.
class Map
{
2022-08-28 15:20:49 +00:00
static std::map<std::string, std::string, std::less<>> mFallbackMap;
2016-01-06 11:58:36 +00:00
2022-09-22 18:26:05 +00:00
public:
static void init(const std::map<std::string, std::string>& fallback);
2022-09-22 18:26:05 +00:00
2022-08-28 15:20:49 +00: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