mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-28 19:21:04 +00:00
Do not copy the whole attributes store
This commit is contained in:
parent
fc1f244627
commit
1126f38a1e
@ -476,7 +476,7 @@ namespace MWLua
|
|||||||
|
|
||||||
auto skillIncreasesForAttributeStatsT
|
auto skillIncreasesForAttributeStatsT
|
||||||
= context.mLua->sol().new_usertype<SkillIncreasesForAttributeStats>("SkillIncreasesForAttributeStats");
|
= context.mLua->sol().new_usertype<SkillIncreasesForAttributeStats>("SkillIncreasesForAttributeStats");
|
||||||
for (auto attribute : MWBase::Environment::get().getESMStore()->get<ESM::Attribute>())
|
for (const auto& attribute : MWBase::Environment::get().getESMStore()->get<ESM::Attribute>())
|
||||||
{
|
{
|
||||||
skillIncreasesForAttributeStatsT[ESM::RefId(attribute.mId).serializeText()] = sol::property(
|
skillIncreasesForAttributeStatsT[ESM::RefId(attribute.mId).serializeText()] = sol::property(
|
||||||
[=](const SkillIncreasesForAttributeStats& stat) { return stat.get(context, attribute.mId); },
|
[=](const SkillIncreasesForAttributeStats& stat) { return stat.get(context, attribute.mId); },
|
||||||
|
Loading…
x
Reference in New Issue
Block a user