mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-06 07:15:36 +00:00
Address feedback
This commit is contained in:
parent
cd8f2355c0
commit
2a1d520c9e
3 changed files with 7 additions and 5 deletions
|
@ -5,6 +5,8 @@
|
|||
|
||||
#include <components/misc/strings/algorithm.hpp>
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
namespace ESM
|
||||
{
|
||||
const SkillId Skill::Block("Block");
|
||||
|
@ -42,7 +44,7 @@ namespace ESM
|
|||
|
||||
bool hasIndex = false;
|
||||
bool hasData = false;
|
||||
int index = -1;
|
||||
int32_t index = -1;
|
||||
while (esm.hasMoreSubs())
|
||||
{
|
||||
esm.getSubName();
|
||||
|
@ -89,7 +91,7 @@ namespace ESM
|
|||
mDescription.clear();
|
||||
}
|
||||
|
||||
static const RefId sSkills[] = {
|
||||
static const RefId sSkills[Skill::Length] = {
|
||||
Skill::Block,
|
||||
Skill::Armorer,
|
||||
Skill::MediumArmor,
|
||||
|
|
|
@ -49,7 +49,7 @@ namespace ESM
|
|||
mWerewolfDeprecatedData = true;
|
||||
std::vector<StatState<float>> skills(mSkills.begin(), mSkills.end());
|
||||
|
||||
for (int i = 0; i < ESM::Skill::Length; ++i)
|
||||
for (size_t i = 0; i < std::size(mSkills); ++i)
|
||||
{
|
||||
StatState<float> skill;
|
||||
skill.load(esm, intFallback);
|
||||
|
|
|
@ -54,7 +54,7 @@ namespace ESM
|
|||
= esm.getFormatVersion() <= MaxClearModifiersFormatVersion && !mObject.mNpcStats.mIsWerewolf;
|
||||
if (esm.hasMoreSubs())
|
||||
{
|
||||
for (int i = 0; i < Attribute::Length; ++i)
|
||||
for (size_t i = 0; i < std::size(mSaveAttributes); ++i)
|
||||
{
|
||||
StatState<float> attribute;
|
||||
attribute.load(esm, intFallback);
|
||||
|
@ -64,7 +64,7 @@ namespace ESM
|
|||
if (mObject.mNpcStats.mIsWerewolf)
|
||||
mObject.mCreatureStats.mAttributes[i] = attribute;
|
||||
}
|
||||
for (int i = 0; i < Skill::Length; ++i)
|
||||
for (size_t i = 0; i < std::size(mSaveSkills); ++i)
|
||||
{
|
||||
StatState<float> skill;
|
||||
skill.load(esm, intFallback);
|
||||
|
|
Loading…
Reference in a new issue