forked from mirror/openmw-tes3mp
Added a static list of skill names to ESM::Skill.
This commit is contained in:
parent
e88f67bb3c
commit
1c79a62957
4 changed files with 101 additions and 0 deletions
|
@ -102,6 +102,7 @@ source_group(components\\esm_store FILES ${ESM_STORE} ${ESM_STORE_HEADER})
|
||||||
file(GLOB ESM_HEADER ${COMP_DIR}/esm/*.hpp)
|
file(GLOB ESM_HEADER ${COMP_DIR}/esm/*.hpp)
|
||||||
set(ESM
|
set(ESM
|
||||||
${COMP_DIR}/esm/load_impl.cpp
|
${COMP_DIR}/esm/load_impl.cpp
|
||||||
|
${COMP_DIR}/esm/skill.cpp
|
||||||
)
|
)
|
||||||
source_group(components\\esm FILES ${ESM_HEADER} ${ESM})
|
source_group(components\\esm FILES ${ESM_HEADER} ${ESM})
|
||||||
|
|
||||||
|
|
33
components/esm/loadskil.cpp
Normal file
33
components/esm/loadskil.cpp
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
#include "loadskil.hpp"
|
||||||
|
|
||||||
|
namespace ESMS
|
||||||
|
{
|
||||||
|
const std::string Skill::sSkillNames[Length] = {
|
||||||
|
"Block",
|
||||||
|
"Armorer",
|
||||||
|
"Medium Armor",
|
||||||
|
"Heavy Armor",
|
||||||
|
"Blunt Weapon",
|
||||||
|
"Long Blade",
|
||||||
|
"Axe",
|
||||||
|
"Spear",
|
||||||
|
"Athletics",
|
||||||
|
"Enchant",
|
||||||
|
"Destruction",
|
||||||
|
"Alteration",
|
||||||
|
"Illusion",
|
||||||
|
"Conjuration",
|
||||||
|
"Mysticism",
|
||||||
|
"Restoration",
|
||||||
|
"Alchemy",
|
||||||
|
"Unarmored",
|
||||||
|
"Security",
|
||||||
|
"Sneak",
|
||||||
|
"Acrobatics",
|
||||||
|
"Light Armor",
|
||||||
|
"Short Blade",
|
||||||
|
"Marksman",
|
||||||
|
"Speechcraft",
|
||||||
|
"Hand To Hand",
|
||||||
|
};
|
||||||
|
}
|
|
@ -30,6 +30,39 @@ struct Skill
|
||||||
|
|
||||||
std::string description;
|
std::string description;
|
||||||
|
|
||||||
|
enum SkillEnum
|
||||||
|
{
|
||||||
|
Block = 0,
|
||||||
|
Armorer = 1,
|
||||||
|
MediumArmor = 2,
|
||||||
|
HeavyArmor = 3,
|
||||||
|
BluntWeapon = 4,
|
||||||
|
LongBlade = 5,
|
||||||
|
Axe = 6,
|
||||||
|
Spear = 7,
|
||||||
|
Athletics = 8,
|
||||||
|
Enchant = 9,
|
||||||
|
Destruction = 10,
|
||||||
|
Alteration = 11,
|
||||||
|
Illusion = 12,
|
||||||
|
Conjuration = 13,
|
||||||
|
Mysticism = 14,
|
||||||
|
Restoration = 15,
|
||||||
|
Alchemy = 16,
|
||||||
|
Unarmored = 17,
|
||||||
|
Security = 18,
|
||||||
|
Sneak = 19,
|
||||||
|
Acrobatics = 20,
|
||||||
|
LightArmor = 21,
|
||||||
|
ShortBlade = 22,
|
||||||
|
Marksman = 23,
|
||||||
|
Mercantile = 24,
|
||||||
|
Speechcraft = 25,
|
||||||
|
HandToHand = 26,
|
||||||
|
Length
|
||||||
|
};
|
||||||
|
static const std::string sSkillNames[Length];
|
||||||
|
|
||||||
void load(ESMReader &esm)
|
void load(ESMReader &esm)
|
||||||
{
|
{
|
||||||
esm.getHNT(data, "SKDT", 24);
|
esm.getHNT(data, "SKDT", 24);
|
||||||
|
|
34
components/esm/skill.cpp
Normal file
34
components/esm/skill.cpp
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
#include "loadskil.hpp"
|
||||||
|
|
||||||
|
namespace ESM
|
||||||
|
{
|
||||||
|
const std::string Skill::sSkillNames[Length] = {
|
||||||
|
"Block",
|
||||||
|
"Armorer",
|
||||||
|
"Medium Armor",
|
||||||
|
"Heavy Armor",
|
||||||
|
"Blunt Weapon",
|
||||||
|
"Long Blade",
|
||||||
|
"Axe",
|
||||||
|
"Spear",
|
||||||
|
"Athletics",
|
||||||
|
"Enchant",
|
||||||
|
"Destruction",
|
||||||
|
"Alteration",
|
||||||
|
"Illusion",
|
||||||
|
"Conjuration",
|
||||||
|
"Mysticism",
|
||||||
|
"Restoration",
|
||||||
|
"Alchemy",
|
||||||
|
"Unarmored",
|
||||||
|
"Security",
|
||||||
|
"Sneak",
|
||||||
|
"Acrobatics",
|
||||||
|
"Light Armor",
|
||||||
|
"Short Blade",
|
||||||
|
"Marksman",
|
||||||
|
"Mercantile",
|
||||||
|
"Speechcraft",
|
||||||
|
"Hand To Hand",
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue