diff --git a/apps/openmw/mwlua/animationbindings.cpp b/apps/openmw/mwlua/animationbindings.cpp index f20b22e35f..17dd9aef42 100644 --- a/apps/openmw/mwlua/animationbindings.cpp +++ b/apps/openmw/mwlua/animationbindings.cpp @@ -234,9 +234,9 @@ namespace MWLua [mechanics](const sol::object& object, const std::string& groupname, const sol::table& options) { uint32_t numberOfLoops = options.get_or("loops", std::numeric_limits::max()); float speed = options.get_or("speed", 1.f); - std::string startKey = options.get_or("startkey", "start"); - std::string stopKey = options.get_or("stopkey", "stop"); - bool forceLoop = options.get_or("forceloop", false); + std::string startKey = options.get_or("startKey", "start"); + std::string stopKey = options.get_or("stopKey", "stop"); + bool forceLoop = options.get_or("forceLoop", false); MWWorld::Ptr ptr = getMutablePtrOrThrow(ObjectVariant(object)); mechanics->playAnimationGroupLua(ptr, groupname, numberOfLoops, speed, startKey, stopKey, forceLoop); @@ -247,20 +247,20 @@ namespace MWLua ptr, groupname, std::numeric_limits::max(), 1, "start", "stop", false); }); - api["playBlended"] = [](const sol::object& object, std::string_view groupname, const sol::table& options) { + api["playBlended"] = [](const sol::object& object, std::string_view groupName, const sol::table& options) { uint32_t loops = options.get_or("loops", 0u); MWRender::Animation::AnimPriority priority = getPriorityArgument(options); - BlendMask blendMask = options.get_or("blendmask", BlendMask::BlendMask_All); - bool autoDisable = options.get_or("autodisable", true); + BlendMask blendMask = options.get_or("blendMask", BlendMask::BlendMask_All); + bool autoDisable = options.get_or("autoDisable", true); float speed = options.get_or("speed", 1.0f); - std::string start = options.get_or("startkey", "start"); - std::string stop = options.get_or("stopkey", "stop"); - float startpoint = options.get_or("startpoint", 0.0f); - bool forceLoop = options.get_or("forceloop", false); + std::string start = options.get_or("startKey", "start"); + std::string stop = options.get_or("stopKey", "stop"); + float startPoint = options.get_or("startPoint", 0.0f); + bool forceLoop = options.get_or("forceLoop", false); auto animation = getMutableAnimationOrThrow(ObjectVariant(object)); - animation->play(groupname, priority, blendMask, autoDisable, speed, start, stop, startpoint, loops, - forceLoop || animation->isLoopingAnimation(groupname)); + animation->play(groupName, priority, blendMask, autoDisable, speed, start, stop, startPoint, loops, + forceLoop || animation->isLoopingAnimation(groupName)); }; api["hasGroup"] = [](const sol::object& object, std::string_view groupname) -> bool { @@ -287,11 +287,11 @@ namespace MWLua context.mLuaManager->addAction( [object = ObjectVariant(object), model = getStaticModelOrThrow(staticOrID), effectId = options.get_or("vfxId", ""), loop = options.get_or("loop", false), - bonename = options.get_or("bonename", ""), + boneName = options.get_or("boneName", ""), particleTexture = options.get_or("particleTextureOverride", "")] { MWRender::Animation* anim = getMutableAnimationOrThrow(ObjectVariant(object)); - anim->addEffect(model, effectId, loop, bonename, particleTexture); + anim->addEffect(model, effectId, loop, boneName, particleTexture); }, "addVfxAction"); }); diff --git a/apps/openmw/mwlua/luamanagerimp.cpp b/apps/openmw/mwlua/luamanagerimp.cpp index 5c8a3ff909..b15fb2f5bf 100644 --- a/apps/openmw/mwlua/luamanagerimp.cpp +++ b/apps/openmw/mwlua/luamanagerimp.cpp @@ -426,14 +426,14 @@ namespace MWLua std::string_view start, std::string_view stop, float startpoint, uint32_t loops, bool loopfallback) { sol::table options = mLua.newTable(); - options["blendmask"] = blendMask; - options["autodisable"] = autodisable; + options["blendMask"] = blendMask; + options["autoDisable"] = autodisable; options["speed"] = speedmult; - options["startkey"] = start; - options["stopkey"] = stop; - options["startpoint"] = startpoint; + options["startKey"] = start; + options["stopKey"] = stop; + options["startPoint"] = startpoint; options["loops"] = loops; - options["forceloop"] = loopfallback; + options["forceLoop"] = loopfallback; bool priorityAsTable = false; for (uint32_t i = 1; i < MWRender::sNumBlendMasks; i++)